In TouchDesigner, when you composite multiple masks with varying opacities, the resulting output can appear dim if the masks’ combined opacity is not properly managed. To ensure a vibrant output even when the masks’ opacity values sum to less than 100%, you can use normalization or adjustment techniques. Here’s a step-by-step approach to achieve this:
Ensure you have your 4 masks set up and their opacity controlled by incoming percentage values. Let’s assume these values are normalized between 0 and 1 (e.g., 25% is 0.25).
When the sum of the opacity values is less than 1, the output will naturally be dimmer. To maintain a vibrant output, you can normalize the values so that their sum is always 1.
-
Sum the Opacity Values:
- Use a
Math CHOP to sum the incoming percentage values.
- Set the
Math CHOP to “Add” mode.
-
Normalize the Values:
- Use another
Math CHOP to divide each incoming value by the total sum.
- Connect the output of the summing
Math CHOP to this Math CHOP.
- In the
Math CHOP parameters, set the operation to “Divide” and use the total sum from the first Math CHOP as the divisor.
Now that you have normalized opacity values, apply them to the respective masks:
- Use a
Lookup CHOP or a Rename CHOP to reassign these normalized values to control the opacity of each mask.
When compositing the masks, ensure the blending mode is set to add or another appropriate blending mode to combine the masks without losing brightness:
- Use an
Over TOP or Composite TOP:
- Ensure the blending mode in
Composite TOP is set to “Add” or another suitable mode that maintains brightness.
- Chain the masks together using this blending mode.
If further adjustment is needed to ensure vibrancy:
- Levels Adjustment:
- Use a
Level TOP to adjust the final output’s levels, brightness, and contrast to ensure it is vibrant.
-
Incoming Opacity Values:
Constant CHOP (4 channels, each representing a mask’s opacity).
-
Sum Opacity Values:
Math CHOP (set to “Add” mode).
-
Normalize Values:
Math CHOP (set to “Divide” mode, with the divisor being the total sum from the previous Math CHOP).
-
Apply Normalized Values:
Lookup CHOP or Rename CHOP (map the normalized values back to the masks).
-
Composite Masks:
Composite TOP (set to “Add” blending mode).
-
Adjust Final Output:
Level TOP (tweak levels to ensure vibrant output).
By following these steps, you ensure that the combined opacity values always sum to a maximum value, thereby maintaining a vibrant and bright composite output.