1 XXX
- Not complete yet
!!!
5 MESA_packed_depth_stencil
9 GL_MESA_packed_depth_stencil
13 Keith Whitwell
, VA Linux Systems Inc.
(keithw 'at' valinux.com
)
14 Brian Paul
, VA Linux Systems Inc.
(brianp 'at' valinux.com
)
22 $Id
: MESA_packed_depth_stencil.spec
,v
1.1 2000/11/03 14:58:45 brianp Exp $
30 EXT_abgr affects the definition of this extension
31 SGIS_texture4D affects the definition of this extension
32 EXT_cmyka affects the definition of this extension
33 ARB_packed_pixels affects the definition of this extension
37 Provides a mechanism
for DrawPixels and ReadPixels to efficiently
38 transfer depth and stencil image data. Specifically
, we defined new
39 packed pixel formats and types which pack both stencil and depth
44 1. Is this the right way to distinguish between
24/8 and
8/24
45 pixel formats? Should we instead provide both
:
50 And perhaps just use GL_UNSIGNED_INT
, GL_UNSIGNED_SHORT ?
52 2. If not
, is it correct to use _REV to indicate that stencil
53 preceeds depth
in the
1_15 and
8_24 formats?
55 3. Do we really want the GL_UNSIGNED_SHORT formats?
58 New Procedures and Functions
64 Accepted by the
<format
> parameter of ReadPixels and DrawPixels
:
66 GL_DEPTH_STENCIL_MESA
0x8750
68 Accepted by the
<type> parameter of ReadPixels and DrawPixels
:
70 GL_UNSIGNED_INT_24_8_MESA
0x8751
71 GL_UNSIGNED_INT_8_24_REV_MESA
0x8752
72 GL_UNSIGNED_SHORT_15_1_MESA
0x8753
73 GL_UNSIGNED_SHORT_1_15_REV_MESA
0x8754
75 Additions to Chapter
2 of the
1.1 Specification
(OpenGL Operation
)
79 Additions to Chapter
3 of the
1.1 Specification
(Rasterization
)
81 One entry is added to table
3.5 (DrawPixels and ReadPixels formats
).
85 Format
Name Buffer Element Meaning and Order
86 ----------- ------ -------------------------
87 COLOR_INDEX Color Color index
88 STENCIL_INDEX Stencil Stencil index
89 DEPTH_COMPONENT Depth Depth component
91 GREEN Color G component
92 BLUE Color B component
93 ALPHA Color A component
94 RGB Color R
, G
, B components
95 RGBA Color R
, G
, B
, A components
96 BGRA Color B
, G
, R
, A components
97 ABGR_EXT Color A
, B
, G
, R components
98 CMYK_EXT Color Cyan
, Magenta
, Yellow
, Black components
99 CMYKA_EXT Color Cyan
, Magenta
, Yellow
, Black
, A components
100 LUMINANCE Color Luminance component
101 LUMINANCE_ALPHA Color Luminance
, A components
102 DEPTH_STENCIL Depth
, Depth component
, stencil index.
105 Table
3.5: DrawPixels and ReadPixels formats. The third column
106 gives a description of and the number and order of elements
in a
109 Add to the description of packed pixel formats
:
111 <type> Parameter Data of Matching
112 Token
Name Type Elements Pixel Formats
113 ---------------- ---- -------- -------------
115 UNSIGNED_BYTE_3_3_2 ubyte
3 RGB
116 UNSIGNED_BYTE_2_3_3_REV ubyte
3 RGB
117 UNSIGNED_SHORT_5_6_5 ushort
3 RGB
118 UNSIGNED_SHORT_5_6_5_REV ushort
3 RGB
119 UNSIGNED_SHORT_4_4_4_4 ushort
4 RGBA
,BGRA
,ABGR_EXT
,CMYK_EXT
120 UNSIGNED_SHORT_4_4_4_4_REV ushort
4 RGBA
,BGRA
121 UNSIGNED_SHORT_5_5_5_1 ushort
4 RGBA
,BGRA
,ABGR_EXT
,CMYK_EXT
122 UNSIGNED_SHORT_1_5_5_5_REV ushort
4 RGBA
,BGRA
123 UNSIGNED_INT_8_8_8_8 uint
4 RGBA
,BGRA
,ABGR_EXT
,CMYK_EXT
124 UNSIGNED_INT_8_8_8_8_REV uint
4 RGBA
,BGRA
125 UNSIGNED_INT_10_10_10_2 uint
4 RGBA
,BGRA
,ABGR_EXT
,CMYK_EXT
126 UNSIGNED_INT_2_10_10_10_REV uint
4 RGBA
,BGRA
127 UNSIGNED_SHORT_15_1_MESA ushort
2 DEPTH_STENCIL_MESA
128 UNSIGNED_SHORT_1_15_REV_MESA ushort
2 DEPTH_STENCIL_MESA
129 UNSIGNED_SHORT_24_8_MESA ushort
2 DEPTH_STENCIL_MESA
130 UNSIGNED_SHORT_8_24_REV_MESA ushort
2 DEPTH_STENCIL_MESA
134 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
135 +-----------------------+-----------------------------------------------------------------------+
137 +-----------------------+-----------------------------------------------------------------------+
145 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
146 +----------------------------------------------------------------------+------------------------+
148 +----------------------------------------------------------------------+------------------------+
155 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
156 +-----------------------------------------------------------+---+
158 +-----------------------------------------------------------+---+
164 UNSIGNED_SHORT_1_15_REV
:
166 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
167 +---+-----------------------------------------------------------+
169 +---+-----------------------------------------------------------+
174 The assignment of elements to fields
in the packed pixel is as
175 described
in the table below
:
177 First Second Third Fourth
178 Format Element Element Element Element
179 ------ ------- ------- ------- -------
181 RGBA red green blue alpha
182 BGRA blue green red alpha
183 ABGR_EXT alpha blue green red
184 CMYK_EXT cyan magenta yellow black
185 DEPTH_STENCIL_MESA depth stencil
187 Additions to Chapter
4 of the
1.1 Specification
(Per
-Fragment Operations
188 and the Frame Buffer
)
190 The new format is added to the discussion of Obtaining Pixels from the
191 Framebuffer. It should
read " If the
<format
> is one of RED
, GREEN
,
192 BLUE
, ALPHA
, RGB
, RGBA
, ABGR_EXT
, LUMINANCE
, or LUMINANCE_ALPHA
, and
193 the GL is
in color index mode
, then the color index is obtained."
195 The new format is added to the discussion of Index Lookup. It should
196 read "If
<format
> is one of RED
, GREEN
, BLUE
, ALPHA
, RGB
, RGBA
,
197 ABGR_EXT
, LUMINANCE
, or LUMINANCE_ALPHA
, then the index is used to
198 reference
4 tables of color components
: PIXEL_MAP_I_TO_R
,
199 PIXEL_MAP_I_TO_G
, PIXEL_MAP_I_TO_B
, and PIXEL_MAP_I_TO_A."
202 Additions to Chapter
5 of the
1.1 Specification
(Special Functions
)
206 Additions to Chapter
6 of the
1.1 Specification
(State and State Requests
)
210 Additions to the GLX Specification
228 Version 1.0 - 23 Sep
2000
229 Keith's original version.
231 Version 1.1 - 3 Nov
2000
232 Brian's edits
, assigned values to new enums.