| 192 | LogError("\"tint\" uniform not found in shader"); |
| 193 | } |
| 194 | void setUniforms(Vec2<int> screenSize, bool flipY, Colour tint = {255, 255, 255, 255}, |
| 195 | GLint texUnit = 0) |
| 196 | { |
| 197 | if (screenSize != currentScreenSize) |
| 198 | { |
| 199 | currentScreenSize = screenSize; |
| 200 | this->uniform(this->screenSizeLoc, screenSize); |
| 201 | } |
| 202 | if (texUnit != currentTexUnit) |
| 203 | { |
| 204 | currentTexUnit = texUnit; |
| 205 | this->uniform(this->texLoc, texUnit); |
| 206 | } |
| 207 | if (flipY != currentFlipY) |
| 208 | { |
| 209 | currentFlipY = flipY; |
| 210 | this->uniform(this->flipYLoc, flipY); |
| 211 | } |
| 212 | if (tint != currentTint) |
| 213 | { |
| 214 | currentTint = tint; |
| 215 | this->uniform(this->tintLoc, tint); |
| 216 | } |
| 217 | } |
| 218 | }; |
| 219 | const char *PaletteProgram_vertexSource = { |
| 220 | "#version 110\n" |
no test coverage detected