Lines Matching defs:texUnit

128    const struct gl_fixedfunc_texture_unit *texUnit = ctx->Texture.FixedFuncUnit + unit;
130 printf(" GL_TEXTURE_ENV_MODE = %s\n", _mesa_enum_to_string(texUnit->EnvMode));
131 printf(" GL_COMBINE_RGB = %s\n", _mesa_enum_to_string(texUnit->Combine.ModeRGB));
132 printf(" GL_COMBINE_ALPHA = %s\n", _mesa_enum_to_string(texUnit->Combine.ModeA));
133 printf(" GL_SOURCE0_RGB = %s\n", _mesa_enum_to_string(texUnit->Combine.SourceRGB[0]));
134 printf(" GL_SOURCE1_RGB = %s\n", _mesa_enum_to_string(texUnit->Combine.SourceRGB[1]));
135 printf(" GL_SOURCE2_RGB = %s\n", _mesa_enum_to_string(texUnit->Combine.SourceRGB[2]));
136 printf(" GL_SOURCE0_ALPHA = %s\n", _mesa_enum_to_string(texUnit->Combine.SourceA[0]));
137 printf(" GL_SOURCE1_ALPHA = %s\n", _mesa_enum_to_string(texUnit->Combine.SourceA[1]));
138 printf(" GL_SOURCE2_ALPHA = %s\n", _mesa_enum_to_string(texUnit->Combine.SourceA[2]));
139 printf(" GL_OPERAND0_RGB = %s\n", _mesa_enum_to_string(texUnit->Combine.OperandRGB[0]));
140 printf(" GL_OPERAND1_RGB = %s\n", _mesa_enum_to_string(texUnit->Combine.OperandRGB[1]));
141 printf(" GL_OPERAND2_RGB = %s\n", _mesa_enum_to_string(texUnit->Combine.OperandRGB[2]));
142 printf(" GL_OPERAND0_ALPHA = %s\n", _mesa_enum_to_string(texUnit->Combine.OperandA[0]));
143 printf(" GL_OPERAND1_ALPHA = %s\n", _mesa_enum_to_string(texUnit->Combine.OperandA[1]));
144 printf(" GL_OPERAND2_ALPHA = %s\n", _mesa_enum_to_string(texUnit->Combine.OperandA[2]));
145 printf(" GL_RGB_SCALE = %d\n", 1 << texUnit->Combine.ScaleShiftRGB);
146 printf(" GL_ALPHA_SCALE = %d\n", 1 << texUnit->Combine.ScaleShiftA);
147 printf(" GL_TEXTURE_ENV_COLOR = (%f, %f, %f, %f)\n", texUnit->EnvColor[0], texUnit->EnvColor[1], texUnit->EnvColor[2], texUnit->EnvColor[3]);
290 const GLuint texUnit = texture - GL_TEXTURE0;
298 if (ctx->Texture.CurrentUnit == texUnit)
306 if (texUnit >= k) {
326 ctx->Texture.CurrentUnit = texUnit;
329 ctx->CurrentStack = &ctx->TextureMatrixStack[texUnit];
353 GLuint texUnit = texture - GL_TEXTURE0;
359 if (ctx->Array.ActiveTexture == texUnit)
362 if (texUnit >= ctx->Const.MaxTextureCoordUnits) {
369 ctx->Array.ActiveTexture = texUnit;
480 pack_tex_combine(struct gl_fixedfunc_texture_unit *texUnit)
482 struct gl_tex_env_combine_state *state = texUnit->_CurrentCombine;
483 struct gl_tex_env_combine_packed *packed = &texUnit->_CurrentCombinePacked;
487 packed->ModeRGB = tex_combine_translate_mode(texUnit->EnvMode, state->ModeRGB);
488 packed->ModeA = tex_combine_translate_mode(texUnit->EnvMode, state->ModeA);
513 struct gl_texture_unit *texUnit,
519 if (texUnit->_Current->Target == GL_TEXTURE_BUFFER)
522 /* Set the texUnit->_CurrentCombine field to point to the user's combiner
531 const struct gl_texture_object *texObj = texUnit->_Current;
613 struct gl_fixedfunc_texture_unit *texUnit =
616 texUnit->_GenFlags = 0x0;
621 if (texUnit->TexGenEnabled) {
622 if (texUnit->TexGenEnabled & S_BIT) {
623 texUnit->_GenFlags |= texUnit->GenS._ModeBit;
625 if (texUnit->TexGenEnabled & T_BIT) {
626 texUnit->_GenFlags |= texUnit->GenT._ModeBit;
628 if (texUnit->TexGenEnabled & R_BIT) {
629 texUnit->_GenFlags |= texUnit->GenR._ModeBit;
631 if (texUnit->TexGenEnabled & Q_BIT) {
632 texUnit->_GenFlags |= texUnit->GenQ._ModeBit;
636 ctx->Texture._GenFlags |= texUnit->_GenFlags;
650 struct gl_texture_unit *texUnit;
654 texUnit = &ctx->Texture.Unit[unit];
667 texObj = texUnit->CurrentTex[target_index];
669 sampler = texUnit->Sampler ?
670 texUnit->Sampler : &texObj->Sampler;
769 struct gl_texture_unit *texUnit = &ctx->Texture.Unit[unit];
815 struct gl_texture_object *texObj = texUnit->CurrentTex[texIndex];
816 struct gl_sampler_object *sampler = texUnit->Sampler ?
817 texUnit->Sampler : &texObj->Sampler;
823 _mesa_reference_texobj(&texUnit->_Current, texObj);
839 update_tex_combine(ctx, texUnit, fftexUnit);
1019 struct gl_texture_unit *texUnit = &ctx->Texture.Unit[u];
1024 _mesa_reference_texobj(&texUnit->CurrentTex[tex],
1028 texUnit->_BoundTextures = 0;
1032 struct gl_fixedfunc_texture_unit *texUnit =
1035 texUnit->EnvMode = GL_MODULATE;
1036 ASSIGN_4V( texUnit->EnvColor, 0.0, 0.0, 0.0, 0.0 );
1038 texUnit->Combine = default_combine_state;
1039 texUnit->_EnvMode = default_combine_state;
1040 texUnit->_CurrentCombine = & texUnit->_EnvMode;
1042 texUnit->TexGenEnabled = 0x0;
1043 texUnit->GenS.Mode = GL_EYE_LINEAR;
1044 texUnit->GenT.Mode = GL_EYE_LINEAR;
1045 texUnit->GenR.Mode = GL_EYE_LINEAR;
1046 texUnit->GenQ.Mode = GL_EYE_LINEAR;
1047 texUnit->GenS._ModeBit = TEXGEN_EYE_LINEAR;
1048 texUnit->GenT._ModeBit = TEXGEN_EYE_LINEAR;
1049 texUnit->GenR._ModeBit = TEXGEN_EYE_LINEAR;
1050 texUnit->GenQ._ModeBit = TEXGEN_EYE_LINEAR;
1053 ASSIGN_4V( texUnit->GenS.ObjectPlane, 1.0, 0.0, 0.0, 0.0 );
1054 ASSIGN_4V( texUnit->GenT.ObjectPlane, 0.0, 1.0, 0.0, 0.0 );
1055 ASSIGN_4V( texUnit->GenR.ObjectPlane, 0.0, 0.0, 0.0, 0.0 );
1056 ASSIGN_4V( texUnit->GenQ.ObjectPlane, 0.0, 0.0, 0.0, 0.0 );
1057 ASSIGN_4V( texUnit->GenS.EyePlane, 1.0, 0.0, 0.0, 0.0 );
1058 ASSIGN_4V( texUnit->GenT.EyePlane, 0.0, 1.0, 0.0, 0.0 );
1059 ASSIGN_4V( texUnit->GenR.EyePlane, 0.0, 0.0, 0.0, 0.0 );
1060 ASSIGN_4V( texUnit->GenQ.EyePlane, 0.0, 0.0, 0.0, 0.0 );
1126 struct gl_texture_unit *texUnit = &ctx->Texture.Unit[u];
1128 _mesa_reference_texobj(&texUnit->CurrentTex[tex],