diff options
author | 2009-12-16 14:13:06 -0800 | |
---|---|---|
committer | 2009-12-16 14:13:06 -0800 | |
commit | ce9adcce02ef528cf5a65c3650099aa54ebb712a (patch) | |
tree | 0f7a423d186d588d0324ed6c9c5b7524e06bac44 /libs/rs/rsProgramVertex.cpp | |
parent | 5dad8b4d1fda37b7b4763ef7361c5eb92131cb7e (diff) |
Fix emulated glColor in es2 mode.
Diffstat (limited to 'libs/rs/rsProgramVertex.cpp')
-rw-r--r-- | libs/rs/rsProgramVertex.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/libs/rs/rsProgramVertex.cpp b/libs/rs/rsProgramVertex.cpp index 058cd737dbce..153e2d6844ae 100644 --- a/libs/rs/rsProgramVertex.cpp +++ b/libs/rs/rsProgramVertex.cpp @@ -158,6 +158,8 @@ void ProgramVertex::setupGL2(const Context *rsc, ProgramVertexState *state, Shad //return; } + glVertexAttrib4f(1, state->color[0], state->color[1], state->color[2], state->color[3]); + const float *f = static_cast<const float *>(mConstants->getPtr()); Matrix mvp; @@ -259,6 +261,11 @@ void ProgramVertexState::init(Context *rsc, int32_t w, int32_t h) pv->init(rsc); pv->bindAllocation(alloc); + color[0] = 1.f; + color[1] = 1.f; + color[2] = 1.f; + color[3] = 1.f; + updateSize(rsc, w, h); } |