#include "worgen.h"
FUNCTION c_pxdiv (ns, in1, in2, out, scale, offset, dtype, errval)
long *ns; unsigned char *in1; unsigned char *in2; unsigned char *out; float *scale; float *offset; long *dtype; long *errval;
The number of the samples to be processed.
An array of pixel values to be divided (numerator).
An array of divisor pixel values (denominator).
An array created by dividing, scaling, and offsetting the two input arrays.
out = (in1 / in2) x scale + offset
The scale factor to be applied after division.
The offset to be applied after division.
An integer value that represents the type of data of the input and output arrays. Legal values include:
= EBYTE(1): unsigned byte data = EWORD(2): signed two byte data = ELONG(3): signed four byte dat = EREAL(4): four byte floating point data
An integer value to be placed in the output array at all locations where a divide by zero was attempted.
The c_pxdiv() call is used to create an output array
c_pxdiv() returns
RETURN VALUE
E_SUCC --> successful completion
TOOBIG --> exceeded upper limit of data type
TOOSMALL--> exceeded lower limit of data type
TYPERR --> invalid data type specified
DIVZERO --> divide by zero