core  array_cache  math  swrast  swrast_setup  tnl  tnl_dd 
Main Page   Data Structures   File List   Data Fields   Globals   Related Pages  

texformat.h File Reference

Texture formats definitions. More...

#include "mtypes.h"

Assorted hardware-friendly formats

const struct gl_texture_format _mesa_texformat_rgba8888
const struct gl_texture_format _mesa_texformat_rgba8888_rev
const struct gl_texture_format _mesa_texformat_argb8888
const struct gl_texture_format _mesa_texformat_argb8888_rev
const struct gl_texture_format _mesa_texformat_rgb888
const struct gl_texture_format _mesa_texformat_bgr888
const struct gl_texture_format _mesa_texformat_rgb565
const struct gl_texture_format _mesa_texformat_rgb565_rev
const struct gl_texture_format _mesa_texformat_argb4444
const struct gl_texture_format _mesa_texformat_argb4444_rev
const struct gl_texture_format _mesa_texformat_argb1555
const struct gl_texture_format _mesa_texformat_argb1555_rev
const struct gl_texture_format _mesa_texformat_al88
const struct gl_texture_format _mesa_texformat_al88_rev
const struct gl_texture_format _mesa_texformat_rgb332
const struct gl_texture_format _mesa_texformat_a8
const struct gl_texture_format _mesa_texformat_l8
const struct gl_texture_format _mesa_texformat_i8
const struct gl_texture_format _mesa_texformat_ci8

YCbCr formats

const struct gl_texture_format _mesa_texformat_ycbcr
const struct gl_texture_format _mesa_texformat_ycbcr_rev

Compressed formats

const struct gl_texture_format _mesa_texformat_rgb_fxt1
const struct gl_texture_format _mesa_texformat_rgba_fxt1
const struct gl_texture_format _mesa_texformat_rgb_dxt1
const struct gl_texture_format _mesa_texformat_rgba_dxt1
const struct gl_texture_format _mesa_texformat_rgba_dxt3
const struct gl_texture_format _mesa_texformat_rgba_dxt5

The null format

const struct gl_texture_format _mesa_null_texformat

Enumerations

enum  _format {
  MESA_FORMAT_RGBA8888, MESA_FORMAT_RGBA8888_REV, MESA_FORMAT_ARGB8888, MESA_FORMAT_ARGB8888_REV,
  MESA_FORMAT_RGB888, MESA_FORMAT_BGR888, MESA_FORMAT_RGB565, MESA_FORMAT_RGB565_REV,
  MESA_FORMAT_ARGB4444, MESA_FORMAT_ARGB4444_REV, MESA_FORMAT_ARGB1555, MESA_FORMAT_ARGB1555_REV,
  MESA_FORMAT_AL88, MESA_FORMAT_AL88_REV, MESA_FORMAT_RGB332, MESA_FORMAT_A8,
  MESA_FORMAT_L8, MESA_FORMAT_I8, MESA_FORMAT_CI8, MESA_FORMAT_YCBCR,
  MESA_FORMAT_YCBCR_REV, MESA_FORMAT_RGB_FXT1, MESA_FORMAT_RGBA_FXT1, MESA_FORMAT_RGB_DXT1,
  MESA_FORMAT_RGBA_DXT1, MESA_FORMAT_RGBA_DXT3, MESA_FORMAT_RGBA_DXT5, MESA_FORMAT_RGBA,
  MESA_FORMAT_RGB, MESA_FORMAT_ALPHA, MESA_FORMAT_LUMINANCE, MESA_FORMAT_LUMINANCE_ALPHA,
  MESA_FORMAT_INTENSITY, MESA_FORMAT_DEPTH_COMPONENT_FLOAT32, MESA_FORMAT_DEPTH_COMPONENT16, MESA_FORMAT_RGBA_FLOAT32,
  MESA_FORMAT_RGBA_FLOAT16, MESA_FORMAT_RGB_FLOAT32, MESA_FORMAT_RGB_FLOAT16, MESA_FORMAT_ALPHA_FLOAT32,
  MESA_FORMAT_ALPHA_FLOAT16, MESA_FORMAT_LUMINANCE_FLOAT32, MESA_FORMAT_LUMINANCE_FLOAT16, MESA_FORMAT_LUMINANCE_ALPHA_FLOAT32,
  MESA_FORMAT_LUMINANCE_ALPHA_FLOAT16, MESA_FORMAT_INTENSITY_FLOAT32, MESA_FORMAT_INTENSITY_FLOAT16
}
 Mesa internal texture image formats. More...


Functions

const struct gl_texture_format_mesa_choose_tex_format (GLcontext *ctx, GLint internalFormat, GLenum format, GLenum type)
 Choose an appropriate texture format given the format, type and internalFormat parameters passed to glTexImage(). More...


Detailed Description

Texture formats definitions.

Author:
Gareth Hughes

Enumeration Type Documentation

enum _format
 

Mesa internal texture image formats.

All texture images are stored in one of these formats.

NOTE: when you add a new format, be sure to update the do_row() function in texstore.c used for auto mipmap generation.

Enumeration values:
MESA_FORMAT_RGBA8888 
MESA_FORMAT_RGBA8888_REV 
MESA_FORMAT_ARGB8888 
MESA_FORMAT_ARGB8888_REV 
MESA_FORMAT_RGB888 
MESA_FORMAT_BGR888 
MESA_FORMAT_RGB565 
MESA_FORMAT_RGB565_REV 
MESA_FORMAT_ARGB4444 
MESA_FORMAT_ARGB4444_REV 
MESA_FORMAT_ARGB1555 
MESA_FORMAT_ARGB1555_REV 
MESA_FORMAT_AL88 
MESA_FORMAT_AL88_REV 
MESA_FORMAT_RGB332 
MESA_FORMAT_A8 
MESA_FORMAT_L8 
MESA_FORMAT_I8 
MESA_FORMAT_CI8 
MESA_FORMAT_YCBCR 
MESA_FORMAT_YCBCR_REV 
MESA_FORMAT_RGB_FXT1 
MESA_FORMAT_RGBA_FXT1 
MESA_FORMAT_RGB_DXT1 
MESA_FORMAT_RGBA_DXT1 
MESA_FORMAT_RGBA_DXT3 
MESA_FORMAT_RGBA_DXT5 
MESA_FORMAT_RGBA 
MESA_FORMAT_RGB 
MESA_FORMAT_ALPHA 
MESA_FORMAT_LUMINANCE 
MESA_FORMAT_LUMINANCE_ALPHA 
MESA_FORMAT_INTENSITY 
MESA_FORMAT_DEPTH_COMPONENT_FLOAT32  Depth textures.
MESA_FORMAT_DEPTH_COMPONENT16 
MESA_FORMAT_RGBA_FLOAT32 
MESA_FORMAT_RGBA_FLOAT16 
MESA_FORMAT_RGB_FLOAT32 
MESA_FORMAT_RGB_FLOAT16 
MESA_FORMAT_ALPHA_FLOAT32 
MESA_FORMAT_ALPHA_FLOAT16 
MESA_FORMAT_LUMINANCE_FLOAT32 
MESA_FORMAT_LUMINANCE_FLOAT16 
MESA_FORMAT_LUMINANCE_ALPHA_FLOAT32 
MESA_FORMAT_LUMINANCE_ALPHA_FLOAT16 
MESA_FORMAT_INTENSITY_FLOAT32 
MESA_FORMAT_INTENSITY_FLOAT16 


Function Documentation

const struct gl_texture_format* _mesa_choose_tex_format GLcontext   ctx,
GLint    internalFormat,
GLenum    format,
GLenum    type
 

Choose an appropriate texture format given the format, type and internalFormat parameters passed to glTexImage().

Parameters:
ctx  the GL context.
internalFormat  user's prefered internal texture format.
format  incoming image pixel format.
type  incoming image data type.
Returns:
a pointer to a gl_texture_format object which describes the choosen texture format, or NULL on failure.
This is called via dd_function_table::ChooseTextureFormat. Hardware drivers will typically override this function with a specialized version.


Variable Documentation

const struct gl_texture_format _mesa_null_texformat
 

const struct gl_texture_format _mesa_texformat_a8
 

const struct gl_texture_format _mesa_texformat_al88
 

const struct gl_texture_format _mesa_texformat_al88_rev
 

const struct gl_texture_format _mesa_texformat_alpha
 

const struct gl_texture_format _mesa_texformat_alpha_float16
 

const struct gl_texture_format _mesa_texformat_alpha_float32
 

const struct gl_texture_format _mesa_texformat_argb1555
 

const struct gl_texture_format _mesa_texformat_argb1555_rev
 

const struct gl_texture_format _mesa_texformat_argb4444
 

const struct gl_texture_format _mesa_texformat_argb4444_rev
 

const struct gl_texture_format _mesa_texformat_argb8888
 

const struct gl_texture_format _mesa_texformat_argb8888_rev
 

const struct gl_texture_format _mesa_texformat_bgr888
 

const struct gl_texture_format _mesa_texformat_ci8
 

const struct gl_texture_format _mesa_texformat_depth_component16
 

const struct gl_texture_format _mesa_texformat_depth_component_float32
 

Depth textures.

const struct gl_texture_format _mesa_texformat_i8
 

const struct gl_texture_format _mesa_texformat_intensity
 

const struct gl_texture_format _mesa_texformat_intensity_float16
 

const struct gl_texture_format _mesa_texformat_intensity_float32
 

const struct gl_texture_format _mesa_texformat_l8
 

const struct gl_texture_format _mesa_texformat_luminance
 

const struct gl_texture_format _mesa_texformat_luminance_alpha
 

const struct gl_texture_format _mesa_texformat_luminance_alpha_float16
 

const struct gl_texture_format _mesa_texformat_luminance_alpha_float32
 

const struct gl_texture_format _mesa_texformat_luminance_float16
 

const struct gl_texture_format _mesa_texformat_luminance_float32
 

const struct gl_texture_format _mesa_texformat_rgb
 

const struct gl_texture_format _mesa_texformat_rgb332
 

const struct gl_texture_format _mesa_texformat_rgb565
 

const struct gl_texture_format _mesa_texformat_rgb565_rev
 

const struct gl_texture_format _mesa_texformat_rgb888
 

const struct gl_texture_format _mesa_texformat_rgb_dxt1
 

const struct gl_texture_format _mesa_texformat_rgb_float16
 

const struct gl_texture_format _mesa_texformat_rgb_float32
 

const struct gl_texture_format _mesa_texformat_rgb_fxt1
 

const struct gl_texture_format _mesa_texformat_rgba
 

GLchan-valued formats.

const struct gl_texture_format _mesa_texformat_rgba8888
 

const struct gl_texture_format _mesa_texformat_rgba8888_rev
 

const struct gl_texture_format _mesa_texformat_rgba_dxt1
 

const struct gl_texture_format _mesa_texformat_rgba_dxt3
 

const struct gl_texture_format _mesa_texformat_rgba_dxt5
 

const struct gl_texture_format _mesa_texformat_rgba_float16
 

const struct gl_texture_format _mesa_texformat_rgba_float32
 

Floating point texture formats.

const struct gl_texture_format _mesa_texformat_rgba_fxt1
 

const struct gl_texture_format _mesa_texformat_ycbcr
 

const struct gl_texture_format _mesa_texformat_ycbcr_rev
 


Generated on Sun May 16 15:55:12 2004 for Mesa Core by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001