VisionX V4VMATHVisionX V4
NAME

vmath − compute a primitive mathematical function of the pixels of a VisionX image

SYNOPSIS

vmath if=infile of=outfile [th=thresh] [hi=hval] [lo=lval] [bf=bval] [tf=tval] [-abs] [-log] [-exp] [-sqrt] [-mlog] [-scale] [-clip] [-d]

DESCRIPTION

Vmath performs a function or a set of functions on each pixel of the image data file. The following functions are implemented: abs,clip,scale,sqrt,log,exp, multiply by a constant and add a constant. The file created by vmath always has the same format as the input file. For all of these operations the data is converted internally to floating point format for processing. Any clipping and scaling is performed after the mathematical function has been computed. For some mathematical functions, integer or byte data will not return useful results.

OPTIONS

-abs

compute the absolute value of all pixels

-log

compute the logarithm of all pixel values

-sqrt

compute the square root of all pixel values

-exp

compute the exponential of all pixel values

-mlog

modified log function, similar to log except that input values less than zero are set to zero and values in the range 0-3 are linearly scaled.

bf=bval

The value of the parameter bval is added to all pixels.

tf=tval all pixels are multiplied by the parameter tval.

hi=hval

the high value for the pixels in the output file is set to hval. The default value for hval is 1.0 for all formats except unsigned byte (format 1) in which case the default is 255.

lo=lval

the low value for the pixels in the output file is set to loval. The default value for lval is 0.0.

-scale

set the range of the output pixels from lval to hval.

-clip

set all pixels with values higher than hval to hval and set all pixels with values less than lval to lval.

AUTHOR

A. P. Reeves