home *** CD-ROM | disk | FTP | other *** search
/ SGI Developer Toolbox 6.1 / SGI Developer Toolbox 6.1 - Disc 1.iso / toolbox / documents / OpenGL / opengldoc / glspec / pixel_texture.spec < prev    next >
Encoding:
Text File  |  1996-11-11  |  4.8 KB  |  136 lines

  1. Name
  2.  
  3.     SGIX_pixel_texture
  4.  
  5. Name Strings
  6.  
  7.     GL_SGIX_pixel_texture
  8.  
  9. Version
  10.  
  11.     $Date: 1996/04/02 00:08:29 $ $Revision: 1.2 $
  12.  
  13. Number
  14.  
  15.     15
  16.  
  17. Dependencies
  18.  
  19.     None
  20.  
  21. Overview
  22.  
  23.     This extension allows the color components of pixel groups to be used as
  24.     texture coordinates, effectively converting a color image into a texture
  25.     coordinate image.  Because texture mapping is essentially a
  26.     multidimensional table lookup, this conversion supports multidimensional
  27.     color lookups for images.  Such multidimensional lookups can be used to
  28.     implement very accurate color space conversions.
  29.  
  30. Issues
  31.  
  32.     *    Should LOD be supported?
  33.  
  34. New Procedures and Functions
  35.  
  36.     void PixelTexGenSGIX(enum mode);
  37.  
  38. New Tokens
  39.  
  40.     Accepted by the <pname> parameter of GetBooleanv, GetIntegerv,
  41.     GetFloatv, and GetDoublev:
  42.  
  43.     PIXEL_TEX_GEN_MODE_SGIX
  44.  
  45. Additions to Chapter 2 of the 1.0 Specification (OpenGL Operation)
  46.  
  47.     None
  48.  
  49. Additions to Chapter 3 of the 1.0 Specification (Rasterization)
  50.  
  51.     This extension modifies the "Conversion to Fragments" subsection of
  52.     section 3.6.3 (Rasterization of Pixel Rectangles) of the GL
  53.     Specification.  The paragraph beginning with "A fragment arising from a
  54.     group consisting of color data ..." is replaced by the following:
  55.  
  56.     A fragment arising from a group consisting of color index data takes on
  57.     the color index of the group; the depth and texture coordinates are
  58.     taken from the current raster position's associated data.  Likewise, a
  59.     fragment arising from a depth component takes the component's depth
  60.     value; the color and texture coordinates are given by those associated
  61.     with the current raster position.  Groups arising from DrawPixels with a
  62.     <format> of STENCIL_INDEX are treated specially and are described in
  63.     section 4.3.1.
  64.  
  65.     The treatment of fragments arising from groups consisting of RGBA color
  66.     data is determined by the PIXEL_TEX_GEN_MODE_SGIX value.  PixelTexGenSGIX
  67.     is used to set this value to one of NONE, RGB, or RGBA.  (It is NONE by
  68.     default.)  In all cases a fragment arising from a group consisting of
  69.     RGBA color data takes its depth component from the current raster
  70.     position's associated data.  The assignment of color and texture
  71.     coordinate values to such a fragment is defined by the following table:
  72.  
  73.                 PIXEL_TEX_GEN_MODE_SGIX        PIXEL_TEX_GEN_MODE_SGIX        PIXEL_TEX_GEN_MODE_SGIX
  74.     Fragment value        is NONE                is RGB                is RGBA
  75.     --------------        ----------------------        ----------------------        ----------------------
  76.     red            pixel group's red        CRP's red            CRP's red
  77.     green            pixel group's green        CRP's green            CRP's green
  78.     blue            pixel group's blue        CRP's blue            CRP's blue
  79.     alpha            pixel group's alpha        pixel group's alpha        CRP's alpha
  80.  
  81.     S texture coordinate    CRP's S texture coordinate    pixel group's red        pixel group's red
  82.     T texture coordinate    CRP's T texture coordinate    pixel group's green        pixel group's green
  83.     R texture coordinate    CRP's R texture coordinate    pixel group's blue        pixel group's blue
  84.     Q texture coordinate    CRP's Q texture coordinate    CRP's Q texture coordinate    pixel group's alpha
  85.  
  86.     Assignment of pixel group and current raster position associated
  87.     data to a fragment arising from an RGBA color pixel group.  CRP is
  88.     an abbreviation of "current raster position".  The fragment value in
  89.     the left-most column is assigned the value in the second, third, or
  90.     fourth column, depending on the PixelTexGenSGIX mode value.
  91.  
  92.     When a pixel group color component is assigned to a fragment texture
  93.     coordinate, it is as if that color component had undergone only clamping
  94.     to [0,1] during final conversion, rather than the clamping and scaling
  95.     to framebuffer resolution that is defined by the specification.  (See
  96.     the "Final Conversion" subsection that immediately precedes the
  97.     "Conversion to Fragments" subsection.)
  98.     
  99. Additions to Chapter 4 of the 1.0 Specification (Per-Fragment Operations
  100. and the Framebuffer)
  101.  
  102.     The operation of PixelTexGenSGIX during pixel copy operations is
  103.     identical to the operation during pixel drawing.  Because PixelTexGenSGIX
  104.     defines the rasterization of pixel groups, it has no effect on texture
  105.     definitions or on pixel query (ReadPixels) operations.
  106.  
  107. Additions to Chapter 5 of the 1.0 Specification (Special Functions)
  108.  
  109.     None
  110.  
  111. Additions to Chapter 6 of the 1.0 Specification (State and State Requests)
  112.  
  113.     None
  114.  
  115. Additions to the GLX Specification
  116.  
  117.     None
  118.  
  119. Errors
  120.  
  121.     INVALID_OPERATION is generated if PixelTexGenSGIX parameter <mode> is not
  122.     NONE, RGB, or RGBA.
  123.  
  124.     INVALID_OPERATION is generated if PixelTexGenSGIX is called between
  125.     execution of Begin and the corresponding execution of End.
  126.  
  127. New State
  128.  
  129.     Get Value            Get Command    Type    Initial Value    Attrib
  130.     ---------            -----------    ----    -------------    ------
  131.     PIXEL_TEX_GEN_MODE_SGIX    GetIntegerv    Z3    NONE        pixel
  132.  
  133. New Implementation Dependent State
  134.  
  135.     None
  136.