#include "glheader.h"
#include "mfeatures.h"
#include "colormac.h"
#include "colortab.h"
#include "context.h"
#include "enums.h"
#include "macros.h"
#include "texcompress.h"
#include "texobj.h"
#include "teximage.h"
#include "texstate.h"
#include "texenvprogram.h"
#include "mtypes.h"
Functions | |
| void | _mesa_copy_texture_state (const GLcontext *src, GLcontext *dst) |
| Used by glXCopyContext to copy texture state from one context to another. | |
| void | _mesa_print_texunit_state (GLcontext *ctx, GLuint unit) |
| static void | calculate_derived_texenv (struct gl_tex_env_combine_state *state, GLenum mode, GLenum texBaseFormat) |
| Convert "classic" texture environment to ARB_texture_env_combine style environments. | |
| void GLAPIENTRY | _mesa_ActiveTextureARB (GLenum texture) |
| void GLAPIENTRY | _mesa_ClientActiveTextureARB (GLenum texture) |
| static void | update_texture_matrices (GLcontext *ctx) |
| |
| static void | update_tex_combine (GLcontext *ctx, struct gl_texture_unit *texUnit) |
| Examine texture unit's combine/env state to update derived state. | |
| static void | update_texture_state (GLcontext *ctx) |
| |
| void | _mesa_update_texture (GLcontext *ctx, GLuint new_state) |
| Update texture-related derived state. | |
| static GLboolean | alloc_proxy_textures (GLcontext *ctx) |
| Allocate the proxy textures for the given context. | |
| static void | init_texture_unit (GLcontext *ctx, GLuint unit) |
| Initialize a texture unit. | |
| GLboolean | _mesa_init_texture (GLcontext *ctx) |
| Initialize texture state for the given context. | |
| void | _mesa_free_texture_data (GLcontext *ctx) |
| Free dynamically-allocted texture data attached to the given context. | |
| void | _mesa_update_default_objects_texture (GLcontext *ctx) |
| Update the default texture objects in the given context to reference those specified in the shared state and release those referencing the old shared state. | |
Variables | |
| static struct gl_tex_env_combine_state | default_combine_state |
| Default texture combine environment state. | |
| void GLAPIENTRY _mesa_ActiveTextureARB | ( | GLenum | texture | ) |
| void GLAPIENTRY _mesa_ClientActiveTextureARB | ( | GLenum | texture | ) |
Used by glXCopyContext to copy texture state from one context to another.
| void _mesa_free_texture_data | ( | GLcontext * | ctx | ) |
Free dynamically-allocted texture data attached to the given context.
| GLboolean _mesa_init_texture | ( | GLcontext * | ctx | ) |
Initialize texture state for the given context.
| void _mesa_print_texunit_state | ( | GLcontext * | ctx, | |
| GLuint | unit | |||
| ) |
| void _mesa_update_default_objects_texture | ( | GLcontext * | ctx | ) |
Update the default texture objects in the given context to reference those specified in the shared state and release those referencing the old shared state.
| void _mesa_update_texture | ( | GLcontext * | ctx, | |
| GLuint | new_state | |||
| ) |
Update texture-related derived state.
| static GLboolean alloc_proxy_textures | ( | GLcontext * | ctx | ) | [static] |
Allocate the proxy textures for the given context.
| ctx | the context to allocate proxies for. |
| static void calculate_derived_texenv | ( | struct gl_tex_env_combine_state * | state, | |
| GLenum | mode, | |||
| GLenum | texBaseFormat | |||
| ) | [static] |
Convert "classic" texture environment to ARB_texture_env_combine style environments.
| state | texture_env_combine state vector to be filled-in. | |
| mode | Classic texture environment mode (i.e., GL_REPLACE, GL_BLEND, GL_DECAL, etc.). | |
| texBaseFormat | Base format of the texture associated with the texture unit. |
| static void init_texture_unit | ( | GLcontext * | ctx, | |
| GLuint | unit | |||
| ) | [static] |
Initialize a texture unit.
| ctx | GL context. | |
| unit | texture unit number to be initialized. |
| static void update_tex_combine | ( | GLcontext * | ctx, | |
| struct gl_texture_unit * | texUnit | |||
| ) | [static] |
Examine texture unit's combine/env state to update derived state.
| static void update_texture_matrices | ( | GLcontext * | ctx | ) | [static] |
On changes to _NEW_TEXTURE, the ENABLE_TEXMAT flags are updated by _mesa_update_textures(), below.
| ctx | GL context. |
| static void update_texture_state | ( | GLcontext * | ctx | ) | [static] |
On changes to _NEW_TEXTURE_MATRIX, the ENABLE_TEXMAT flags are updated by _mesa_update_texture_matrices, above.
| ctx | GL context. |
struct gl_tex_env_combine_state default_combine_state [static] |
Initial value:
{
GL_MODULATE, GL_MODULATE,
{ GL_TEXTURE, GL_PREVIOUS, GL_CONSTANT, GL_CONSTANT },
{ GL_TEXTURE, GL_PREVIOUS, GL_CONSTANT, GL_CONSTANT },
{ GL_SRC_COLOR, GL_SRC_COLOR, GL_SRC_ALPHA, GL_SRC_ALPHA },
{ GL_SRC_ALPHA, GL_SRC_ALPHA, GL_SRC_ALPHA, GL_SRC_ALPHA },
0, 0,
2, 2
}
This is used to initialize a context's texture units and as the basis for converting "classic" texture environmnets to ARB_texture_env_combine style values.
1.5.4