MagnitudeLat

DESCRIPTION

MagnitudeLat computes the magnitude of Input's data values. The output lattice has the same coordinates as the input, but each data value is replaced by its magnitude. The data type is preserved.

The magnitude is normally computed as the square root of the sum of each data element squared. If the input lattice has 3 components data values and Norm Type is set to "Luminance", the lattice is interpreted as an RGB image, and the standard NTSC luminance is computed

I = 0.299*Red + 0.587*Green + 0.114*Blue
If the input lattice doesn't have 3 components, Norm Type is set to "Magnitude" and the normal magnitude is output.

INPUTS

Port: Input
Type: Lattice
The input data lattice

WIDGETS

Port: Norm Type
Type: Radio Box
Menu Item: Magnitude
Menu Item: Luminance
Selects magnitude or luminance Output

OUTPUTS

Port: Output
Type: Lattice
Constraints: 1-vector
Magnitude of the input lattice.

KNOWN PROBLEMS

No range checking is performed if "Luminance" is requested, the input data values should be in the range [0..1].

SEE ALSO

GrayScaleImg, Gradient, DisplaceLat.
[Documentation Home]
© The Numerical Algorithms Group Ltd, Oxford UK. 2000

Website Feedback

If you would like a response from NAG please provide your e-mail address below.

(If you're a human, don't change the following field)
Your first name.
CAPTCHA
This question is for testing whether you are a human visitor and to prevent automated spam submissions.
Image CAPTCHA
Enter the characters shown in the image.