Woolz Image Processing  Version 1.7.5
WlzRGBChannelRatio
Name
WlzRGBChannelRatio - computes log ratio of RGB channels in a RGBA object.
Synopsis
WlzRGBChannelRatio [-h] [-o<output object file>]
                   [-d<channel>] [-n<channel>] [-m<channel>]
                   [-N] [<input object file>]
Options
-h Help - print help message
-o Output object file name.
-d Denominator, must be a valid channel letter.
-n Numerator, must be a valid channel letter.
-m Multiplier, must be a valid channel letter.
-N Normalise the values and convert to unsigned byte.
Description
Computes log ratio of RGB channels in a RGBA object for each pixel using ratio \(r\) with

\[ r = \log(1 + \frac{n}{1 + d}). \]

or if a multiplier channel is specified

\[ r = m \log(1 + \frac{n}{1 + d}). \]

This results in an object with either float values or values normalised to the range 0-255 and converted to ubyte. Colour channels are specified by the ** letter of the colour channel strings *r*ed, *g*reen, *b*lue, *y*ellow, *m*agenta, "*c*yan, *h*ue, s*aturation, *v*alue and gr*e*y, ie r, g, b, y, m, c, h, s, v and e. No multiplier is used unless given on the command line. By default the input object is read from the standard input and the output object is written to standard the output.

Examples
# The following commad computes a new object from a RGBA object in.wlz.
# In the resulting object the pixel values are the ratio of the input
#  red and green components evaluated at each pixel. The ratio object
# is written to out.obj.
WlzRGBChannelRatio -n r -d g -o out.wlz in.wlz
File
WlzRGBChannelRatio.c
See Also
WlzRGBChanRatio(3)