Operator OR

The operator OR performs a bitwise logical OR operation. Each output bit is set to a logical "1" if any of the corresponding bits is "1", otherwise the output is "0". The number of input links has to be selected at the instantiation of the module.

Thus the output bit i of n inputs is

I/O Properties

Property Value
Operator Type O
Input Links I0, data input
I1..In-1, data input
Output Link O, data output

Supported Link Format

Link Parameter Input Link I0 Input Link I1..In-1 Output Link O
Bit Width [1, 64]1 as I as I
Arithmetic {unsigned, signed} as I as I
Parallelism any as I as I
Kernel Columns any as I as I
Kernel Rows any as I as I
Img Protocol {VALT_IMAGE2D, VALT_LINE1D, VALT_PIXEL0D, VALT_SIGNAL} as I as I
Color Format any as I as I
Color Flavor any as I as I
Max. Img Width any as I as I
Max. Img Height any as I as I

1

The range of the input bit width is [1, 64] for unsigned values. For signed inputs, the range is [2, 64]. For unsigned color inputs, the range is [3, 63] and for signed color, the range is [6, 63].

Parameters

None

Examples of Use

The use of operator OR is shown in the following examples:

  • 'Hit or Miss'

    Examples - The implementation can detect four simple patterns in a binary image. For every match, the output will be set to one.

  • 'Grid Overlay Fading'

    Examples - A grid is overlayed to the input images. The grid pixel value is determined from the input pixel value.