Index: tests/GLProgramsTest.cpp |
=================================================================== |
--- tests/GLProgramsTest.cpp (revision 8091) |
+++ tests/GLProgramsTest.cpp (working copy) |
@@ -121,6 +121,8 @@ |
GrGLProgram::Desc pdesc; |
GrEffectStage stages[GrDrawState::kNumStages]; |
+ int currAttribIndex = GrDrawState::kAttribIndexCount; |
+ int attribIndices[2]; |
for (int s = 0; s < maxStages; ++s) { |
// enable the stage? |
if (random.nextBool()) { |
@@ -129,7 +131,10 @@ |
&random, |
this->getContext(), |
dummyTextures)); |
- stages[s].setEffect(effect.get()); |
+ for (int i = 0; i < effect.get()->get()->numVertexAttribs(); ++i) { |
+ attribIndices[i] = currAttribIndex++; |
+ } |
+ stages[s].setEffect(effect.get(), attribIndices); |
} |
} |
pdesc.setRandom(&random, this, stages); |