Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
dhrogers committed Nov 5, 2024
1 parent 6233262 commit ac2ba92
Showing 1 changed file with 23 additions and 1 deletion.
24 changes: 23 additions & 1 deletion scripts/cinematic
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,31 @@ class Element:
self.colormap.inputs.channel.set(element['channel'], False) # name of the channel that needs to be rendered
self.colormap.inputs.images.set(self.imReader.outputs.images, False)
self.colormap.inputs.composition_id.set(-1, False)

# set output
self.outputs = self.colormap.outputs

# shadow
if 'shadow' in config:
if not 'state' in config['shadow'] or config['shadow']['state']:
if not 'shadow' in config or config['shadow']['type'] == 'SSAO':
shadow = config['shadow']
self.shadow = pycinema.filters.ShaderSSAO()
self.shadow.inputs.images.set(self.colormap.outputs.images, False)
# other settings
if 'radius' in shadow:
self.shadow.inputs.radius.set(shadow['radius'])
else:
self.shadow.inputs.radius.set(0.03)
if 'samples' in shadow:
self.shadow.inputs.samples.set(shadow['samples'])
else:
self.shadow.inputs.samples.set(32)
if 'diff' in shadow:
self.shadow.inputs.diff.set(shadow['diff'])
else:
self.shadow.inputs.diff.set(0.5)
# set output
self.outputs = self.shadow.outputs


def function_composite(args):
Expand Down

0 comments on commit ac2ba92

Please sign in to comment.