| 245 | void TrivialShader::ResetTintColor() { SetTintColor(1.0f, 1.0f, 1.0f); } |
| 246 | |
| 247 | void TrivialShader::SetTintColor(float r, float g, float b) { |
| 248 | mTint[0] = r; |
| 249 | mTint[1] = g; |
| 250 | mTint[2] = b; |
| 251 | |
| 252 | if (mPreparedVertexBuf) { |
| 253 | // we are in the middle of rendering, so push the new tint color to |
| 254 | // the shader right away. |
| 255 | glUniform4f(mTintLoc, mTint[0], mTint[1], mTint[2], 1.0f); |
| 256 | } |
| 257 | } |
| 258 | |
| 259 | void TrivialShader::BeginRender(VertexBuf* geom) { |
| 260 | // let superclass do the basic work |
no outgoing calls
no test coverage detected