Remove TGSI_INTERPOLATE_ATTRIB.

This commit is contained in:
Michal Krol 2007-10-29 11:40:09 +00:00
parent 242b8659e4
commit e15ca7963e
3 changed files with 11 additions and 10 deletions

View file

@ -294,7 +294,7 @@ tgsi_build_declaration_interpolation(
{
struct tgsi_declaration_interpolation di;
assert( interpolate <= TGSI_INTERPOLATE_ATTRIB );
assert( interpolate <= TGSI_INTERPOLATE_PERSPECTIVE );
di = tgsi_default_declaration_interpolation();
di.Interpolate = interpolate;

View file

@ -96,7 +96,6 @@ struct tgsi_declaration_mask
#define TGSI_INTERPOLATE_CONSTANT 0
#define TGSI_INTERPOLATE_LINEAR 1
#define TGSI_INTERPOLATE_PERSPECTIVE 2
#define TGSI_INTERPOLATE_ATTRIB 3 /**< Vertex shader input attrib */
struct tgsi_declaration_interpolation
{

View file

@ -519,6 +519,7 @@ compile_instruction(
static struct tgsi_full_declaration
make_input_decl(
GLuint index,
GLboolean interpolate_info,
GLuint interpolate,
GLuint usage_mask,
GLboolean semantic_info,
@ -534,14 +535,16 @@ make_input_decl(
decl.Declaration.Declare = TGSI_DECLARE_RANGE;
decl.Declaration.UsageMask = usage_mask;
decl.Declaration.Semantic = semantic_info;
decl.Declaration.Interpolate = 1;
decl.u.DeclarationRange.First = index;
decl.u.DeclarationRange.Last = index;
if (semantic_info) {
decl.Semantic.SemanticName = semantic_name;
decl.Semantic.SemanticIndex = semantic_index;
}
decl.Interpolation.Interpolate = interpolate;
if (interpolate_info) {
decl.Declaration.Interpolate = 1;
decl.Interpolation.Interpolate = interpolate;
}
return decl;
}
@ -685,7 +688,7 @@ tgsi_translate_mesa_program(
case TGSI_SEMANTIC_POSITION:
/* Fragment XY pos */
fulldecl = make_input_decl(i,
TGSI_INTERPOLATE_CONSTANT,
GL_TRUE, TGSI_INTERPOLATE_CONSTANT,
TGSI_WRITEMASK_XY,
GL_TRUE, TGSI_SEMANTIC_POSITION, 0 );
ti += tgsi_build_full_declaration(
@ -695,7 +698,7 @@ tgsi_translate_mesa_program(
maxTokens - ti );
/* Fragment ZW pos */
fulldecl = make_input_decl(i,
TGSI_INTERPOLATE_LINEAR,
GL_TRUE, TGSI_INTERPOLATE_LINEAR,
TGSI_WRITEMASK_ZW,
GL_TRUE, TGSI_SEMANTIC_POSITION, 0 );
ti += tgsi_build_full_declaration(&fulldecl,
@ -705,7 +708,7 @@ tgsi_translate_mesa_program(
break;
default:
fulldecl = make_input_decl(i,
interpMode[i],
GL_TRUE, interpMode[i],
TGSI_WRITEMASK_XYZW,
GL_TRUE, inputSemanticName[i],
inputSemanticIndex[i]);
@ -722,10 +725,9 @@ tgsi_translate_mesa_program(
for (i = 0; i < numInputs; i++) {
struct tgsi_full_declaration fulldecl;
fulldecl = make_input_decl(i,
TGSI_INTERPOLATE_ATTRIB,
GL_FALSE, 0,
TGSI_WRITEMASK_XYZW,
GL_FALSE, inputSemanticName[i],
inputSemanticIndex[i]);
GL_FALSE, 0, 0);
ti += tgsi_build_full_declaration(&fulldecl,
&tokens[ti],
header,