1 EXTRACT Extract a subset (or surset) of a GDF file
        EXTRACT

    Extracts a subset of an input image. The output image can be larger than
    the subset; in this case the additional pixels are blanked if the output
    image  is  being  created, unmodified if it already exists.  It works on
    images of any dimensions, and any subset  of  the  input  image  can  be
    placed anywhere in the output image.

    This  task  can also be used to build a N+P dimensional image from a set
    of N dimensional ones, by initializing the output image  once  with  its
    full dimensions and then placing the (subset of the) input images at the
    appropriate place in the output image.
2 Y_NAME$
        TASK\FILE "Input file name" Y_NAME$

    This is the name of the input file.
2 X_NAME$
        TASK\FILE "Output file name" X_NAME$

    This is the name of the output file.
2 BLC$
        TASK\INTEGER "Bottom left corner" BLC$[4]

    This is the position (in pixel units) of the Bottom Left Corner  of  the
    extracted part (in the input map of course). 0 means 1.

    For  example,  if  one  wants to extract the 51x61 central pixels from a
    100x120 map, X extracted range is  [25:75]  and  Y  extracted  range  is
    [30:90]. Then the bottom left corner is: 25 30 0 0
2 TRC$
        TASK\INTEGER "Top right corner" TRC$[4]

    This is the position (in pixel units) of the Top  Right  Corner  of  the
    extracted  part  (in  the input map of course).  0 means the the current
    image dimension.

    For  example,  if  one  wants to extract the 51x61 central pixels from a
    100x120 map, X extracted range is  [25:75]  and  Y  extracted  range  is
    [30:90]. Then the top right corner is: 75 90 0 0
2 PIXEL_IN$
        TASK\INTEGER "Position of one pixel in input image" PIXEL_IN$[4]

    This is the position of one pixel in the input map.  Together  with  the
    position  of  the  same  pixel in the output map (see PIXEL_OUT$), it is
    used to align the two maps.

    For  example,  if  one  wants to extract the 51x61 central pixels from a
    100x120 map, X extracted range is  [25:75]  and  Y  extracted  range  is
    [30:90].  The  simplest  way to align the maps is to use the bottom left
    corner of the extracted region as PIXEL_IN$, in this case: 25 30 1 1

    Other choices for PIXEL_IN$ are possible if you prefer  other  reference
    positions (typically some source in the map).
2 PIXEL_OUT$
        TASK\INTEGER "Position of this pixel in output image" PIXEL_OUT$[4]

    This is the position of one pixel in the output map.  Together with  the
    position  of the same pixel in the input map (see PIXEL_IN$), it is used
    to align the two maps.

    For  example,  if  one  wants to extract the 51x61 central pixels from a
    100x120 map, X extracted range is  [25:75]  and  Y  extracted  range  is
    [30:90]. If PIXEL_IN$ is the bottom left corner of the extracted region,
    this pixel will be the absolute bottom left corner in  the  output  map,
    i.e.  PIXEL_OUT$  =  1 1 1 1. Other values of PIXEL_OUT$ would shift the
    extracted region in the output map.

    Any alignments or shifts are possible. Typically if you want  to  center
    the PIXEL_IN$ (e.g. some source) in the output map, set PIXEL_OUT$ to 50
    60 1 1
2 INITIALIZE$
        TASK\LOGICAL "Initialize output image" INITIALIZE$

    Answer .TRUE.  if you want to create/overwrite the output  map,  .FALSE.
    if you want to insert the extracted part in an existing output map.
2 X_DIM$
        TASK\INTEGER "Dimensions of output image" X_DIM$[4]

    This information is only used if you initialize the output map.   It  is
    the  total dimension of the output map.  The answer should be TRC-BLC+1,
    unless you want to allow some extra space  for  other  data.   This  can
    occur  for  example  if you are building a cube from a set of planes.  0
    means TRC-BLC+1.
2 BLANKOUT$
        TASK\LOGICAL "Initialize with blanking value" BLANKOUT$

    Should initializing be at the blanking value or not?
2 INITVAL$
        TASK\REAL "Initialization value" INITVAL$

    Initial value, if BLANKOUT$ is False.
1 ENDOFHELP







































