pixrect — extract a rectangle from a color pix file
Pixrect extracts a rectangular region from a color pix(5) format file. The program prompts for the area to extract in x and y pixels, the scanline length of the input file in pixels, and the origin in the input file from which to extract. First quadrant coordinates and file storage formats are used.
By default pixels of size three bytes are assumed as in the
pix(5)
format. However, the
-#
bytes
flag can be used to specify some other pixel size, where
bytes
is the number of bytes per pixel. Thus this program
can be used to extract rectangles of other data types, such as
an array of floats, etc.