
vmapxfer(1)                  Khoros                   vmapxfer(1)

PROGRAM
     vmapxfer - Transfers the Map from one image to another

SYNTAX
     vmapxfer

     -i1            Input Image to receive map

     -i2            input image to extract map from

     -o             output image

     [-V]           Gives the version for vmapxfer

     [-U]           Gives the usage for vmapxfer

     [-P]           Prompts for command line options

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

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

DESCRIPTION
     vmapxfer will transfer the map associated with the second
     input image (extract image), argument -i2, to the image
     associated with the first input argument -i1 (receive
     image).  This routine will replace the receive image's map
     with that from the extract image.

     The data and data type of the extract image will be com-
     pletely ignored. The data storage of the receive image must
     be either BIT, BYTE, SHORT, or LONG. Only Map Schemes
     One_Per_Band and Shared are allowed for the extract image.

     The following table describes how the map is transfered and
     the form of the resulting image.

     Receive Image     Extract Image      Resulting Image
     Map Enable        Map Enable         Map Enable
     --------------------------------------------------------
     OPTIONAL          OPTIONAL           OPTIONAL
     OPTIONAL          FORCE              OPTIONAL
     FORCE             OPTIONAL           FORCE
     FORCE             FORCE              FORCE

     Receive Image     Extract Image       Resulting Image
     Map Scheme        Map Scheme          Map Scheme
     ---------------------------------------------------------
     None             None                    INVALID
     None             1 PB                    1 PB *
     None             Shared                  1 PB or Shared **
     1 PB             None                    INVALID
     1 PB             1 PB                    1 PB *
     1 PB             Shared                  1 PB or Shared **
     Shared           None                    INVALID
     Shared           1 PB                    1 PB *
     Shared           Shared                  Shared

         1 PB = ONE_PER_BAND

       *  The number of data bands for Image 1 must
          equal the number of data bands for image 2.
          Thus, a one to one correspondance between
          the maps in image 1 and image 2.

       ** If Image 1 only contains 1 data band then
          the Map Scheme will be set to 1 PB, otherwise
          it will be set to Shared.

     This routine will prescan the data to get the min and max
     for each data band and make sure that the min and max can
     map into the map(s). If the min and max cannot map into the
     map the routine will give an error message and quit.

     If the receive image is of data type BIT, then the routine
     checks the map column size of the extract image to ensure
     that it does not exceed a value of 2.  That is, a BIT image
     can only have a map that has two entries (a value for 0 and
     1).

     If the extracting image has a map scheme of ONE_PER_BAND
     then the receiving image must have the same number of data
     bands as the extracting image, unless the receiving image
     has a map scheme of NONE and the extracting image has only 1
     band.

     The color space model for the receive image will be set to
     the color space model of the extract image.

     Map types GROUPED and CYCLE will not be supported at this
     time, since we really have not defined how these will actu-
     ally work.

REQUIRED ARGUMENTS
     -i1    type: infile
            desc: Input Image to receive map

     -i2    type: infile
            desc: input image to extract map from

     -o     type: outfile
            desc: output image

OPTIONAL ARGUMENTS
     none

EXAMPLES
     vmapxfer -i1 receive-image -i2 extract_image -o new_image

     The map will be transfered from the extract_image and
     replace the map in the receive_image. The resulting image
     will be the new_image.

SEE ALSO
     intro(1), verror(3), vgparms(3), vutils(3), lvmapxfer(3)

RESTRICTIONS
     both input images must have data storage type of BIT, BYTE,
     SHORT or LONG.

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

Khoros                    Release: 1.0                          1

