this->Const.MaxVertexAttribs = ctx->Const.VertexProgram.MaxAttribs;
this->Const.MaxVertexUniformComponents = ctx->Const.VertexProgram.MaxUniformComponents;
this->Const.MaxVaryingFloats = ctx->Const.MaxVarying * 4;
- this->Const.MaxVertexTextureImageUnits = ctx->Const.MaxVertexTextureImageUnits;
+ this->Const.MaxVertexTextureImageUnits = ctx->Const.VertexProgram.MaxTextureImageUnits;
this->Const.MaxCombinedTextureImageUnits = ctx->Const.MaxCombinedTextureImageUnits;
- this->Const.MaxTextureImageUnits = ctx->Const.MaxTextureImageUnits;
+ this->Const.MaxTextureImageUnits = ctx->Const.FragmentProgram.MaxTextureImageUnits;
this->Const.MaxFragmentUniformComponents = ctx->Const.FragmentProgram.MaxUniformComponents;
this->Const.MinProgramTexelOffset = ctx->Const.MinProgramTexelOffset;
this->Const.MaxProgramTexelOffset = ctx->Const.MaxProgramTexelOffset;
};
const unsigned max_samplers[MESA_SHADER_TYPES] = {
- ctx->Const.MaxVertexTextureImageUnits,
- ctx->Const.MaxTextureImageUnits,
- ctx->Const.MaxGeometryTextureImageUnits
+ ctx->Const.VertexProgram.MaxTextureImageUnits,
+ ctx->Const.FragmentProgram.MaxTextureImageUnits,
+ ctx->Const.GeometryProgram.MaxTextureImageUnits
};
const unsigned max_uniform_components[MESA_SHADER_TYPES] = {
ctx->Const.VertexProgram.MaxUniformComponents,
ctx->Const.FragmentProgram.MaxUniformComponents,
- 0 /* FINISHME: Geometry shaders. */
+ ctx->Const.GeometryProgram.MaxUniformComponents
};
const unsigned max_uniform_blocks[MESA_SHADER_TYPES] = {
ctx->Const.VertexProgram.MaxUniformComponents = 512;
ctx->Const.MaxVarying = 8; /* == gl_MaxVaryingFloats / 4 */
- ctx->Const.MaxVertexTextureImageUnits = 0;
+ ctx->Const.VertexProgram.MaxTextureImageUnits = 0;
ctx->Const.MaxCombinedTextureImageUnits = 2;
- ctx->Const.MaxTextureImageUnits = 2;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = 2;
ctx->Const.FragmentProgram.MaxUniformComponents = 64;
ctx->Const.MaxDrawBuffers = 1;
FALLBACK(intel, INTEL_FALLBACK_USER, 1);
intel->ctx.Const.MaxTextureUnits = I830_TEX_UNITS;
- intel->ctx.Const.MaxTextureImageUnits = I830_TEX_UNITS;
+ intel->ctx.Const.FragmentProgram.MaxTextureImageUnits = I830_TEX_UNITS;
intel->ctx.Const.MaxTextureCoordUnits = I830_TEX_UNITS;
/* Advertise the full hardware capabilities. The new memory
FALLBACK(intel, INTEL_FALLBACK_USER, 1);
ctx->Const.MaxTextureUnits = I915_TEX_UNITS;
- ctx->Const.MaxTextureImageUnits = I915_TEX_UNITS;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = I915_TEX_UNITS;
ctx->Const.MaxTextureCoordUnits = I915_TEX_UNITS;
ctx->Const.MaxVarying = I915_TEX_UNITS;
ctx->Const.MaxCombinedTextureImageUnits =
- ctx->Const.MaxVertexTextureImageUnits +
- ctx->Const.MaxTextureImageUnits;
+ ctx->Const.VertexProgram.MaxTextureImageUnits +
+ ctx->Const.FragmentProgram.MaxTextureImageUnits;
/* Advertise the full hardware capabilities. The new memory
* manager should cope much better with overload situations:
ctx->Const.MaxDualSourceDrawBuffers = 1;
ctx->Const.MaxDrawBuffers = BRW_MAX_DRAW_BUFFERS;
- ctx->Const.MaxTextureImageUnits = BRW_MAX_TEX_UNIT;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = BRW_MAX_TEX_UNIT;
ctx->Const.MaxTextureCoordUnits = 8; /* Mesa limit */
ctx->Const.MaxTextureUnits = MIN2(ctx->Const.MaxTextureCoordUnits,
- ctx->Const.MaxTextureImageUnits);
- ctx->Const.MaxVertexTextureImageUnits = BRW_MAX_TEX_UNIT;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits);
+ ctx->Const.VertexProgram.MaxTextureImageUnits = BRW_MAX_TEX_UNIT;
ctx->Const.MaxCombinedTextureImageUnits =
- ctx->Const.MaxVertexTextureImageUnits +
- ctx->Const.MaxTextureImageUnits;
+ ctx->Const.VertexProgram.MaxTextureImageUnits +
+ ctx->Const.FragmentProgram.MaxTextureImageUnits;
ctx->Const.MaxTextureLevels = 14; /* 8192 */
if (ctx->Const.MaxTextureLevels > MAX_TEXTURE_LEVELS)
/* GL constants. */
ctx->Const.MaxTextureLevels = 11;
ctx->Const.MaxTextureCoordUnits = NV04_TEXTURE_UNITS;
- ctx->Const.MaxTextureImageUnits = NV04_TEXTURE_UNITS;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = NV04_TEXTURE_UNITS;
ctx->Const.MaxTextureUnits = NV04_TEXTURE_UNITS;
ctx->Const.MaxTextureMaxAnisotropy = 2;
ctx->Const.MaxTextureLodBias = 15;
/* GL constants. */
ctx->Const.MaxTextureLevels = 12;
ctx->Const.MaxTextureCoordUnits = NV10_TEXTURE_UNITS;
- ctx->Const.MaxTextureImageUnits = NV10_TEXTURE_UNITS;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = NV10_TEXTURE_UNITS;
ctx->Const.MaxTextureUnits = NV10_TEXTURE_UNITS;
ctx->Const.MaxTextureMaxAnisotropy = 2;
ctx->Const.MaxTextureLodBias = 15;
/* GL constants. */
ctx->Const.MaxTextureCoordUnits = NV20_TEXTURE_UNITS;
- ctx->Const.MaxTextureImageUnits = NV20_TEXTURE_UNITS;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = NV20_TEXTURE_UNITS;
ctx->Const.MaxTextureUnits = NV20_TEXTURE_UNITS;
ctx->Const.MaxTextureMaxAnisotropy = 8;
ctx->Const.MaxTextureLodBias = 15;
*/
ctx->Const.MaxTextureUnits = driQueryOptioni (&rmesa->radeon.optionCache,
"texture_units");
- ctx->Const.MaxTextureImageUnits = ctx->Const.MaxTextureUnits;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = ctx->Const.MaxTextureUnits;
ctx->Const.MaxTextureCoordUnits = ctx->Const.MaxTextureUnits;
ctx->Const.MaxCombinedTextureImageUnits = ctx->Const.MaxTextureUnits;
0, RADEON_GEM_DOMAIN_VRAM);
}
- for (i = 0; i < ctx->Const.MaxTextureImageUnits; ++i) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxTextureImageUnits; ++i) {
radeonTexObj *t;
if (!ctx->Texture.Unit[i]._ReallyEnabled)
ctx->Const.MaxTextureUnits = driQueryOptioni (&rmesa->radeon.optionCache,
"texture_units");
- ctx->Const.MaxTextureImageUnits = ctx->Const.MaxTextureUnits;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = ctx->Const.MaxTextureUnits;
ctx->Const.MaxTextureCoordUnits = ctx->Const.MaxTextureUnits;
ctx->Const.MaxCombinedTextureImageUnits = ctx->Const.MaxTextureUnits;
0, RADEON_GEM_DOMAIN_VRAM);
}
- for (i = 0; i < ctx->Const.MaxTextureImageUnits; ++i) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxTextureImageUnits; ++i) {
radeonTexObj *t;
if (!ctx->Texture.Unit[i]._ReallyEnabled)
ctx->Const.MaxTextureRectSize = MAX_TEXTURE_RECT_SIZE;
ctx->Const.MaxArrayTextureLayers = MAX_ARRAY_TEXTURE_LAYERS;
ctx->Const.MaxTextureCoordUnits = MAX_TEXTURE_COORD_UNITS;
- ctx->Const.MaxTextureImageUnits = MAX_TEXTURE_IMAGE_UNITS;
+ ctx->Const.FragmentProgram.MaxTextureImageUnits = MAX_TEXTURE_IMAGE_UNITS;
ctx->Const.MaxTextureUnits = MIN2(ctx->Const.MaxTextureCoordUnits,
- ctx->Const.MaxTextureImageUnits);
+ ctx->Const.FragmentProgram.MaxTextureImageUnits);
ctx->Const.MaxTextureMaxAnisotropy = MAX_TEXTURE_MAX_ANISOTROPY;
ctx->Const.MaxTextureLodBias = MAX_TEXTURE_LOD_BIAS;
ctx->Const.MaxTextureBufferSize = 65536;
ctx->Const.MaxColorAttachments = MAX_COLOR_ATTACHMENTS;
ctx->Const.MaxRenderbufferSize = MAX_RENDERBUFFER_SIZE;
- ctx->Const.MaxVertexTextureImageUnits = MAX_TEXTURE_IMAGE_UNITS;
+ ctx->Const.VertexProgram.MaxTextureImageUnits = MAX_TEXTURE_IMAGE_UNITS;
ctx->Const.MaxCombinedTextureImageUnits = MAX_COMBINED_TEXTURE_IMAGE_UNITS;
ctx->Const.MaxVarying = 16; /* old limit not to break tnl and swrast */
- ctx->Const.MaxGeometryTextureImageUnits = MAX_TEXTURE_IMAGE_UNITS;
+ ctx->Const.GeometryProgram.MaxTextureImageUnits = MAX_TEXTURE_IMAGE_UNITS;
ctx->Const.MaxVertexVaryingComponents = MAX_VERTEX_VARYING_COMPONENTS;
ctx->Const.MaxGeometryVaryingComponents = MAX_GEOMETRY_VARYING_COMPONENTS;
ctx->Const.MaxGeometryOutputVertices = MAX_GEOMETRY_OUTPUT_VERTICES;
assert(ctx->Const.VertexProgram.MaxLocalParams <= MAX_PROGRAM_LOCAL_PARAMS);
/* Texture unit checks */
- assert(ctx->Const.MaxTextureImageUnits > 0);
- assert(ctx->Const.MaxTextureImageUnits <= MAX_TEXTURE_IMAGE_UNITS);
+ assert(ctx->Const.FragmentProgram.MaxTextureImageUnits > 0);
+ assert(ctx->Const.FragmentProgram.MaxTextureImageUnits <= MAX_TEXTURE_IMAGE_UNITS);
assert(ctx->Const.MaxTextureCoordUnits > 0);
assert(ctx->Const.MaxTextureCoordUnits <= MAX_TEXTURE_COORD_UNITS);
assert(ctx->Const.MaxTextureUnits > 0);
assert(ctx->Const.MaxTextureUnits <= MAX_TEXTURE_IMAGE_UNITS);
assert(ctx->Const.MaxTextureUnits <= MAX_TEXTURE_COORD_UNITS);
- assert(ctx->Const.MaxTextureUnits == MIN2(ctx->Const.MaxTextureImageUnits,
+ assert(ctx->Const.MaxTextureUnits == MIN2(ctx->Const.FragmentProgram.MaxTextureImageUnits,
ctx->Const.MaxTextureCoordUnits));
assert(ctx->Const.MaxCombinedTextureImageUnits > 0);
assert(ctx->Const.MaxCombinedTextureImageUnits <= MAX_COMBINED_TEXTURE_IMAGE_UNITS);
assert(ctx->Const.MaxTextureCoordUnits <= MAX_COMBINED_TEXTURE_IMAGE_UNITS);
/* number of coord units cannot be greater than number of image units */
- assert(ctx->Const.MaxTextureCoordUnits <= ctx->Const.MaxTextureImageUnits);
+ assert(ctx->Const.MaxTextureCoordUnits <= ctx->Const.FragmentProgram.MaxTextureImageUnits);
/* Texture size checks */
# GL_ARB_fragment_program
# == GL_MAX_TEXTURE_IMAGE_UNITS_NV
- [ "MAX_TEXTURE_IMAGE_UNITS_ARB", "CONTEXT_INT(Const.MaxTextureImageUnits), extra_ARB_fragment_program" ],
- [ "MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB", "CONTEXT_INT(Const.MaxVertexTextureImageUnits), extra_ARB_vertex_shader" ],
+ [ "MAX_TEXTURE_IMAGE_UNITS_ARB", "CONTEXT_INT(Const.FragmentProgram.MaxTextureImageUnits), extra_ARB_fragment_program" ],
+ [ "MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB", "CONTEXT_INT(Const.VertexProgram.MaxTextureImageUnits), extra_ARB_vertex_shader" ],
[ "MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB", "CONTEXT_INT(Const.MaxCombinedTextureImageUnits), extra_ARB_vertex_shader" ],
# GL_ARB_shader_objects
[ "MAX_VERTEX_STREAMS", "CONTEXT_INT(Const.MaxVertexStreams), extra_ARB_transform_feedback3" ],
# GL_ARB_geometry_shader4
- [ "MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB", "CONTEXT_INT(Const.MaxGeometryTextureImageUnits), extra_ARB_geometry_shader4" ],
+ [ "MAX_GEOMETRY_TEXTURE_IMAGE_UNITS_ARB", "CONTEXT_INT(Const.GeometryProgram.MaxTextureImageUnits), extra_ARB_geometry_shader4" ],
[ "MAX_GEOMETRY_OUTPUT_VERTICES_ARB", "CONTEXT_INT(Const.MaxGeometryOutputVertices), extra_ARB_geometry_shader4" ],
[ "MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS_ARB", "CONTEXT_INT(Const.MaxGeometryTotalOutputComponents), extra_ARB_geometry_shader4" ],
[ "MAX_GEOMETRY_UNIFORM_COMPONENTS_ARB", "CONTEXT_INT(Const.GeometryProgram.MaxUniformComponents), extra_ARB_geometry_shader4" ],
/* GL_ARB_uniform_buffer_object */
GLuint MaxUniformBlocks;
GLuint MaxCombinedUniformComponents;
+ GLuint MaxTextureImageUnits;
};
GLuint MaxArrayTextureLayers; /**< Max layers in array textures */
GLuint MaxTextureRectSize; /**< Max rectangle texture size, in pixes */
GLuint MaxTextureCoordUnits;
- GLuint MaxTextureImageUnits;
- GLuint MaxVertexTextureImageUnits;
GLuint MaxCombinedTextureImageUnits;
- GLuint MaxGeometryTextureImageUnits;
- GLuint MaxTextureUnits; /**< = MIN(CoordUnits, ImageUnits) */
+ GLuint MaxTextureUnits; /**< = MIN(CoordUnits, FragmentProgram.ImageUnits) */
GLfloat MaxTextureMaxAnisotropy; /**< GL_EXT_texture_filter_anisotropic */
GLfloat MaxTextureLodBias; /**< GL_EXT_texture_lod_bias */
GLuint MaxTextureBufferSize; /**< GL_ARB_texture_buffer_object */
}
else if (pname == GL_BUMP_NUM_TEX_UNITS_ATI) {
GLint count = 0;
- for (i = 0; i < ctx->Const.MaxTextureImageUnits; i++) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxTextureImageUnits; i++) {
if (ctx->Const.SupportedBumpUnits & (1 << i)) {
count++;
}
*param = count;
}
else if (pname == GL_BUMP_TEX_UNITS_ATI) {
- for (i = 0; i < ctx->Const.MaxTextureImageUnits; i++) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxTextureImageUnits; i++) {
if (ctx->Const.SupportedBumpUnits & (1 << i)) {
*param++ = i + GL_TEXTURE0;
}
}
else if (pname == GL_BUMP_NUM_TEX_UNITS_ATI) {
GLint count = 0;
- for (i = 0; i < ctx->Const.MaxTextureImageUnits; i++) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxTextureImageUnits; i++) {
if (ctx->Const.SupportedBumpUnits & (1 << i)) {
count++;
}
*param = (GLfloat) count;
}
else if (pname == GL_BUMP_TEX_UNITS_ATI) {
- for (i = 0; i < ctx->Const.MaxTextureImageUnits; i++) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxTextureImageUnits; i++) {
if (ctx->Const.SupportedBumpUnits & (1 << i)) {
*param++ = (GLfloat) (i + GL_TEXTURE0);
}
ctx->Extensions.EXT_texture_snorm &&
ctx->Extensions.NV_primitive_restart &&
ctx->Extensions.NV_texture_rectangle &&
- ctx->Const.MaxVertexTextureImageUnits >= 16);
+ ctx->Const.VertexProgram.MaxTextureImageUnits >= 16);
const GLboolean ver_3_2 = (ver_3_1 &&
ctx->Const.GLSLVersion >= 150 &&
ctx->Extensions.ARB_depth_clamp &&
? & ctx->Const.VertexProgram
: & ctx->Const.FragmentProgram;
- state->MaxTextureImageUnits = ctx->Const.MaxTextureImageUnits;
+ state->MaxTextureImageUnits = ctx->Const.FragmentProgram.MaxTextureImageUnits;
state->MaxTextureCoordUnits = ctx->Const.MaxTextureCoordUnits;
state->MaxTextureUnits = ctx->Const.MaxTextureUnits;
state->MaxClipPlanes = ctx->Const.MaxClipPlanes;
update_shader_samplers(st,
PIPE_SHADER_FRAGMENT,
&ctx->FragmentProgram._Current->Base,
- ctx->Const.MaxTextureImageUnits,
+ ctx->Const.FragmentProgram.MaxTextureImageUnits,
st->state.samplers[PIPE_SHADER_FRAGMENT],
&st->state.num_samplers[PIPE_SHADER_FRAGMENT]);
update_shader_samplers(st,
PIPE_SHADER_VERTEX,
&ctx->VertexProgram._Current->Base,
- ctx->Const.MaxVertexTextureImageUnits,
+ ctx->Const.VertexProgram.MaxTextureImageUnits,
st->state.samplers[PIPE_SHADER_VERTEX],
&st->state.num_samplers[PIPE_SHADER_VERTEX]);
update_shader_samplers(st,
PIPE_SHADER_GEOMETRY,
&ctx->GeometryProgram._Current->Base,
- ctx->Const.MaxGeometryTextureImageUnits,
+ ctx->Const.GeometryProgram.MaxTextureImageUnits,
st->state.samplers[PIPE_SHADER_GEOMETRY],
&st->state.num_samplers[PIPE_SHADER_GEOMETRY]);
}
{
const struct gl_context *ctx = st->ctx;
- if (ctx->Const.MaxVertexTextureImageUnits > 0) {
+ if (ctx->Const.VertexProgram.MaxTextureImageUnits > 0) {
update_textures(st,
PIPE_SHADER_VERTEX,
&ctx->VertexProgram._Current->Base,
- ctx->Const.MaxVertexTextureImageUnits,
+ ctx->Const.VertexProgram.MaxTextureImageUnits,
st->state.sampler_views[PIPE_SHADER_VERTEX],
&st->state.num_sampler_views[PIPE_SHADER_VERTEX]);
}
update_textures(st,
PIPE_SHADER_FRAGMENT,
&ctx->FragmentProgram._Current->Base,
- ctx->Const.MaxTextureImageUnits,
+ ctx->Const.FragmentProgram.MaxTextureImageUnits,
st->state.sampler_views[PIPE_SHADER_FRAGMENT],
&st->state.num_sampler_views[PIPE_SHADER_FRAGMENT]);
}
update_textures(st,
PIPE_SHADER_GEOMETRY,
&ctx->GeometryProgram._Current->Base,
- ctx->Const.MaxTextureImageUnits,
+ ctx->Const.FragmentProgram.MaxTextureImageUnits,
st->state.sampler_views[PIPE_SHADER_GEOMETRY],
&st->state.num_sampler_views[PIPE_SHADER_GEOMETRY]);
}
c->MaxArrayTextureLayers
= screen->get_param(screen, PIPE_CAP_MAX_TEXTURE_ARRAY_LAYERS);
- c->MaxTextureImageUnits
+ c->FragmentProgram.MaxTextureImageUnits
= _min(screen->get_shader_param(screen, PIPE_SHADER_FRAGMENT,
PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS),
MAX_TEXTURE_IMAGE_UNITS);
- c->MaxVertexTextureImageUnits
+ c->VertexProgram.MaxTextureImageUnits
= _min(screen->get_shader_param(screen, PIPE_SHADER_VERTEX,
PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS),
MAX_TEXTURE_IMAGE_UNITS);
MAX_COMBINED_TEXTURE_IMAGE_UNITS);
c->MaxTextureCoordUnits
- = _min(c->MaxTextureImageUnits, MAX_TEXTURE_COORD_UNITS);
+ = _min(c->FragmentProgram.MaxTextureImageUnits, MAX_TEXTURE_COORD_UNITS);
- c->MaxTextureUnits = _min(c->MaxTextureImageUnits, c->MaxTextureCoordUnits);
+ c->MaxTextureUnits = _min(c->FragmentProgram.MaxTextureImageUnits, c->MaxTextureCoordUnits);
/* Define max viewport size and max renderbuffer size in terms of
* max texture size (note: max tex RECT size = max tex 2D size).
assert(i == program->num_immediates);
/* texture samplers */
- for (i = 0; i < ctx->Const.MaxTextureImageUnits; i++) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxTextureImageUnits; i++) {
if (program->samplers_used & (1 << i)) {
t->samplers[i] = ureg_DECL_sampler(ureg, i);
}
}
/* texture samplers */
- for (i = 0; i < ctx->Const.MaxTextureImageUnits; i++) {
+ for (i = 0; i < ctx->Const.FragmentProgram.MaxTextureImageUnits; i++) {
if (program->SamplersUsed & (1 << i)) {
t->samplers[i] = ureg_DECL_sampler( ureg, i );
}
swrast->BlendFunc = _swrast_validate_blend_func;
if (new_state & _SWRAST_NEW_TEXTURE_SAMPLE_FUNC)
- for (i = 0 ; i < ctx->Const.MaxTextureImageUnits ; i++)
+ for (i = 0 ; i < ctx->Const.FragmentProgram.MaxTextureImageUnits ; i++)
swrast->TextureSample[i] = NULL;
}
if (!swrast)
return; /* pipe hack */
- for (u = 0; u < ctx->Const.MaxTextureImageUnits; u++) {
+ for (u = 0; u < ctx->Const.FragmentProgram.MaxTextureImageUnits; u++) {
struct gl_texture_object *tObj = ctx->Texture.Unit[u]._Current;
/* Note: If tObj is NULL, the sample function will be a simple
* function that just returns opaque black (0,0,0,1).
* thread.
*/
swrast->TexelBuffer =
- malloc(ctx->Const.MaxTextureImageUnits * maxThreads *
+ malloc(ctx->Const.FragmentProgram.MaxTextureImageUnits * maxThreads *
SWRAST_MAX_WIDTH * 4 * sizeof(GLfloat));
if (!swrast->TexelBuffer) {
_mesa_error(ctx, GL_OUT_OF_MEMORY, "texture_combine");
{
GLuint u;
- for (u = 0; u < ctx->Const.MaxVertexTextureImageUnits; u++) {
+ for (u = 0; u < ctx->Const.VertexProgram.MaxTextureImageUnits; u++) {
if (vp->Base.TexturesUsed[u]) {
/* Note: _Current *should* correspond to the target indicated
* in TexturesUsed[u].
{
GLuint u;
- for (u = 0; u < ctx->Const.MaxVertexTextureImageUnits; u++) {
+ for (u = 0; u < ctx->Const.VertexProgram.MaxTextureImageUnits; u++) {
if (vp->Base.TexturesUsed[u]) {
/* Note: _Current *should* correspond to the target indicated
* in TexturesUsed[u].