• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1Name
2
3    ARB_texture_env_crossbar
4
5Name Strings
6
7    GL_ARB_texture_env_crossbar
8
9Contact
10
11    Bimal Poddar, Intel (bimal.poddar 'at' intel.com)
12    Jack Middleton, Sun (Jack.Middleton 'at' Eng.Sun.COM)
13    Rick Hammerstone, AMD (rick.hammerstone 'at' amd.com)
14
15Notice
16
17    Copyright (c) 2001-2013 The Khronos Group Inc. Copyright terms at
18        http://www.khronos.org/registry/speccopyright.html
19
20Specification Update Policy
21
22    Khronos-approved extension specifications are updated in response to
23    issues and bugs prioritized by the Khronos OpenGL Working Group. For
24    extensions which have been promoted to a core Specification, fixes will
25    first appear in the latest version of that core Specification, and will
26    eventually be backported to the extension document. This policy is
27    described in more detail at
28        https://www.khronos.org/registry/OpenGL/docs/update_policy.php
29
30Status
31
32    Complete. Approved by ARB on February 16, 2001.
33
34Version
35
36    Last modified date: 2006/11/04
37
38Number
39
40    ARB Extension #18
41
42Dependencies
43
44    This extension is written against the OpenGL 1.2.1 Specification.
45    OpenGL 1.1, ARB_multitexture and ARB_texture_env_combine are required
46    by this extension.
47
48Overview
49
50    This extension adds the capability to use the texture color from
51    other texture units as sources to the COMBINE_ARB enviornment
52    function. The ARB_texture_env_combine extension defined texture
53    enviornment functions which could use the color from the
54    current texture unit as a source. This extension adds
55    the ability to use the color from any texture unit as a source.
56
57Issues
58
59 1. Should only "upstream" textures be allowed as inputs to a
60    given texture unit? (Texture inputs to unit <m> are restricted to
61    the range TEXTURE0_ARB to TEXTURE<m>_ARB).
62
63    - RESOLVED: No. Most vendors support this functionality.
64
65
66 2. Do we still need TEXTURE as a source if we allow TEXTURE<n>_ARB?
67
68    - RESOLVED: Yes, since this allows backwards compatibility.
69
70 3. What should be the behavior when the texture environment
71    references a texture unit that is not enabled or does not have a
72    valid texture object bound to it?
73
74    - RESOLVED: Texture blending should be disabled on the texture
75      unit that is referencing the invalid or disabled texture. This
76      seems to be a reasonable compromise between disabling all
77      texturing and generating "default" texel values. Also, this
78      behavior is more easily forward compatible to an extension
79      which separates the texture lookup and texture blend units.
80
81New Procedures and Functions
82
83    None
84
85New Tokens
86
87    Accepted by the <params> parameter of TexEnvf, TexEnvi, TexEnvfv,
88    and TexEnviv when the <pname> parameter value is SOURCE0_RGB_ARB,
89    SOURCE1_RGB_ARB, SOURCE2_RGB_ARB, SOURCE0_ALPHA_ARB,
90    SOURCE1_ALPHA_ARB, or SOURCE2_ALPHA_ARB
91
92        TEXTURE<n>_ARB                        0x84C0+<n>
93
94    where <n> is in the range 0 to MAX_TEXTURE_UNITS_ARB.
95
96Additions to Chapter 2 of the GL Specification (OpenGL Operation)
97
98    None
99
100Additions to Chapter 3 of the GL Specification (Rasterization)
101
102    Modify paragraph describing tables 3.21 and 3.22 in the
103    ARB_texture_env_combine spec to read:
104
105    The arguments Arg0, Arg1 and Arg2 are determined by the values of
106    SOURCE<n>_RGB_ARB, SOURCE<n>_ALPHA_ARB, OPERAND<n>_RGB_ARB and
107    OPERAND<n>_ALPHA_ARB. In the following two tables, Ct and At are
108    the filtered texture RGB and alpha values; Ct<n> and At<n> are the
109    filtered texture RGB and alpha values from the texture bound to
110    texture unit <n>; Cc and Ac are the texture environment RGB and
111    alpha values; Cf and Af are the RGB and alpha of the primary color
112    of the incoming fragment; and Cp and Ap are the RGB and alpha
113    values resulting from the previous texture environment. On texture
114    environment 0, Cp and Ap are identical to Cf and Af, respectively.
115    The relationship is described in tables 3.21 and 3.22.
116    Added to table 3.21 of the ARB_texture_env_combine spec:
117
118        SOURCE<n>_RGB_ARB       OPERAND<n>_RGB_ARB      Argument
119        -----------------       --------------          --------
120
121        TEXTURE<n>_ARB          SRC_COLOR               Ct<n>
122                                ONE_MINUS_SRC_COLOR     (1-Ct<n>)
123                                SRC_ALPHA               At<n>
124                                ONE_MINUS_SRC_ALPHA     (1-At<n>)
125
126        Table 3.21: Arguments for COMBINE_RGB_ARB functions
127
128    Added to table 3.22 of the ARB_texture_env_combine spec:
129
130        SOURCE<n>_ALPHA_ARB     OPERAND<n>_ALPHA_ARB    Argument
131        -----------------       --------------          --------
132
133        TEXTURE<n>_ARB          SRC_ALPHA               At<n>
134                                ONE_MINUS_SRC_ALPHA     (1-At<n>)
135
136        Table 3.22: Arguments for COMBINE_ALPHA_ARB functions
137
138Additions to Chapter 4 of the GL Specification (Per-Fragment Operations
139and the Framebuffer)
140
141    None
142
143Additions to Chapter 5 of the GL Specification (Special Functions)
144
145    None
146
147Additions to Chapter 6 of the GL Specification (State and State Requests)
148
149    None
150
151Additions to Appendix F of the GL Specification (ARB Extensions)
152
153    Inserted after the second paragraph of F.2.12:
154
155    If the value of TEXTURE_ENV_MODE is COMBINE_ARB, the texture
156    function associated with a given texture unit is computed using
157    the values specified by SOURCE<n>_RGB_ARB, SOURCE<n>_ALPHA_ARB,
158    OPERAND<n>_RGB_ARB and OPERAND<n>_ALPHA_ARB. If TEXTURE<n>_ARB is
159    specified as SOURCE<n>_RGB_ARB or SOURCE<n>_ALPHA_ARB, the texture
160    value from texture unit <n> will be used in computing the texture
161    function for this texture unit.
162
163    Inserted after the third paragraph of F.2.12:
164
165    If a texture environment for a given texture unit references a
166    texture unit that is disabled or does not have a valid texture
167    object bound to it, then it is as if texture blending is disabled
168    for the given texture unit. Every texture unit implicitly
169    references the texture object that is bound to it, regardless
170    of the texture function specified by COMBINE_RGB_ARB or COMBINE_ALPHA_ARB.
171
172Additions to the GLX Specification
173
174    None
175
176GLX Protocol
177
178    None
179
180Errors
181
182    INVALID_ENUM is generated if <params> value for SOURCE0_RGB_ARB,
183    SOURCE1_RGB_ARB, SOURCE2_RGB_ARB, SOURCE0_ALPHA_ARB,
184    SOURCE1_ALPHA_ARB or SOURCE2_ALPHA_ARB is not one of TEXTURE,
185    CONSTANT_ARB, PRIMARY_COLOR_ARB, PREVIOUS_ARB, or TEXTURE<n>_ARB,
186    where <n> is in the range 0 to MAX_TEXTURE_UNITS_ARB.
187
188New State
189
190    None
191
192Revision History
193    06/11/04    benj        Updated contact info after ATI/AMD merger.
194
195    01/02/02    bpoddar     Added original EXT/ARB contributors to the contact
196                            list
197
198    00/12/06    bpoddar     Added comments from the ARB meeting.
199                            Changed texturing disable to texture blending
200                            disable. Added description of table 3.21
201                            and 3.22 to define Ct<n> and At<n>.
202
203    00/12/01    bpoddar     Added clarification regarding disabling of
204                            texture blend unit when it references a
205                            disabled texture.
206                            Removed some changes which were already
207                            specified in ARB_texture_env_combine spec.
208
209    00/10/31    jmiddleton  First version of the spec
210