#include <mtypes.h>
This is the central context data structure for Mesa. Almost all OpenGL state is contained in this structure. Think of this as a base class from which device drivers will derive sub classes.
The GLcontext typedef names this structure.
Data Fields | |
struct gl_shared_state * | Shared |
State possibly shared with other contexts in the address space. | |
GLvisual | Visual |
GLframebuffer * | DrawBuffer |
buffer for writing | |
GLframebuffer * | ReadBuffer |
buffer for reading | |
GLframebuffer * | WinSysDrawBuffer |
set with MakeCurrent | |
GLframebuffer * | WinSysReadBuffer |
set with MakeCurrent | |
struct dd_function_table | Driver |
Device driver function pointer table. | |
void * | DriverCtx |
Points to device driver context/state. | |
struct gl_constants | Const |
Core/Driver constants. | |
GLmatrix | _ModelProjectMatrix |
Combined modelview and projection matrix. | |
struct gl_meta_state * | Meta |
for "meta" operations | |
GLenum | ErrorValue |
Last error code. | |
const char * | ErrorDebugFmtString |
Recognize and silence repeated error debug messages in buggy apps. | |
GLuint | ErrorDebugCount |
GLenum | RenderMode |
either GL_RENDER, GL_SELECT, GL_FEEDBACK | |
GLbitfield | NewState |
bitwise-or of _NEW_* flags | |
GLboolean | ViewportInitialized |
has viewport size been initialized? | |
GLbitfield | varying_vp_inputs |
mask of VERT_BIT_* flags | |
struct gl_list_extensions | ListExt |
driver dlist extensions | |
GLboolean | NoDither |
Dither disable via MESA_NO_DITHER env var. | |
GLboolean | Mesa_DXTn |
software compression/decompression supported or not | |
GLboolean | mvp_with_dp4 |
Use dp4 (rather than mul/mad) instructions for position transformation? | |
struct gl_tnl_module | TnlModule |
Core tnl module support. | |
API function pointer tables | |
struct _glapi_table * | Save |
Display list save functions. | |
struct _glapi_table * | Exec |
Execute functions. | |
struct _glapi_table * | CurrentDispatch |
== Save or Exec !! | |
The various 4x4 matrix stacks | |
struct gl_matrix_stack | ModelviewMatrixStack |
struct gl_matrix_stack | ProjectionMatrixStack |
struct gl_matrix_stack | ColorMatrixStack |
struct gl_matrix_stack | TextureMatrixStack [MAX_TEXTURE_UNITS] |
struct gl_matrix_stack | ProgramMatrixStack [MAX_PROGRAM_MATRICES] |
struct gl_matrix_stack * | CurrentStack |
Points to one of the above stacks. | |
Display lists | |
struct gl_dlist_state | ListState |
GLboolean | ExecuteFlag |
Execute GL commands? | |
GLboolean | CompileFlag |
Compile GL commands into display list? | |
struct gl_extensions | Extensions |
Extension information. | |
State attribute stack (for glPush/PopAttrib) | |
GLuint | AttribStackDepth |
struct gl_attrib_node * | AttribStack [MAX_ATTRIB_STACK_DEPTH] |
Renderer attribute groups | |
We define a struct for each attribute group to make pushing and popping attributes easy.
Also it's a good organization. | |
struct gl_accum_attrib | Accum |
Accum buffer attributes. | |
struct gl_colorbuffer_attrib | Color |
Color buffer attributes. | |
struct gl_current_attrib | Current |
Current attributes. | |
struct gl_depthbuffer_attrib | Depth |
Depth buffer attributes. | |
struct gl_eval_attrib | Eval |
Eval attributes. | |
struct gl_fog_attrib | Fog |
Fog attributes. | |
struct gl_hint_attrib | Hint |
Hint attributes. | |
struct gl_light_attrib | Light |
Light attributes. | |
struct gl_line_attrib | Line |
Line attributes. | |
struct gl_list_attrib | List |
List attributes. | |
struct gl_multisample_attrib | Multisample |
struct gl_pixel_attrib | Pixel |
Pixel attributes. | |
struct gl_point_attrib | Point |
Point attributes. | |
struct gl_polygon_attrib | Polygon |
Polygon attributes. | |
GLuint | PolygonStipple [32] |
Polygon stipple. | |
struct gl_scissor_attrib | Scissor |
Scissor attributes. | |
struct gl_stencil_attrib | Stencil |
Stencil buffer attributes. | |
struct gl_texture_attrib | Texture |
Texture attributes. | |
struct gl_transform_attrib | Transform |
Transformation attributes. | |
struct gl_viewport_attrib | Viewport |
Viewport attributes. | |
Client attribute stack | |
GLuint | ClientAttribStackDepth |
struct gl_attrib_node * | ClientAttribStack [MAX_CLIENT_ATTRIB_STACK_DEPTH] |
Client attribute groups | |
struct gl_array_attrib | Array |
Vertex arrays. | |
struct gl_pixelstore_attrib | Pack |
Pixel packing. | |
struct gl_pixelstore_attrib | Unpack |
Pixel unpacking. | |
struct gl_pixelstore_attrib | DefaultPacking |
Default params. | |
Other assorted state (not pushed/popped on attribute stack) | |
struct gl_pixelmaps | PixelMaps |
struct gl_histogram_attrib | Histogram |
struct gl_minmax_attrib | MinMax |
struct gl_convolution_attrib | Convolution1D |
struct gl_convolution_attrib | Convolution2D |
struct gl_convolution_attrib | Separable2D |
struct gl_evaluators | EvalMap |
All evaluators. | |
struct gl_feedback | Feedback |
Feedback. | |
struct gl_selection | Select |
Selection. | |
struct gl_color_table | ColorTable [COLORTABLE_MAX] |
struct gl_color_table | ProxyColorTable [COLORTABLE_MAX] |
struct gl_program_state | Program |
general program state | |
struct gl_vertex_program_state | VertexProgram |
struct gl_fragment_program_state | FragmentProgram |
struct gl_ati_fragment_shader_state | ATIFragmentShader |
struct gl_shader_state | Shader |
GLSL shader object state. | |
struct gl_query_state | Query |
occlusion, timer queries | |
struct gl_buffer_object * | CopyReadBuffer |
GL_ARB_copy_buffer. | |
struct gl_buffer_object * | CopyWriteBuffer |
GL_ARB_copy_buffer. | |
Derived state | |
GLbitfield | _TriangleCaps |
Bitwise-or of DD_* flags. | |
GLbitfield | _ImageTransferState |
bitwise-or of IMAGE_*_BIT flags | |
GLfloat | _EyeZDir [3] |
GLfloat | _ModelViewInvScale |
GLboolean | _NeedEyeCoords |
GLboolean | _ForceEyeCoords |
GLuint | TextureStateTimestamp |
detect changes to shared state | |
struct gl_shine_tab * | _ShineTable [2] |
Active shine tables. | |
struct gl_shine_tab * | _ShineTabList |
MRU list of inactive shine tables. | |
For debugging/development only | |
GLboolean | FirstTimeCurrent |
Hooks for module contexts. | |
These will eventually live in the driver or elsewhere. | |
void * | swrast_context |
void * | swsetup_context |
void * | swtnl_context |
void * | swtnl_im |
struct st_context * | st |
void * | aelt_context |
struct gl_shared_state* __GLcontextRec::Shared [read] |
State possibly shared with other contexts in the address space.
struct _glapi_table* __GLcontextRec::Save [read] |
Display list save functions.
struct _glapi_table* __GLcontextRec::Exec [read] |
Execute functions.
struct _glapi_table* __GLcontextRec::CurrentDispatch [read] |
== Save or Exec !!
buffer for writing
buffer for reading
set with MakeCurrent
set with MakeCurrent
struct dd_function_table __GLcontextRec::Driver [read] |
Device driver function pointer table.
Points to device driver context/state.
struct gl_constants __GLcontextRec::Const [read] |
Core/Driver constants.
struct gl_matrix_stack __GLcontextRec::ModelviewMatrixStack [read] |
struct gl_matrix_stack __GLcontextRec::ProjectionMatrixStack [read] |
struct gl_matrix_stack __GLcontextRec::ColorMatrixStack [read] |
struct gl_matrix_stack __GLcontextRec::TextureMatrixStack[MAX_TEXTURE_UNITS] [read] |
struct gl_matrix_stack __GLcontextRec::ProgramMatrixStack[MAX_PROGRAM_MATRICES] [read] |
struct gl_matrix_stack* __GLcontextRec::CurrentStack [read] |
Points to one of the above stacks.
Combined modelview and projection matrix.
struct gl_dlist_state __GLcontextRec::ListState [read] |
GLboolean __GLcontextRec::ExecuteFlag |
Execute GL commands?
GLboolean __GLcontextRec::CompileFlag |
Compile GL commands into display list?
struct gl_extensions __GLcontextRec::Extensions [read] |
Extension information.
struct gl_attrib_node* __GLcontextRec::AttribStack[MAX_ATTRIB_STACK_DEPTH] [read] |
struct gl_accum_attrib __GLcontextRec::Accum [read] |
Accum buffer attributes.
struct gl_colorbuffer_attrib __GLcontextRec::Color [read] |
Color buffer attributes.
struct gl_current_attrib __GLcontextRec::Current [read] |
Current attributes.
struct gl_depthbuffer_attrib __GLcontextRec::Depth [read] |
Depth buffer attributes.
struct gl_eval_attrib __GLcontextRec::Eval [read] |
Eval attributes.
struct gl_fog_attrib __GLcontextRec::Fog [read] |
Fog attributes.
struct gl_hint_attrib __GLcontextRec::Hint [read] |
Hint attributes.
struct gl_light_attrib __GLcontextRec::Light [read] |
Light attributes.
struct gl_line_attrib __GLcontextRec::Line [read] |
Line attributes.
struct gl_list_attrib __GLcontextRec::List [read] |
List attributes.
struct gl_multisample_attrib __GLcontextRec::Multisample [read] |
struct gl_pixel_attrib __GLcontextRec::Pixel [read] |
Pixel attributes.
struct gl_point_attrib __GLcontextRec::Point [read] |
Point attributes.
struct gl_polygon_attrib __GLcontextRec::Polygon [read] |
Polygon attributes.
GLuint __GLcontextRec::PolygonStipple[32] |
Polygon stipple.
struct gl_scissor_attrib __GLcontextRec::Scissor [read] |
Scissor attributes.
struct gl_stencil_attrib __GLcontextRec::Stencil [read] |
Stencil buffer attributes.
struct gl_texture_attrib __GLcontextRec::Texture [read] |
Texture attributes.
struct gl_transform_attrib __GLcontextRec::Transform [read] |
Transformation attributes.
struct gl_viewport_attrib __GLcontextRec::Viewport [read] |
Viewport attributes.
struct gl_attrib_node* __GLcontextRec::ClientAttribStack[MAX_CLIENT_ATTRIB_STACK_DEPTH] [read] |
struct gl_array_attrib __GLcontextRec::Array [read] |
Vertex arrays.
struct gl_pixelstore_attrib __GLcontextRec::Pack [read] |
Pixel packing.
struct gl_pixelstore_attrib __GLcontextRec::Unpack [read] |
Pixel unpacking.
struct gl_pixelstore_attrib __GLcontextRec::DefaultPacking [read] |
Default params.
struct gl_pixelmaps __GLcontextRec::PixelMaps [read] |
struct gl_histogram_attrib __GLcontextRec::Histogram [read] |
struct gl_minmax_attrib __GLcontextRec::MinMax [read] |
struct gl_convolution_attrib __GLcontextRec::Convolution1D [read] |
struct gl_convolution_attrib __GLcontextRec::Convolution2D [read] |
struct gl_convolution_attrib __GLcontextRec::Separable2D [read] |
struct gl_evaluators __GLcontextRec::EvalMap [read] |
All evaluators.
struct gl_feedback __GLcontextRec::Feedback [read] |
Feedback.
struct gl_selection __GLcontextRec::Select [read] |
Selection.
struct gl_color_table __GLcontextRec::ColorTable[COLORTABLE_MAX] [read] |
struct gl_color_table __GLcontextRec::ProxyColorTable[COLORTABLE_MAX] [read] |
struct gl_program_state __GLcontextRec::Program [read] |
general program state
struct gl_vertex_program_state __GLcontextRec::VertexProgram [read] |
struct gl_fragment_program_state __GLcontextRec::FragmentProgram [read] |
struct gl_shader_state __GLcontextRec::Shader [read] |
GLSL shader object state.
struct gl_query_state __GLcontextRec::Query [read] |
occlusion, timer queries
struct gl_buffer_object* __GLcontextRec::CopyReadBuffer [read] |
GL_ARB_copy_buffer.
struct gl_buffer_object* __GLcontextRec::CopyWriteBuffer [read] |
GL_ARB_copy_buffer.
struct gl_meta_state* __GLcontextRec::Meta [read] |
for "meta" operations
GLenum __GLcontextRec::ErrorValue |
Last error code.
const char* __GLcontextRec::ErrorDebugFmtString |
Recognize and silence repeated error debug messages in buggy apps.
GLenum __GLcontextRec::RenderMode |
either GL_RENDER, GL_SELECT, GL_FEEDBACK
GLbitfield __GLcontextRec::NewState |
bitwise-or of _NEW_* flags
GLboolean __GLcontextRec::ViewportInitialized |
has viewport size been initialized?
GLbitfield __GLcontextRec::varying_vp_inputs |
mask of VERT_BIT_* flags
GLbitfield __GLcontextRec::_TriangleCaps |
Bitwise-or of DD_* flags.
Note that this bitfield may be used before state validation so they need to always be current.
GLbitfield __GLcontextRec::_ImageTransferState |
bitwise-or of IMAGE_*_BIT flags
GLfloat __GLcontextRec::_EyeZDir[3] |
GLboolean __GLcontextRec::_NeedEyeCoords |
GLboolean __GLcontextRec::_ForceEyeCoords |
detect changes to shared state
struct gl_shine_tab* __GLcontextRec::_ShineTable[2] [read] |
Active shine tables.
struct gl_shine_tab* __GLcontextRec::_ShineTabList [read] |
MRU list of inactive shine tables.
struct gl_list_extensions __GLcontextRec::ListExt [read] |
driver dlist extensions
GLboolean __GLcontextRec::FirstTimeCurrent |
GLboolean __GLcontextRec::NoDither |
Dither disable via MESA_NO_DITHER env var.
GLboolean __GLcontextRec::Mesa_DXTn |
software compression/decompression supported or not
GLboolean __GLcontextRec::mvp_with_dp4 |
Use dp4 (rather than mul/mad) instructions for position transformation?
struct gl_tnl_module __GLcontextRec::TnlModule [read] |
Core tnl module support.
void* __GLcontextRec::swtnl_im |
struct st_context* __GLcontextRec::st [read] |