Mesa (master): gallium/docs: table of texture formats and (x,y,z,w) tuples returned by TEX

Brian Paul brianp at kemper.freedesktop.org
Tue Feb 2 15:15:38 UTC 2010


Module: Mesa
Branch: master
Commit: 4778f46bb52f26f255eca87fe3d2fcc9bb71f13a
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=4778f46bb52f26f255eca87fe3d2fcc9bb71f13a

Author: Brian Paul <brianp at vmware.com>
Date:   Tue Feb  2 08:14:40 2010 -0700

gallium/docs: table of texture formats and (x,y,z,w) tuples returned by TEX

Maybe someone can convert this into a real table instead of just
preformatted text.

---

 src/gallium/docs/source/tgsi.rst |   29 +++++++++++++++++++++++++++++
 1 files changed, 29 insertions(+), 0 deletions(-)

diff --git a/src/gallium/docs/source/tgsi.rst b/src/gallium/docs/source/tgsi.rst
index 3e702ce..17fe76e 100644
--- a/src/gallium/docs/source/tgsi.rst
+++ b/src/gallium/docs/source/tgsi.rst
@@ -1441,3 +1441,32 @@ GL_ARB_fragment_coord_conventions extension.
 
 DirectX 9 uses INTEGER.
 DirectX 10 uses HALF_INTEGER.
+
+
+
+Texture Sampling and Texture Formats
+------------------------------------
+
+This table shows how texture image components are returned as (x,y,z,w)
+tuples by TGSI texture instructions, such as TEX, TXD, and TXP.
+For reference, OpenGL and Direct3D convensions are shown as well::
+
+  Texture Components  Gallium       OpenGL        DX9
+  ---------------------------------------------------------
+  R,G,B,A             (R,G,B,A)     (R,G,B,A)     (R,G,B,A)
+  R,G,B               (R,G,B,1)     (R,G,B,1)     (R,G,B,1)
+  R,G                 tbd           (R,G,0,1)     (R,G,1,1)
+  R                   tbd           (R,0,0,1)     (R,1,1,1)
+  A                   (0,0,0,A)     (0,0,0,A)     (0,0,0,A)
+  L                   (L,L,L,1)     (L,L,L,1)     (L,L,L,1)
+  LA                  (L,L,L,A)     (L,L,L,A)     (L,L,L,A)
+  I                   (I,I,I,I)     (I,I,I,I)     n/a
+  UV                  tbd           (0,0,0,1)*    (U,V,1,1)
+  Z                   tbd           (Z,Z,Z,Z) or  (0,Z,0,1)
+                                    (Z,Z,Z,1) or
+                                    (0,0,0,Z)**
+
+  Footnotes:
+  * per http://www.opengl.org/registry/specs/ATI/envmap_bumpmap.txt
+  ** depends on GL_DEPTH_TEXTURE_MODE state
+ 
\ No newline at end of file




More information about the mesa-commit mailing list