Commit graph

23 commits

Author SHA1 Message Date
Matthew Waters
d38587c142 glshader: add glBindFragDataLocation
There are some cases where it's needed for binding in/out variables in shaders.
e.g. glsl 150 (gl 3.2) doesn't support the 'layout (location = ?)' specifiers in
the shader source so we have to bind them ourselves.
2016-03-31 20:52:42 +11:00
Matthew Waters
3dfc6899ad gl: be consistent in gobject boilerpate
GST_GL_IS_* vs GST_IS_GL_*

git grep -l 'GST_GL_IS_' | xargs sed -i 's/GST_GL_IS_/GST_IS_GL_/g'
2015-10-19 15:15:30 +11:00
Matthew Waters
b25807c382 glshader: port to using GstGLSLStage objects for string management
A GstGLShader is now simply a collection of stages that are
compiled and linked together into a program.  The uniform/attribute
interface has remained the same.
2015-10-15 21:27:57 +11:00
Matthew Waters
fca0bc97a4 glshader add support for gl3 2014-11-28 09:14:25 +11:00
Matthew Waters
d2cbc7cc16 glshader: advertise the default vertex and fragment shaders on desktop GL 2014-10-30 18:58:49 +11:00
Lubosz Sarnecki
d2cac06eeb glshader: expose opengl handle in getter
https://bugzilla.gnome.org/show_bug.cgi?id=734482
2014-08-21 17:38:36 +10:00
Matthew Waters
c247be334a gl: make all GObjects inherit from GstObject
Aids memory leak debugging with GST_TRACE=mem-live
2014-05-08 15:33:43 +10:00
Julien Isorce
64e5b5a203 gl: add convenient functions to setup default vertex and fragment shaders
Most of our 2D filters use the same simple vertex shader.
Also define the default fragment shader as the identity.

Avoid duplicating the same vertex and fragment shader text.
2014-04-30 15:35:49 +01:00
Matthew Waters
9b22b0e0ba [812/906] move the GL vtable from GstGLDisplay to GstGLContext
Conflicts:
	tests/check/libs/gstglcontext.c
2014-03-15 18:37:02 +01:00
Sebastian Dröge
a5a46aa833 [733/906] gl: Major header and include cleanup 2014-03-15 18:36:57 +01:00
Julien Isorce
dd7e054e2c [732/906] build: fix repeated typedefs
Write forward declarations in another way to avoid
repeated typedefs "error: redefinition of typedef".
Raised when using i686-apple-darwin11-llvm-gcc-4.2
It seems that C apple compiler does not support
C11 feature.

https://bugzilla.gnome.org/show_bug.cgi?id=703885
2014-03-15 18:36:57 +01:00
Matthew Waters
7b03a572d9 [647/906] remove dependecy on glew 2014-03-15 18:36:52 +01:00
Matthew Waters
fa3c3b8434 [642/906] add gstglconfig.h for apps to find out what our capabilites are
ie libgstgl can be compiled with any combination of opengl/gles2
2014-03-15 18:36:52 +01:00
Matthew Waters
ca661a7719 [631/906] remove redefinition warnings in compiling tests 2014-03-15 18:36:51 +01:00
Matthew Waters
cc8e54541b [624/906] OPENGL_ES2 => HAVE_GLES2 and add HAVE_OPENGL
use GstGLAPI to determine which code paths to execute.
perform some cleanups
2014-03-15 18:36:51 +01:00
Matthew Waters
93f7e993ad [603/906] update FSF address 2014-03-15 18:36:50 +01:00
Julien Isorce
591b4282ed [477/906] OpenGL ES 2.0: fix build since glfiltershader changes 2014-03-15 18:36:42 +01:00
Luc Deschenaux
268f1a30b2 [471/906] glshader: add dynamic fragment shader filter
Also add fragment shader parser
Fix bug #600195
2014-03-15 18:36:42 +01:00
Julien Isorce
d21aaa22bf [467/906] tests: various build fixes
- cmake could not find glib
 - put gtk variables at the beginning to avoid GL conflicts
 - update examples to clutter-1.8
 - use const instead of deprecated G_CONST_RETURN
 - set max pending events to 0 to make cube example works again
2014-03-15 18:36:42 +01:00
Julien Isorce
db7d436bd8 [387/906] glmixer: add a glmixer base element
glmixer can be seen as a glfilter except it handles N requested
sink pads.
Each sink pad and the src pad are video/x-raw-gl.
glmixer is responsible for managing different framerates from inputs.
It uses OpenGL context sharing. It means that each input is in its
own OpenGL context shared together and shared with the OpenGL context
of the ouput gl chain.
Also add a glmosaic which is an example of implementation of glmixer.
For now glmosaic is a cube but it will be fixed in the next commits.
For now the glmixer has some weird behaviours in some configurations
but it will be improved in the next commits.
The autotools builds is temporarly broken since those changes
have been made on win32.
2014-03-15 18:36:37 +01:00
Julien Isorce
ec0bb66fe9 [321/906] add OpenGL ES 2.x support.
In OpenGL 2.x for Embedded System, a lot of basic scene/draw functions
have been removed. It means that everything is made using vertex and
fragment shaders.
I have also added a gstglwindow backend for winCE that uses EGL
(Native Platform Graphics Intercace) (which is a full part of
OpenGL ES specification). It remove the use of wgl/glx functions.
2014-03-15 18:36:33 +01:00
Julien Isorce
10853e1c2f [212/906] add a glbumper (bump mapping filter through GLSL) that exposes how to use both vertex and fragment shaders 2014-03-15 18:36:27 +01:00
Filippo Argiolas
aeadf6bc0e [127/906] Imported GstGLShader from cvs branch. Added a demo laplacian convolution filter to demonstrate how this can be integrated with minimum effort. 2014-03-15 18:36:22 +01:00