>  Docs Center  >  Libraries  >  Salvaggio  >  QUAD_TO_QUAD_PROJECTIVE_TRANSFORM
Libraries

QUAD_TO_QUAD_PROJECTIVE_TRANSFORM

QUAD_TO_QUAD_PROJECTIVE_TRANSFORM

Name


    QUAD_TO_QUAD_PROJECTIVE_TRANSFORM

Purpose


    This function will perform a quadrilateral-to-quadrilateral projective
    transform of the provided image. The transformation is defined using
    the provided quadrilateral vertices defined in a clockwise order
    beginning at the upper left-hand corner. The provided image coordinates
    are targeted to fall at the provided map coordinates.

Category


    GENERAL.

Calling Sequence


    result = QUAD_TO_QUAD_PROJECTIVE_TRANSFORM( image, $
                                                imageQuad, $
                                                mapQuad, $
                                                MAP_DIMENSIONS=mapDimensions, $
                                                BACKGROUND_VALUE=backgroundValue

Inputs


    image
      A two-dimensional or three-dimensional array containg either greyscale
      or color image data, respectively.
    imageQuad
      An 8-element vector containing the vertices of the quadilateral enclosing
      the region on the image to be transformed. The vector has the form
          [ xUL, yUL, xUR, yUR, xLR, yLR, xLL, yLL ]
    mapQuad
      An 8-element vector containing the vertices of the quadilateral enclosing
      the region on the map to be targeted. The vector has the form
          [ uUL, vUL, uUR, vUR, uLR, vLR, uLL, vLL ]

Keyword Parametrs


      MAP_DIMENSIONS
        Set this keyword to a 2-element vector containing the [width,height] of
        the targeted map region. If this is omitted, a region corresponding to
        the bounding rectangle around the quadrilateral vertices will be used.
      BACKGROUND_VALUE
        Set this keyword to the value to be placed in the transformed data
        at points that fall outside the boundaries of the provided image to be
        transformed [DEFAULT=0].
  :ERROR CHECKING:
    None.

Side Effects


    None.

Requires


    NORMH
    PROJECTIVE_MAPPING_MATRIX

Modification History


    Written by: Carl Salvaggio
    January, 2012 Original code
   

Disclaimer


    This source code is provided "as is" and without warranties as to performance
    or merchantability. The author and/or distributors of this source code may
    have made statements about this source code. Any such statements do not
    constitute warranties and shall not be relied on by the user in deciding
    whether to use this source code.
    This source code is provided without any express or implied warranties
    whatsoever. Because of the diversity of conditions and hardware under which
    this source code may be used, no warranty of fitness for a particular purpose
    is offered. The user is advised to test the source code thoroughly before
    relying on it. The user must assume the entire risk of using the source code.



© 2024 NV5 Geospatial Solutions, Inc. |  Legal
   Contact Us