summaryrefslogtreecommitdiff
path: root/gdk/resources
Commit message (Collapse)AuthorAgeFilesLines
* Use GLSL version 110 for OpenGL 2 shaders.Juan Pablo Ugarte2016-11-016-12/+4
| | | | | | | | According to docs and Intel legacy drivers, GLSL version 130 is for GL 3.0 not GL 2.0/2.1 Validated files with reference compiler from https://www.khronos.org/opengles/sdk/tools/Reference-Compiler/
* gl: Use a uniform to flip R and B colors on GLESEmmanuele Bassi2016-04-251-2/+6
| | | | | | | | | | | | This allows us to decide when the R and B color channels should be flipped with a much better granularity. For instance, when using GLX_EXT_texture_from_pixmap to create a GL texture from a surface we don't need to swap the R and B channels, as the internal representation of the texture data will already have the appropriate colors. We also don't need to flip color channels when blitting from a texture.
* gl: Tweak the swizzle for GLES texture fragmentsEmmanuele Bassi2016-04-251-1/+4
| | | | | | | | | | Cairo surfaces are in BGRA format, but we upload them as RGBA buffers on GLES; this means that the R and B channels are flipped in the texture data. Instead of doing a costly channel flip before putting them on the GPU, we can flip the values inside the GLSL shader we use specifically for GLES.
* gdk: Add GLES shadersEmmanuele Bassi2016-04-252-0/+19
| | | | We cannot use GL shaders with GLES.
* gdk: Move GLSL shaders into GResourceEmmanuele Bassi2016-04-258-0/+90
Having the shaders inlined as C strings makes them harder to edit and maintain.