NAME
subrect - cut out subrectangle of an image
PROTOTYPE
unitptr subrect( int dx1, int dy1, int dx2, int dy2, unitptr dest)
ARGUMENTS
- int dx1
- width in pixels of source image
- int dy1
- height in pixels of source image
- int dx2
- width in pixels of subrectangle and result image
- int dy2
- height in pixels of subrectangle and result image
- unitptr dest
- host unit for newly created instance
RETURN VALUE:
- unitptr u:
- pointer to newly created unit
INTERFACE OF CREATED UNIT:
- X_in[dx1*dy1]:
- (packed input field 0) pixel values of
source image
- Y_in[2]:
- (input field 1) offset of subrect rela-
tive to lower left corner of source
image.
- X_out[dx2*dy2]:
- (packed output field 0) result image
DESCRIPTION:
Creates unit execution of which
cuts out a rectangular subregion of dx2*dy2 pixels from the
source image of dx1*dy1 pixels. The subrectangle is sent to
packed output field X_out. Input field Y_in specifies the
pixel coordinates of the lower left corner of the subrectan-
gle within image 1.
FILE:
nst_pixel
SEE ALSO:
combine, remap
FILE
/amnt/loge/users/nistaff02/nistaff/rhaschke/nst7/man/../o.linux//../foldersrc/nst_pixel.c