Using Logical Operations
 
 
 

Logical operations are applied separately to each of the red, green, and blue components of images. You can apply Logic Ops commands to combine the RGB channels of corresponding pixels from two source images, described as follows.

AddAdds the luma values of the corresponding pixels from two source clips and assigns the resulting value to the corresponding pixel in the generated clip. If the result is greater than 255, the pixel in the destination clip is clamped at a value of 255 (white).

The order in which the two source clips are selected does not affect the result of the Add operation. The generated clip is brighter than either of the two selected source clips.

AndApplies a bitwise logical AND operation between the RGB channels of corresponding pixels in the two source clips. The order in which the two source clips are selected does not affect the result of the AND operation.

AndInvApplies a bitwise logical AND operation between the negative of the RGB channels of the pixels of the front clip and the RGB channels of the pixels of the back clip.

AndRevApplies a bitwise logical AND operation between the negative of the RGB channels of the pixels of the back clip and the RGB channels of the pixels of the front clip. AndRev and AndInv yield the same result if you switch the order of the two source clips.

DifferenceCalculates the difference between the RGB channels of the corresponding pixels of the two source clips. As opposed to Subtract, the order of the two source clips does not matter, as the smaller channel value is always subtracted from the larger channel value.

Blending with white inverts the colour channel values; blending with black produces no change.

ExclusionAdds the RGB channel values of the corresponding pixels from the two source clips, then subtracts twice the product of these channels. The order of the source clips does not matter.

HardLightMultiplies or screens the selected colour of the front clip onto the back clip, depending on the blend colour. The effect is similar to shining a harsh spotlight on the image, and greatly reduces the contrast levels in the image.

If the blend colour (light source) is lighter than 50% grey, the image is lightened as if it were screened—this is useful for adding highlights to an image. If the blend colour is darker than 50% grey, the image is darkened, as if it were multiplied—this is useful for adding shadows.

Max/LightenCompares the RGB channels of each pixel of the source clips individually and returns the larger of the two values. The order in which you select the source clips does not affect the result.

Min/DarkenCompares the RGB channels of each pixel of the source clips individually and returns the smaller of the two values in the resulting clip. The order in which you select the source clips does not affect the result.

MultiplyMultiplies the RGB channel values of corresponding pixels of the two source clips and normalizes the result by dividing by 255. The resulting RGB channel values are assigned to the corresponding pixels in the generated clip.

The order in which you select the source clips does not affect the result.

NandApplies a bitwise logical AND operation between the RGB channel values of the corresponding pixels of the two source clips, negates the result, and assigns the result to the channels of the corresponding pixels in the generated clip.

NorApplies a bitwise logical OR operation between the RGB channel values of the corresponding pixels of the two source clips, negates the result, and assigns the result to the channels of the corresponding pixels in the generated clip.

The order in which you select the source clips does not affect the result.

OrApplies a bitwise logical OR operation between the RGB channel values of the corresponding pixels of the two source clips, and assigns the result to the channels of the corresponding pixel in the generated clip.

The order in which you select the source clips does not affect the result.

OrInvApplies a bitwise logical OR operation between the negative of the RGB channel values of the pixels in the front clip and the RGB channel values of the corresponding pixels in the back clip, and assigns the result to the channels of the corresponding pixels in the generated clip.

OrRevApplies a bitwise logical OR operation between the RGB channel values of the pixels in the front clip and the negative of the RGB channel values of the corresponding pixel in the back clip, and assigns the result to the channels of the corresponding pixels in the generated clip.

OrRev and OrInv yield the same result if you switch the order of the two source clips.

OverlayMultiplies or screens the colours, depending on the RGB channel values of the first clip you select. Patterns or colours overlay the existing RGB channel values while preserving the highlights and shadows of the first clip's colour. The first clip's colour is not replaced but is mixed with the second clip's colour to reflect the lightness or darkness of the original colour.

ScreenMultiplies the inverse of the second clip's colours with the colours of the first clip. The resulting colour is always lighter. The colour remains unchanged when you screen with black. Screening with white produces white. The effect is similar to projecting multiple photographic slides on top of each other.

SoftLightShines a soft, diffuse light on the image. If the blend colour (light source) is lighter than 50% grey, the image is lightened. If the blend colour is darker than 50% grey, the image is darkened.

Using this mode with a black frame results in a very dark effect, with white a very bright one.

SubtractSubtracts the RGB channel values of the pixels from the back clip from the RGB channel values of the pixels from the front clip and assigns the result to the RGB channel values of the pixel in the generated clip. If an RGB channel value from the back clip is larger than the corresponding channel value in the front clip, yielding a negative result, that result is clamped at 0 (black).

The order of the source clips is important since the back clip is subtracted from the front clip. The resulting clip is always darker than either of the two source clips.

XnorApplies a bitwise logical exclusive OR operation between the RGB channel values of the corresponding pixels of the two source clips, negates the result, and assigns the result to the channels of the corresponding pixels in the generated clip.

The order in which you select the source clips does not affect the result.

XorApplies a bitwise logical exclusive OR operation between the RGB channel values of the corresponding pixels of the two source clips, and assigns the result to the channels of the corresponding pixels in the generated clip.

The order in which you select the source clips does not affect the result.

To use logical operations:

  1. In the Processing menu, click Logic Ops.

    The Logical Operations box appears.

    Show small imageShow large image

    (a) Layer Selection box  (b) Logical Operations box  (c) Transparency field  

  2. Select the mode you want to use from the Logical Operations box.
  3. Select an option from the Layer Selection box. You can select either a Front and a Back clip, or a Front, Back, and Matte clip.
  4. Specify the transparency value.

    Use the default value of 0.0% to combine your clips completely. Using any value above zero results in an effect in which the specified layers are combined, but you can see though the combined clips to the original Back clip.

  5. Select the source clips to be used for the operation. The order in which clips are selected affects the outcome of some operations.
    NoteIf you want to use clips of different resolutions, resize them according to the common destination resolution. See Resize.
  6. Select the destination reel.

    The generated clip appears on the destination reel.