lvect2row(3)

LIBRARY ROUTINE
lvect2row - reformats data stored in vector format to a single-band file where each vector is represented as a separate row in the output file.

LIBRARY CALL
#include "vinclude.h"
int
lvect2row ( image, single_vect, row_offset, col_offset, process_dir )
struct xvimage  *image;
int             single_vect,    /* flag set to 1 if only 1 vector extracted */
                row_offset,     /* if single_vect = 1, pixel row index */
                col_offset,     /* if single_vect = 1, pixel col index */
                process_dir;    /* 0 = DSP_VECTOR, 1 = DSP_BAND */

INPUT

*image
    pointer the input/output xvimage structure

single_vect
    integer flag which, if set to 1, indicates that only on vector is to be extracted

row_offset
    integer, if single_vect is set, this defines the row position of the targeted pixel

col_offset
    integer, if single_vect is set, this defines the column position of the targeted pixel

OUTPUT

*image
    pointer to the input/output (struct xvimage)

MODIFICATIONS

Tue May 22 21:10:52 MDT 1990 Donna Koechner - updated to ghostwriter
Audit Done 05-OCT-90 Donna Koechner
Sun Feb 24 1991 Updated to work on all VFF types except BIT - Donna Koechner

DESCRIPTION
lvect2row reformats data stored in vector (multi-band) format to a single-band file where each vector is represented as a separate row in the output file. The number of rows in the resulting vector image will be the product of the original row and column sizes (ie., the total number of vectors), and the number of columns in the resulting image will be the vector dimension, or number of bands, found in the original file.

If the flag "single_vect" is set to 1, only the pixel vector defined by [row_offset][col_offset] is extracted. In this case, the output header fields "startx" and "starty" are set to col_offset and row_offset to retain position information that might be needed in later processing of the output file.

If the single_vect flag is not set, the entire data set is converted from vector format to the single-band row representation. In this case, the header field "subrow_size" in the output file is set to the original row_size value. This information can then be used for the inverse conversion, lrow2vect (not implemented yet).

SEE ALSO
vect2row(1), intro(3), vipl(3), verror(3), vutils(3)

RESTRICTIONS
Cannot operate on VFF_TYP_BIT.

AUTHOR
Donna Koechner

COPYRIGHT
Copyright 1991, University of New Mexico. All rights reserved.