
vlayer(1)                    Khoros                     vlayer(1)

PROGRAM
     vlayer - Converts a multiband BIT image to a single band
     byte image.

SYNTAX
     vlayer

     -i             input image

     -o             resulting output image

     [-V]           Gives the version for vlayer

     [-U]           Gives the usage for vlayer

     [-P]           Prompts for command line options

     [-A [file1]]   Creates the answer file called vlayer.ans or
                    file1

     [-a [file1]]   Uses vlayer.ans or file1 as the answer file

DESCRIPTION
     vlayer converts a multiband BIT image to a single band byte
     image.

     The input BINARY image should have a color map associated
     with each band, have one map shared among all bands, or no
     map.  Therefore the map scheme should be ONEPERBAND, SHARED,
     or NONE. Each input image color map has a map_row_size of 3
     (corresponding to r g b), and a map_col_size of 2
     (corresponding to 0 and 1), and is of type BYTE.  The
     entries for 0 should be (r = 0, g = 0, b = 0), corresponding
     to black.  The entries for 1 should correspond to the color
     attribute assigned to that band.  A different color attri-
     bute is assigned to each band of the BINARY image,
     corresponding to some feature (ie. roads, etc.) for that
     layer.

     The output image consists of a single band BYTE image with
     an associated color map.  The output image is formed by
     replacing the band number (ie.  1, 2, 3, ...) at each loca-
     tion (ie. row and col) consisting of a 1 in the correspond-
     ing band of the input image.  That is, for each BIT = 1 of a
     particular band of the input image, the corresponding band
     number (1, 2, 3,...)  will be replaced in the output image.

     The input image must be of data storage type BIT, and have a
     map sheme of ONEPERBAND, SHARED, or NONE. The resulting out-
     put image will be of data storage type BYTE, and have a map
     scheme of ONEPERBAND, SHARED, or NONE. The color space model
     and map enable of the input image will be passed along to
     the output image.  The map of the output image will be
     adjusted in size to correspond to a map row size of the
     input image (ie. should be 3 - r g b), and a map col size
     equal to the number of bands in the input image plus one
     (this corresponds to a different color for each band includ-
     ing a color for 0).  The color for 0 is set to be r = 0, g =
     0, and b = 0 (ie. black).

REQUIRED ARGUMENTS
     -i     type: infile
            desc: input image

     -o     type: outfile
            desc: resulting output image

OPTIONAL ARGUMENTS
     none

EXAMPLES
     vlayer -i input.xv -o output.xv
     will convert the multiband BIT image input.xv to a BYTE
     image, output.xv.

SEE ALSO
     intro(1), verror(3), vgparms(3), vutils(3), lvlayer(3)
     dlg2viff(1), mapdlg(1)

RESTRICTIONS
     Will only work on BIT images with a map scheme of ONEPER-
     BAND, SHARED, or NONE.

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

Khoros                    Release: 1.0                          1

