aboutsummaryrefslogtreecommitdiff
path: root/include/ui/shader.h
AgeCommit message (Collapse)AuthorFilesLines
2017-10-17opengl: add flipping vertex shaderGerd Hoffmann1-1/+1
Add vertex shader which flips the texture upside down while blitting it. Add argument to qemu_gl_run_texture_blit() to enable flipping. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-id: 20171010135453.6704-4-kraxel@redhat.com
2017-10-17opengl: move shader init from console-gl.c to shader.cGerd Hoffmann1-8/+6
With the upcoming dmabuf support in qemu there will be more users of the shaders than just console-gl.c. So rename ConsoleGLState to QemuGLShader, rename some functions too, move code from console-gl.c to shaders.c. No functional change. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-id: 20171010135453.6704-3-kraxel@redhat.com
2015-10-08shaders: initialize vertexes onceGerd Hoffmann1-1/+3
Create a buffer for the vertex data and place vertexes there at initialization time. Then just use the buffer for each texture blit. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com>
2015-05-29ui: shader.h protect against double inclusionGerd Hoffmann1-0/+5
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com>
2015-05-29ui: use libexpoxyGerd Hoffmann1-4/+1
libepoxy does the opengl extension handling for us. It also is helpful for trouble-shooting as it prints nice error messages instead of silently failing or segfaulting in case we do something wrong, like using gl commands not supported by the current context. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com>
2015-05-05console-gl: add opengl rendering helper functionsGerd Hoffmann1-0/+2
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Reviewed-by: Max Reitz <mreitz@redhat.com>
2015-05-05opengl: add shader helper functions.Gerd Hoffmann1-0/+9
Helper functions to compile, link and run opengl shader programs. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>