home *** CD-ROM | disk | FTP | other *** search
/ SGI Developer Toolbox 6.1 / SGI Developer Toolbox 6.1 - Disc 1.iso / toolbox / documents / OpenGL / extensions / spec / blend_minmax.spec < prev    next >
Encoding:
Text File  |  1996-11-11  |  3.4 KB  |  135 lines

  1. Name
  2.  
  3.     EXT_blend_minmax
  4.  
  5. Name Strings
  6.  
  7.     GL_EXT_blend_minmax
  8.  
  9. Version
  10.  
  11.     $Date: 1995/09/30 02:30:34 $ $Revision: 1.1 $
  12.  
  13. Number
  14.  
  15.     37
  16.  
  17. Dependencies
  18.  
  19.     None
  20.  
  21. Overview
  22.  
  23.     Blending capability is extended by respecifying the entire blend
  24.     equation.  While this document defines only two new equations, the
  25.     BlendEquationEXT procedure that it defines will be used by subsequent
  26.     extensions to define additional blending equations.
  27.  
  28.     The two new equations defined by this extension produce the minimum
  29.     (or maximum) color components of the source and destination colors.
  30.     Taking the maximum is useful for applications such as maximum projection
  31.     in medical imaging.
  32.  
  33. Issues
  34.  
  35.     *    I've prefixed the ADD token with FUNC, to indicate that the blend
  36.     equation includes the parameters specified by BlendFunc.  (The min
  37.     and max equations don't.)  Is this necessary?  Is it too ugly?
  38.     Is there a better way to accomplish the same thing?
  39.     
  40. New Procedures and Functions
  41.  
  42.     void BlendEquationEXT(enum mode);
  43.  
  44. New Tokens
  45.  
  46.     Accepted by the <mode> parameter of BlendEquationEXT:
  47.  
  48.     FUNC_ADD_EXT                     0x8006
  49.     MIN_EXT                          0x8007
  50.     MAX_EXT                          0x8008
  51.  
  52.     Accepted by the <pname> parameter of GetBooleanv, GetIntegerv,
  53.     GetFloatv, and GetDoublev:
  54.  
  55.     BLEND_EQUATION_EXT               0x8009
  56.  
  57. Additions to Chapter 2 of the GL Specification (OpenGL Operation)
  58.  
  59.     None
  60.  
  61. Additions to Chapter 3 of the GL Specification (Rasterization)
  62.  
  63.     None
  64.  
  65. Additions to Chapter 4 of the GL Specification (Per-Fragment Operations
  66. and the Framebuffer)
  67.  
  68.     The GL Specification defines a single blending equation.  This
  69.     extension introduces a blend equation mode that is specified by calling
  70.     BlendEquationEXT with one of three enumerated values.  The default
  71.     value FUNC_ADD_EXT specifies that the blending equation defined in
  72.     the GL Specification be used.  This equation is
  73.  
  74.     C' = (Cs * S) + (Cd * D)
  75.  
  76.          /  1.0    C' > 1.0
  77.     C = (
  78.          \   C'    C' <= 1.0
  79.  
  80.     where Cs and Cd are the source and destination colors, and S and D are
  81.     as specified by BlendFunc.
  82.  
  83.     If BlendEquationEXT is called with <mode> set to MIN_EXT, the
  84.     blending equation becomes
  85.  
  86.     C = min (Cs, Cd)
  87.  
  88.     Finally, if BlendEquationEXT is called with <mode> set to MAX_EXT, the
  89.     blending equation becomes
  90.  
  91.     C = max (Cs, Cd)
  92.  
  93.     In all cases the blending equation is evaluated separately for each
  94.     color component.
  95.  
  96. Additions to Chapter 5 of the GL Specification (Special Functions)
  97.  
  98.     None
  99.  
  100. Additions to Chapter 6 of the GL Specification (State and State Requests)
  101.  
  102.     None
  103.  
  104. Additions to the GLX Specification
  105.  
  106.     None
  107.  
  108. GLX Protocol
  109.  
  110.     A new GL rendering command is added. The following command is sent to the 
  111.     server as part of a glXRender request:
  112.  
  113.     BlendEquationEXT
  114.             2           8               rendering command length
  115.             2           4097            rendering command opcode
  116.             4           ENUM        mode
  117.  
  118. Errors
  119.  
  120.     INVALID_ENUM is generated by BlendEquationEXT if its single parameter
  121.     is not FUNC_ADD_EXT, MIN_EXT, or MAX_EXT.
  122.  
  123.     INVALID_OPERATION is generated if BlendEquationEXT is executed between
  124.     the execution of Begin and the corresponding execution to End.
  125.  
  126. New State
  127.  
  128.     Get Value        Get Command    Type    Initial Value    Attribute
  129.     ---------        -----------    ----    -------------    ---------
  130.     BLEND_EQUATION_EXT    GetIntegerv    Z3    FUNC_ADD_EXT    color-buffer
  131.  
  132. New Implementation Dependent State
  133.  
  134.     None
  135.