15bd8deadSopenharmony_ciName
25bd8deadSopenharmony_ci
35bd8deadSopenharmony_ci    HP_image_transform
45bd8deadSopenharmony_ci
55bd8deadSopenharmony_ciName Strings
65bd8deadSopenharmony_ci
75bd8deadSopenharmony_ci    GL_HP_image_transform
85bd8deadSopenharmony_ci
95bd8deadSopenharmony_ciVersion
105bd8deadSopenharmony_ci
115bd8deadSopenharmony_ci    $Date: 1996/04/22 23:23:13 $ $Revision: 1.1 $
125bd8deadSopenharmony_ci
135bd8deadSopenharmony_ciNumber
145bd8deadSopenharmony_ci
155bd8deadSopenharmony_ci    66
165bd8deadSopenharmony_ci
175bd8deadSopenharmony_ciDependencies
185bd8deadSopenharmony_ci
195bd8deadSopenharmony_ci    EXT_texture is required
205bd8deadSopenharmony_ci    EXT_convolution affects the definition of this extension
215bd8deadSopenharmony_ci    SGI_color_table is required
225bd8deadSopenharmony_ci
235bd8deadSopenharmony_ciOverview
245bd8deadSopenharmony_ci
255bd8deadSopenharmony_ci    This extension provides support for scaling, rotation, and translation
265bd8deadSopenharmony_ci    of two-dimensional pixel rectangles at a fixed location in the pixel
275bd8deadSopenharmony_ci    transfer process.  The 2D image transformation attributes are specified
285bd8deadSopenharmony_ci    as individual values so that that implementations may easily detect
295bd8deadSopenharmony_ci    scaling and rotation values that lend themselves to optimization.  2D
305bd8deadSopenharmony_ci    image transformation occurs immediately after the post-convolution color
315bd8deadSopenharmony_ci    table stage of the pixel pipeline.  This extension also defines a color
325bd8deadSopenharmony_ci    table that is applied immediately after the image transformation operation.
335bd8deadSopenharmony_ci
345bd8deadSopenharmony_ciNew Procedures and Functions
355bd8deadSopenharmony_ci
365bd8deadSopenharmony_ci    void ImageTransformParameteriHP(enum target,
375bd8deadSopenharmony_ci				    enum pname,
385bd8deadSopenharmony_ci				    const int param)
395bd8deadSopenharmony_ci
405bd8deadSopenharmony_ci    void ImageTransformParameterfHP(enum target,
415bd8deadSopenharmony_ci				    enum pname,
425bd8deadSopenharmony_ci				    const float param)
435bd8deadSopenharmony_ci
445bd8deadSopenharmony_ci    void ImageTransformParameterivHP(enum target,
455bd8deadSopenharmony_ci				     enum pname,
465bd8deadSopenharmony_ci				     const int* params)
475bd8deadSopenharmony_ci
485bd8deadSopenharmony_ci    void ImageTransformParameterfvHP(enum target,
495bd8deadSopenharmony_ci				     enum pname,
505bd8deadSopenharmony_ci				     const float* params)
515bd8deadSopenharmony_ci
525bd8deadSopenharmony_ci    These routines are used to set image transformation attributes.
535bd8deadSopenharmony_ci    The only allowable value for <target> at this time is
545bd8deadSopenharmony_ci    IMAGE_TRANSFORM_2D_HP.  Allowable values for <pname> include:
555bd8deadSopenharmony_ci    IMAGE_SCALE_X_HP, IMAGE_SCALE_Y_HP, IMAGE_ROTATE_ANGLE_HP,
565bd8deadSopenharmony_ci    IMAGE_ROTATE_ORIGIN_X_HP, IMAGE_ROTATE_ORIGIN_Y_HP,
575bd8deadSopenharmony_ci    IMAGE_TRANSLATE_X_HP, IMAGE_TRANSLATE_Y_HP, IMAGE_MAG_FILTER_HP,
585bd8deadSopenharmony_ci    IMAGE_MIN_FILTER_HP, and IMAGE_CUBIC_WEIGHT_HP.
595bd8deadSopenharmony_ci
605bd8deadSopenharmony_ci    void GetImageTransformParameterivHP(enum target,
615bd8deadSopenharmony_ci				        enum pname,
625bd8deadSopenharmony_ci				        const int* params)
635bd8deadSopenharmony_ci
645bd8deadSopenharmony_ci    void GetImageTransformParameterfvHP(enum target,
655bd8deadSopenharmony_ci				        enum pname,
665bd8deadSopenharmony_ci				        const float* params)
675bd8deadSopenharmony_ci
685bd8deadSopenharmony_ci    These routines are used to query image transformation attributes.
695bd8deadSopenharmony_ci    The only allowable value for <target> at this time is
705bd8deadSopenharmony_ci    IMAGE_TRANSFORM_2D_HP.  Allowable values for <pname> include:
715bd8deadSopenharmony_ci    IMAGE_SCALE_X_HP, IMAGE_SCALE_Y_HP, IMAGE_ROTATE_ANGLE_HP,
725bd8deadSopenharmony_ci    IMAGE_ROTATE_ORIGIN_X_HP, IMAGE_ROTATE_ORIGIN_Y_HP,
735bd8deadSopenharmony_ci    IMAGE_TRANSLATE_X_HP, IMAGE_TRANSLATE_Y_HP, IMAGE_MAG_FILTER_HP,
745bd8deadSopenharmony_ci    IMAGE_MIN_FILTER_HP, and IMAGE_CUBIC_WEIGHT_HP.
755bd8deadSopenharmony_ci
765bd8deadSopenharmony_ciNew Tokens
775bd8deadSopenharmony_ci
785bd8deadSopenharmony_ci    Accepted by the <pname> parameter of ImageTransformParameteri,
795bd8deadSopenharmony_ci    ImageTransformParameterf, ImageTransformParameteriv,
805bd8deadSopenharmony_ci    ImageTransformParameterfv, GetImageTransformParameteriv and
815bd8deadSopenharmony_ci    GetImageTransformParameterfv:
825bd8deadSopenharmony_ci
835bd8deadSopenharmony_ci	IMAGE_SCALE_X_HP
845bd8deadSopenharmony_ci	IMAGE_SCALE_Y_HP
855bd8deadSopenharmony_ci	IMAGE_TRANSLATE_X_HP
865bd8deadSopenharmony_ci	IMAGE_TRANSLATE_Y_HP
875bd8deadSopenharmony_ci	IMAGE_ROTATE_ANGLE_HP
885bd8deadSopenharmony_ci	IMAGE_ROTATE_ORIGIN_X_HP
895bd8deadSopenharmony_ci	IMAGE_ROTATE_ORIGIN_Y_HP
905bd8deadSopenharmony_ci	IMAGE_MAG_FILTER_HP
915bd8deadSopenharmony_ci	IMAGE_MIN_FILTER_HP
925bd8deadSopenharmony_ci    	IMAGE_CUBIC_WEIGHT_HP
935bd8deadSopenharmony_ci
945bd8deadSopenharmony_ci    Accepted by the <params> parameter of ImageTransformParameteriHP,
955bd8deadSopenharmony_ci    ImageTransformParameterfHP, ImageTransformParameterivHP, and
965bd8deadSopenharmony_ci    ImageTransformParameterfvHP when <pname> is IMAGE_MAG_FILTER_HP
975bd8deadSopenharmony_ci    or IMAGE_MIN_FILTER_HP:
985bd8deadSopenharmony_ci
995bd8deadSopenharmony_ci	CUBIC_HP
1005bd8deadSopenharmony_ci
1015bd8deadSopenharmony_ci    Accepted by the <params> parameter of ImageTransformParameteriHP,
1025bd8deadSopenharmony_ci    ImageTransformParameterfHP, ImageTransformParameterivHP, and
1035bd8deadSopenharmony_ci    ImageTransformParameterfvHP when <pname> is IMAGE_MIN_FILTER_HP:
1045bd8deadSopenharmony_ci
1055bd8deadSopenharmony_ci	AVERAGE_HP
1065bd8deadSopenharmony_ci
1075bd8deadSopenharmony_ci    Accepted by the <cap> parameter of Enable, Disable, and IsEnabled,
1085bd8deadSopenharmony_ci    and by the <target> parameter of ImageTransformParameterivHP,
1095bd8deadSopenharmony_ci    ImageTransformParameterfvHP, GetImageTransformParameterivHP,
1105bd8deadSopenharmony_ci    and GetImageTransformParameterfvHP:
1115bd8deadSopenharmony_ci
1125bd8deadSopenharmony_ci	IMAGE_TRANSFORM_2D_HP
1135bd8deadSopenharmony_ci
1145bd8deadSopenharmony_ci    Accepted by the <cap> parameter of Enable, Disable, and IsEnabled, and
1155bd8deadSopenharmony_ci    by the <target> parameter of ColorTableSGI, ColorTableParameterivSGI,
1165bd8deadSopenharmony_ci    ColorTableParameterfvSGI, GetColorTableSGI, GetColorTableParameterivSGI,
1175bd8deadSopenharmony_ci    and GetColorTableParameterfvSGI:
1185bd8deadSopenharmony_ci
1195bd8deadSopenharmony_ci	POST_IMAGE_TRANSFORM_COLOR_TABLE_HP
1205bd8deadSopenharmony_ci
1215bd8deadSopenharmony_ci    Accepted by the <target> parameter of ColorTableSGI,
1225bd8deadSopenharmony_ci    GetColorTableParameterivSGI, and GetColorTableParameterfvSGI:
1235bd8deadSopenharmony_ci
1245bd8deadSopenharmony_ci	PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE_HP
1255bd8deadSopenharmony_ci
1265bd8deadSopenharmony_ciAdditions to Chapter 2 of the 1.0 Specification (OpenGL Operation)
1275bd8deadSopenharmony_ci
1285bd8deadSopenharmony_ci    None
1295bd8deadSopenharmony_ci
1305bd8deadSopenharmony_ciAdditions to Chapter 3 of the 1.0 Specification (Rasterization)
1315bd8deadSopenharmony_ci
1325bd8deadSopenharmony_ci    The specification of two-dimensional image transformation operators
1335bd8deadSopenharmony_ci    is added to the GL specification in Section 3.6.2, "Pixel Transfer
1345bd8deadSopenharmony_ci    Modes."  2D image transformation operators are defined by calling
1355bd8deadSopenharmony_ci    ImageTransformParameteriHP, ImageTransformParameterfHP,
1365bd8deadSopenharmony_ci    ImageTransformParameterivHP, or ImageTransformParameterfvHP with
1375bd8deadSopenharmony_ci    <target> set to IMAGE_TRANSFORM_2D_HP.  Parameter values
1385bd8deadSopenharmony_ci    IMAGE_SCALE_X_HP and IMAGE_SCALE_Y_HP establish the scaling factors.
1395bd8deadSopenharmony_ci    IMAGE_TRANSLATE_X_HP and IMAGE_TRANSLATE_Y_HP set the translation
1405bd8deadSopenharmony_ci    factors.  IMAGE_ROTATE_ANGLE_HP sets the rotation angle to be
1415bd8deadSopenharmony_ci    used, and IMAGE_ROTATE_ORIGIN_X_HP and IMAGE_ROTATE_ORIGIN_Y_HP specify
1425bd8deadSopenharmony_ci    the point about which the image is to be scaled and rotated.  If the
1435bd8deadSopenharmony_ci    specified angle is positive, the rotation will be counterclockwise
1445bd8deadSopenharmony_ci    about the specified rotation origin.  If the specified angle is
1455bd8deadSopenharmony_ci    negative, the rotation will be clockwise about the origin.  All
1465bd8deadSopenharmony_ci    of these parameters (scale, rotation, translation, rotation origin)
1475bd8deadSopenharmony_ci    are specified in terms of the input image's coordinates.
1485bd8deadSopenharmony_ci    IMAGE_MAG_FILTER_HP establishes the resampling technique that is to be
1495bd8deadSopenharmony_ci    used after the other image transformation operators have been applied
1505bd8deadSopenharmony_ci    if the image is deemed to have been magnified.  IMAGE_MIN_FILTER_HP
1515bd8deadSopenharmony_ci    defines the resampling technique that is to be applied if the image
1525bd8deadSopenharmony_ci    is minified by the scaling factors.  IMAGE_CUBIC_WEIGHT_HP defines
1535bd8deadSopenharmony_ci    the cubic weighting coefficient that is to be used whenever the
1545bd8deadSopenharmony_ci    resampling technique is set to CUBIC_HP.
1555bd8deadSopenharmony_ci
1565bd8deadSopenharmony_ci    The operations defined by the image transformation operation are
1575bd8deadSopenharmony_ci    added to the GL specification in Section 3.6.3, "Rasterization of
1585bd8deadSopenharmony_ci    Pixel Rectangles," immediately following the operations described in
1595bd8deadSopenharmony_ci    the EXT_convolution extension and the post convolution color table
1605bd8deadSopenharmony_ci    operation that is described in the SGI_color_table extension.  Image
1615bd8deadSopenharmony_ci    transformation is defined only for pixel rectangles that contain RGBA
1625bd8deadSopenharmony_ci    components or depth components at this stage of the pixel processing
1635bd8deadSopenharmony_ci    pipeline (color index values may have been converted to RGBA by a
1645bd8deadSopenharmony_ci    previous stage).  Image transformation is not applied to color index
1655bd8deadSopenharmony_ci    or stencil index pixel data.
1665bd8deadSopenharmony_ci
1675bd8deadSopenharmony_ci    When enabled, the image transformation operation uses the current set
1685bd8deadSopenharmony_ci    of image transformation parameters to compute a new window coordinate
1695bd8deadSopenharmony_ci    for each incoming pixel.  Although image transformation parameters
1705bd8deadSopenharmony_ci    are specified separately, the scaling, rotation, and translation
1715bd8deadSopenharmony_ci    operations are all applied simultaneously (as if the transformation
1725bd8deadSopenharmony_ci    was encoded in a matrix and the resulting matrix was applied to each
1735bd8deadSopenharmony_ci    incoming pixel coordinate).  In the case of 2D image transformation,
1745bd8deadSopenharmony_ci    if (Rx,Ry) specifies the rotation origin, the effect of applying the
1755bd8deadSopenharmony_ci    2D image transformation operators can be defined as follows.  First,
1765bd8deadSopenharmony_ci    the image is translated by -Rx in the x direction and -Ry in the y
1775bd8deadSopenharmony_ci    direction so that its rotation origin is at the origin of the 2D
1785bd8deadSopenharmony_ci    coordinate system.  Second, the x and y scaling factors are
1795bd8deadSopenharmony_ci    applied, causing the image to be scaled as specified in x and y.
1805bd8deadSopenharmony_ci    Third, the rotation angle is applied, causing the image to be rotated
1815bd8deadSopenharmony_ci    about the origin by the specified angle.  Next, the image is translated
1825bd8deadSopenharmony_ci    by Rx in the x direction and Ry in the y direction.  Finally, the
1835bd8deadSopenharmony_ci    scaled and rotated image is translated by the specified translation
1845bd8deadSopenharmony_ci    factors.  Resampling occurs after the scaling/rotation/translation
1855bd8deadSopenharmony_ci    operations have been applied.
1865bd8deadSopenharmony_ci
1875bd8deadSopenharmony_ci    The RGBA or depth value for each location is left unmodified by the image
1885bd8deadSopenharmony_ci    transformation.  Since multiple input pixels can be mapped into a single
1895bd8deadSopenharmony_ci    output pixel (minification of input image), or since output pixels might
1905bd8deadSopenharmony_ci    not have any input pixels mapped to them (magnification of input image),
1915bd8deadSopenharmony_ci    some method of resampling is required.  The resampling method to be
1925bd8deadSopenharmony_ci    used when the image is magnified is specified by calling
1935bd8deadSopenharmony_ci    ImageTransformParameteri, ImageTransformParameterf,
1945bd8deadSopenharmony_ci    ImageTransformParameteriv, or ImageTransformParameterfv with <pname>
1955bd8deadSopenharmony_ci    set to IMAGE_MAG_FILTER_HP and <params> set to NEAREST, LINEAR, or CUBIC_HP.
1965bd8deadSopenharmony_ci    The resampling method to be used when the image is minified is specified
1975bd8deadSopenharmony_ci    by calling ImageTransformParameteri, ImageTransformParameterf,
1985bd8deadSopenharmony_ci    ImageTransformParameteriv, or ImageTransformParameterfv with <pname>
1995bd8deadSopenharmony_ci    set to IMAGE_MIN_FILTER_HP and <params> set to NEAREST, LINEAR, CUBIC_HP,
2005bd8deadSopenharmony_ci    or AVERAGE_HP.  If the resampling method is NEAREST, each output pixel will
2015bd8deadSopenharmony_ci    have the value of the input pixel whose transformed coordinate value is
2025bd8deadSopenharmony_ci    nearest (in Manhattan distance).  If the resampling method is LINEAR, each
2035bd8deadSopenharmony_ci    output pixel will have a value that is the weighted average of the four input
2045bd8deadSopenharmony_ci    pixels whose transformed coordinate values are nearest.
2055bd8deadSopenharmony_ci    
2065bd8deadSopenharmony_ci    If the resampling method is CUBIC_HP, each output pixel will have a value
2075bd8deadSopenharmony_ci    that is affected by the 16 input pixels whose transformed coordinate
2085bd8deadSopenharmony_ci    values are nearest.  The 16 input pixels will be used to perform a cubic
2095bd8deadSopenharmony_ci    spline interpolation to determine the value of the output pixel.  The
2105bd8deadSopenharmony_ci    cubic weight factor is a floating point value that is applied to the
2115bd8deadSopenharmony_ci    cubic interpolation in the manner described in "Digital Image Warping"
2125bd8deadSopenharmony_ci    by George Wolberg (IEEE Computer Society Press, ISBN 0-8186-8944-7).
2135bd8deadSopenharmony_ci    Visually pleasing cubic weighting values are typically in the
2145bd8deadSopenharmony_ci    range [-1,0].  The values -1.0 and -0.5 are most commonly used.
2155bd8deadSopenharmony_ci    For the purpose of performing bicubic interpolation along the outer
2165bd8deadSopenharmony_ci    edge of the image, the outermost one pixel edge of the image is
2175bd8deadSopenharmony_ci    duplicated prior to performing the interpolation along the edges.
2185bd8deadSopenharmony_ci
2195bd8deadSopenharmony_ci    If the resampling method is AVERAGE_HP, the values of all of the input
2205bd8deadSopenharmony_ci    pixels that contribute to the final output pixel will be averaged to
2215bd8deadSopenharmony_ci    determine the final output pixel value.
2225bd8deadSopenharmony_ci
2235bd8deadSopenharmony_ci    The operation of the POST_IMAGE_TRANSFORM_COLOR_TABLE is added to the GL
2245bd8deadSopenharmony_ci    Specification in section 3.6.3, "Rasterization of Pixel Rectangles".
2255bd8deadSopenharmony_ci    This color table behaves in the manner described in the SGI_color_table
2265bd8deadSopenharmony_ci    extension, and it is located immediately after the image transformation
2275bd8deadSopenharmony_ci    operation.  This color table can be enabled or disabled separately from
2285bd8deadSopenharmony_ci    the image transformation operation by calling Enable or Disable with
2295bd8deadSopenharmony_ci    POST_IMAGE_TRANSFORM_COLOR_TABLE.  It can be modified using the procedures
2305bd8deadSopenharmony_ci    defined in the SGI_color_table extension.  The proxy version of this table
2315bd8deadSopenharmony_ci    can be set or queried by using a target value of
2325bd8deadSopenharmony_ci    PROXY_POST_IMAGE_TRANSFORM_COLOR_TABLE.
2335bd8deadSopenharmony_ci
2345bd8deadSopenharmony_ciAdditions to Chapter 4 of the 1.0 Specification (Per-Fragment Operations
2355bd8deadSopenharmony_ciand the Frame Buffer)
2365bd8deadSopenharmony_ci
2375bd8deadSopenharmony_ci    The operation of image transformation during pixel copy and query
2385bd8deadSopenharmony_ci    operations is identical to the operation during pixel drawing and
2395bd8deadSopenharmony_ci    texture image definition.  The image transformation operation occurs
2405bd8deadSopenharmony_ci    immediately after the operations described by EXT_convolution and
2415bd8deadSopenharmony_ci    the post-convolution color table described by SGI_color_table, which
2425bd8deadSopenharmony_ci    follow section 4.3.2 (Reading Pixels) of the GL Specification.
2435bd8deadSopenharmony_ci
2445bd8deadSopenharmony_ciAdditions to Chapter 5 of the 1.0 Specification (Special Functions)
2455bd8deadSopenharmony_ci
2465bd8deadSopenharmony_ci    GetImageTransformParameterivHP, and GetImageTransformParameterfvHP
2475bd8deadSopenharmony_ci    are not included in display lists, but are instead executed immediately.
2485bd8deadSopenharmony_ci
2495bd8deadSopenharmony_ciAdditions to Chapter 6 of the 1.0 Specification (State and State Requests)
2505bd8deadSopenharmony_ci
2515bd8deadSopenharmony_ci    Integer and floating point query functions GetImageTransformParameterivHP
2525bd8deadSopenharmony_ci    and GetImageTransformParameterfvHP are provided.  <target> must be
2535bd8deadSopenharmony_ci    IMAGE_TRANSFORM_2D_HP.  <pname> is one of IMAGE_SCALE_X_HP,
2545bd8deadSopenharmony_ci    IMAGE_SCALE_Y_HP, IMAGE_TRANSLATE_X_HP, IMAGE_TRANSLATE_Y_HP,
2555bd8deadSopenharmony_ci    IMAGE_ROTATE_ANGLE_HP, IMAGE_ROTATE_ORIGIN_X_HP,
2565bd8deadSopenharmony_ci    IMAGE_ROTATE_ORIGIN_Y_HP, IMAGE_MAG_FILTER_HP, IMAGE_MIN_FILTER_HP,
2575bd8deadSopenharmony_ci    or IMAGE_CUBIC_WEIGHT_HP.  The value of the specified parameter is
2585bd8deadSopenharmony_ci    returned in <params>.
2595bd8deadSopenharmony_ci
2605bd8deadSopenharmony_ciAdditions to the GLX Specification
2615bd8deadSopenharmony_ci    
2625bd8deadSopenharmony_ci    None
2635bd8deadSopenharmony_ci
2645bd8deadSopenharmony_ciDependencies on EXT_texture
2655bd8deadSopenharmony_ci
2665bd8deadSopenharmony_ci    EXT_texture is required.  This extension builds on the notion of
2675bd8deadSopenharmony_ci    internal image format, which is defined by EXT_texture.
2685bd8deadSopenharmony_ci
2695bd8deadSopenharmony_ciDependencies on EXT_convolution
2705bd8deadSopenharmony_ci
2715bd8deadSopenharmony_ci    None, except that image transformation follows the convolution
2725bd8deadSopenharmony_ci    operation (and its scale and bias).  If the post-convolution color
2735bd8deadSopenharmony_ci    table is supported, the image transformation operation will occur
2745bd8deadSopenharmony_ci    immediately after the post-convolution color table operation.  If
2755bd8deadSopenharmony_ci    convolution is not supported, the location with respect to all other
2765bd8deadSopenharmony_ci    pixel operations remains the same.
2775bd8deadSopenharmony_ci
2785bd8deadSopenharmony_ciDependencies on SGI_color_table
2795bd8deadSopenharmony_ci
2805bd8deadSopenharmony_ci    SGI_color_table is required.  This extension builds on the notion of
2815bd8deadSopenharmony_ci    color lookup tables at various locations in the pixel processing pipeline.
2825bd8deadSopenharmony_ci    This extension adds another table to the list specified by SGI_color_table.
2835bd8deadSopenharmony_ci    This new table can be manipulated using the procedures defined by
2845bd8deadSopenharmony_ci    SGI_color_table.
2855bd8deadSopenharmony_ci
2865bd8deadSopenharmony_ciErrors
2875bd8deadSopenharmony_ci
2885bd8deadSopenharmony_ci    INVALID_ENUM is generated if ImageTransformParameteriHP,
2895bd8deadSopenharmony_ci    ImageTransformParameterfHP, ImageTransformParameterivHP,
2905bd8deadSopenharmony_ci    ImageTransformParameterfvHP, GetImageTransformParameterivHP,
2915bd8deadSopenharmony_ci    or GetImageTransformParameterfvHP is called with <target> set to
2925bd8deadSopenharmony_ci    a value other than IMAGE_TRANSFORM_2D_HP.
2935bd8deadSopenharmony_ci
2945bd8deadSopenharmony_ci    INVALID_ENUM is generated if GetImageTransformParameterivHP or
2955bd8deadSopenharmony_ci    GetImageTransformParameterfvHP is called with <pname> set to
2965bd8deadSopenharmony_ci    IMAGE_MAG_FILTER_HP and <params> is not one of NEAREST, LINEAR,
2975bd8deadSopenharmony_ci    or CUBIC_HP.
2985bd8deadSopenharmony_ci
2995bd8deadSopenharmony_ci    INVALID_ENUM is generated if GetImageTransformParameterivHP or
3005bd8deadSopenharmony_ci    GetImageTransformParameterfvHP is called with <pname> set to
3015bd8deadSopenharmony_ci    IMAGE_MIN_FILTER_HP and <params> is not one of NEAREST, LINEAR,
3025bd8deadSopenharmony_ci    CUBIC_HP, or AVERAGE_HP.
3035bd8deadSopenharmony_ci
3045bd8deadSopenharmony_ci    INVALID_VALUE is generated if ImageTransformParameteriHP,
3055bd8deadSopenharmony_ci    ImageTransformParameterfHP, ImageTransformParameterivHP, or
3065bd8deadSopenharmony_ci    ImageTransformParameterfvHP is called with <pname> set to
3075bd8deadSopenharmony_ci    IMAGE_CUBIC_WEIGHT_HP and <params> is a value outside of
3085bd8deadSopenharmony_ci    the range [0,1].
3095bd8deadSopenharmony_ci
3105bd8deadSopenharmony_ci    INVALID_OPERATION is generated if ImageTransformParameteriHP,
3115bd8deadSopenharmony_ci    ImageTransformParameterfHP, ImageTransformParameterivHP,
3125bd8deadSopenharmony_ci    ImageTransformParameterfvHP, GetImageTransformParameterivHP,
3135bd8deadSopenharmony_ci    or GetImageTransformParameterfvHP is called between execution of
3145bd8deadSopenharmony_ci    Begin and the corresponding execution of End.
3155bd8deadSopenharmony_ci
3165bd8deadSopenharmony_ciNew State
3175bd8deadSopenharmony_ci										Initial
3185bd8deadSopenharmony_ci    Get Value					Get Command		Type	Value 	  Attrib
3195bd8deadSopenharmony_ci    ---------					-----------		----	-------   ------
3205bd8deadSopenharmony_ci    IMAGE_TRANSFORM_2D_HP		IsEnabled			 B	   False  pixel/enable
3215bd8deadSopenharmony_ci    IMAGE_SCALE_X_HP			GetImageTransformParameterf	 R	   1 	  pixel
3225bd8deadSopenharmony_ci    IMAGE_SCALE_Y_HP			GetImageTransformParameterf	 R	   1 	  pixel
3235bd8deadSopenharmony_ci    IMAGE_TRANSLATE_X_HP		GetImageTransformParameterf	 R	   0 	  pixel
3245bd8deadSopenharmony_ci    IMAGE_TRANSLATE_Y_HP		GetImageTransformParameterf	 R	   0 	  pixel
3255bd8deadSopenharmony_ci    IMAGE_ROTATE_ANGLE_HP		GetImageTransformParameterf	 R	   0 	  pixel
3265bd8deadSopenharmony_ci    IMAGE_ROTATE_ORIGIN_X_HP		GetImageTransformParameterf	 R	   0 	  pixel
3275bd8deadSopenharmony_ci    IMAGE_ROTATE_ORIGIN_Y_HP		GetImageTransformParameterf	 R	   0 	  pixel
3285bd8deadSopenharmony_ci    IMAGE_MAG_FILTER_HP			GetImageTransformParameteri	 Z3	NEAREST   pixel
3295bd8deadSopenharmony_ci    IMAGE_MIN_FILTER_HP			GetImageTransformParameteri	 Z4	NEAREST   pixel
3305bd8deadSopenharmony_ci    IMAGE_CUBIC_WEIGHT_HP		GetImageTransformParameterf	 R	   -1 	  pixel
3315bd8deadSopenharmony_ci    POST_IMAGE_TRANSFORM_COLOR_TABLE_HP	IsEnabled		  	 B	 False	  pixel/enable
3325bd8deadSopenharmony_ci    POST_IMAGE_TRANSFORM_COLOR_TABLE_HP	GetColorTableHP		       3 x I	 empty	    -
3335bd8deadSopenharmony_ci
3345bd8deadSopenharmony_ciNew Implementation Dependent State
3355bd8deadSopenharmony_ci
3365bd8deadSopenharmony_ci    None
3375bd8deadSopenharmony_ci
3385bd8deadSopenharmony_ciIssues
3395bd8deadSopenharmony_ci
3405bd8deadSopenharmony_ci    What is the behavior of ReadPixels when the image transformation
3415bd8deadSopenharmony_ci    is enabled?  One suggestion is to assume that the specified width
3425bd8deadSopenharmony_ci    and height of the region being read are used to define the size
3435bd8deadSopenharmony_ci    of the 2D array in host memory in which the pixel values are to
3445bd8deadSopenharmony_ci    be written.  Any pixels that would be written outside of this region
3455bd8deadSopenharmony_ci    would be clipped.  Why would anyone want to rotate/scale during
3465bd8deadSopenharmony_ci    a readback operation anyway?  Another suggestion is that image
3475bd8deadSopenharmony_ci    transformation is ignored during readback, but this makes it
3485bd8deadSopenharmony_ci    different than the other pixel transfer operations.
3495bd8deadSopenharmony_ci
3505bd8deadSopenharmony_ciNotes
3515bd8deadSopenharmony_ci
3525bd8deadSopenharmony_ci    I originally wrote this extension to utilize an image transformation
3535bd8deadSopenharmony_ci    matrix that worked the same way the other OpenGL matrices worked.
3545bd8deadSopenharmony_ci    However, we found that we could not easily extract the rotation and
3555bd8deadSopenharmony_ci    scaling information and use it to select optimized software routines
3565bd8deadSopenharmony_ci    for special cases like integer zoom and 90 degree rotations.
3575bd8deadSopenharmony_ci    Consequently, I've reverted back to specifying the image transformation
3585bd8deadSopenharmony_ci    parameters individually and the image transformation operation
3595bd8deadSopenharmony_ci    in a more rigid way.
3605bd8deadSopenharmony_ci
3615bd8deadSopenharmony_ci    I would rather have separate state setting calls for each of the
3625bd8deadSopenharmony_ci    2D image transformation parameters.  However, SGI's convolution,
3635bd8deadSopenharmony_ci    color table, and histogram extension all use FooParameter{i,f}v calls
3645bd8deadSopenharmony_ci    to set the state.  I've mimicked their API for three reasons:
3655bd8deadSopenharmony_ci	1. For consistency with those extensions
3665bd8deadSopenharmony_ci	2. To maximize the likelihood of industry acceptance
3675bd8deadSopenharmony_ci	   of this extension
3685bd8deadSopenharmony_ci	3. To allow for the possibility of 1D and 3D image
3695bd8deadSopenharmony_ci	   transforms at a future time.
3705bd8deadSopenharmony_ci
3715bd8deadSopenharmony_ci    I have not excluded the ability to scale, rotate, and translate
3725bd8deadSopenharmony_ci    depth component values.  I thought that image transformation might
3735bd8deadSopenharmony_ci    be useful when the <format> was DEPTH_COMPONENT (i.e., reading or writing
3745bd8deadSopenharmony_ci    depth buffer values).  In this case, the "image" will have x and y values
3755bd8deadSopenharmony_ci    that define the pixel locations, and depth (z) values instead of color
3765bd8deadSopenharmony_ci    values.  The depth values will end up being treated as a single channel
3775bd8deadSopenharmony_ci    image.  This capability might be necessary if you have a depth buffer
3785bd8deadSopenharmony_ci    associated with an image that you want to remain registered as it is
3795bd8deadSopenharmony_ci    stored in the frame buffer.
380