| 971 | q.draw(rgbProgram->posLoc, rgbProgram->texcoordLoc); |
| 972 | } |
| 973 | void drawPalette(GLPaletteImage &img, Vec2<float> offset, Vec2<float> size, |
| 974 | Colour tint = {255, 255, 255, 255}) |
| 975 | { |
| 976 | bindProgram(paletteProgram); |
| 977 | Rect<float> pos(offset, offset + size); |
| 978 | bool flipY = false; |
| 979 | if (currentBoundFBO == 0) |
| 980 | flipY = true; |
| 981 | paletteProgram->setUniforms(this->currentSurface->size, flipY, tint); |
| 982 | BindTexture t(img.texID, 0); |
| 983 | |
| 984 | BindTexture p( |
| 985 | static_cast<GLPalette *>(this->currentPalette->rendererPrivateData.get())->texID, 1); |
| 986 | Quad q(pos, Rect<float>{{0, 0}, {1, 1}}); |
| 987 | q.draw(paletteProgram->posLoc, paletteProgram->texcoordLoc); |
| 988 | } |
| 989 | |
| 990 | void drawSurface(FBOData &fbo, Vec2<float> offset, Vec2<float> size, Scaler scaler, |
| 991 | Colour tint = {255, 255, 255, 255}) |
no test coverage detected