Matthew Waters [Thu, 12 Jun 2014 13:14:45 +0000 (23:14 +1000)]
glfilterapp: actually emit the client-draw signal
Matthew Waters [Thu, 12 Jun 2014 13:13:11 +0000 (23:13 +1000)]
gl/examples: update for TEXTURE_2D change
Matthew Waters [Thu, 12 Jun 2014 04:58:47 +0000 (14:58 +1000)]
glmixer: send the stream-start event
and the caps event after.
https://bugzilla.gnome.org/show_bug.cgi?id=730944
Matthew Waters [Thu, 12 Jun 2014 03:37:51 +0000 (13:37 +1000)]
gl/examples: add GST_PLUGINS_BASE_CFLAGS
Matthew Waters [Thu, 12 Jun 2014 03:15:10 +0000 (13:15 +1000)]
gl/examples: remove spurious include for doublecube example
Matthew Waters [Thu, 12 Jun 2014 03:06:31 +0000 (13:06 +1000)]
gl/examples: add the srcdir and builddir includes
And remove references to $(GST_PLUGINS_GL_*)
Matthew Waters [Thu, 12 Jun 2014 02:49:42 +0000 (12:49 +1000)]
glfilterapp: remove the reshape/draw properties
The reshape property was never used.
Replace the draw property with a signal.
Based on patch by Mathieu Duponchelle <mathieu.duponchelle@epitech.eu>
https://bugzilla.gnome.org/show_bug.cgi?id=704507
Matthew Waters [Thu, 12 Jun 2014 02:14:35 +0000 (12:14 +1000)]
glmixer: lock the size of mix->frames to the number of pads
Fixes a segfault with decodebin ! glmixer where the request pads on
both sides were being requested after the state change to PAUSED.
Also fixes dynamically adding and removing pads while glmixer is
in a state >= PAUSED.
Matthew Waters [Thu, 12 Jun 2014 02:09:56 +0000 (12:09 +1000)]
gl/examples: Port to using signals instead of properties
Based on patch by Mathieu Duponchelle <mathieu.duponchelle@epitech.eu>
https://bugzilla.gnome.org/show_bug.cgi?id=704507
Matthew Waters [Sun, 1 Jun 2014 05:02:52 +0000 (15:02 +1000)]
glimagesink: replace pointer properties with signals
Based on patch by Mathieu Duponchelle <mathieu.duponchelle@epitech.eu>
https://bugzilla.gnome.org/show_bug.cgi?id=704507
Matthew Waters [Thu, 5 Jun 2014 08:43:30 +0000 (18:43 +1000)]
gl/wayland: create a dummy display instead of an EGLDisplay
Currently, GstGLWindowWaylandEGL holds the wayland display connection
If we create the EGLDisplay at the GstDisplay creation time, then
libEGL will internally open another connection to the wayland server.
These two display connections are unable to communicate resulting in
no window output/display and hangs inside libEGL.
Eventually we will move the wl_display from GstGLWindow to GstGLDisplay.
Matthieu Bouron [Sun, 25 May 2014 20:43:22 +0000 (21:43 +0100)]
glimagesink: improve state change debug message
Matthew Waters [Tue, 3 Jun 2014 03:59:51 +0000 (13:59 +1000)]
glupload: always release the previous buffer
Fixes the case where _perform_with_buffer() is called without
intervening calls to _release_buffer() as is the case on start up
with glimagesink.
Also release the buffer when reseting the upload.
https://bugzilla.gnome.org/show_bug.cgi?id=731107
Sebastian Dröge [Mon, 2 Jun 2014 07:23:39 +0000 (09:23 +0200)]
glcontext: Handle (unlikely) NULL return of gl->GetString (GL_VERSION) more gracefully
CID 1219858
Matthew Waters [Fri, 30 May 2014 02:23:09 +0000 (12:23 +1000)]
glmemory: remove uneeded gl api ifdefs
Matthew Waters [Fri, 30 May 2014 01:51:01 +0000 (11:51 +1000)]
glwindow_x11: allow expose events to redraw our window
otherwise we will not update the window contents on low framerate
streams until the next buffer
https://bugzilla.gnome.org/show_bug.cgi?id=723529
Matthew Waters [Fri, 30 May 2014 01:46:00 +0000 (11:46 +1000)]
glimagesink: unref the old buffer outside the lock
it could very well deadlock
https://bugzilla.gnome.org/show_bug.cgi?id=723529
Matthew Waters [Fri, 30 May 2014 01:35:04 +0000 (11:35 +1000)]
Revert "[880/906] glimagesink: remove unused stored_buffer field"
This reverts commit
af3a68db7dc473fb6903c18966b39e4c3f1464d7.
Conflicts:
ext/gl/gstglimagesink.c
https://bugzilla.gnome.org/show_bug.cgi?id=723529
Matthew Waters [Fri, 30 May 2014 00:46:25 +0000 (10:46 +1000)]
glcontext: fix up assertion
error: 'return' with no value, in function returning non-void
Matthew Waters [Fri, 30 May 2014 00:27:14 +0000 (10:27 +1000)]
glfeature: remove GST_GL_API_GLES3
instead check the gl version using gst_gl_context_check_gl_version()
Matthew Waters [Fri, 30 May 2014 00:25:18 +0000 (10:25 +1000)]
glcontext: check for GLES versions
Matthew Waters [Thu, 29 May 2014 10:35:48 +0000 (20:35 +1000)]
gl/context: add check_gl_version
Edward Hervey [Thu, 29 May 2014 15:09:26 +0000 (17:09 +0200)]
glcontext: Try GLX support before EGL support
If available, glx has got a better chance of being the Gl platform
we want to use compared to EGL
Edward Hervey [Thu, 29 May 2014 14:59:28 +0000 (16:59 +0200)]
glcontext: Try to open lib{EGL|GL|GLESv2}.so.1 before lib{EGL|GL|GLESv2}
Fixes issues with .so (without numbering) being installed for development
(such as from mesa-dev) but actual driver (with numbering) coming from
some other place (like nvidia drivers)
Sebastian Dröge [Thu, 29 May 2014 08:37:02 +0000 (10:37 +0200)]
glupload: Fix assertion after API changes
Matthew Waters [Thu, 29 May 2014 08:33:10 +0000 (18:33 +1000)]
gl/colorconvert: keep our private pointer
again, avoid to much trigger
Matthew Waters [Thu, 29 May 2014 08:32:48 +0000 (18:32 +1000)]
tests: update for glupload changes
Matthew Waters [Thu, 29 May 2014 07:29:41 +0000 (17:29 +1000)]
gl/colorconvert: use GstObject's lock instead of our own
Matthew Waters [Thu, 29 May 2014 07:12:03 +0000 (17:12 +1000)]
gl/colorconvert: remove unnecassary pointer inderection
Matthew Waters [Thu, 29 May 2014 06:45:37 +0000 (16:45 +1000)]
gl/upload: re add the upload meta to the private struct
try and avoid being to trigger happy
Matthew Waters [Thu, 29 May 2014 06:29:09 +0000 (16:29 +1000)]
gl/upload: small code cleanup and gst-indent
Matthew Waters [Thu, 29 May 2014 06:22:52 +0000 (16:22 +1000)]
gl/download: use GstObject's lock instead of out own
Matthew Waters [Thu, 29 May 2014 06:20:30 +0000 (16:20 +1000)]
gl/upload: use GstObject's lock instead of our own
Matthew Waters [Thu, 29 May 2014 06:18:08 +0000 (16:18 +1000)]
gl/filter: also remove the width/height in transform_caps
allows scaling in the filters
Matthew Waters [Thu, 29 May 2014 06:11:20 +0000 (16:11 +1000)]
gl/colorconvert: optimise the same format case
simply return the input buffer unchanged
Matthew Waters [Thu, 29 May 2014 06:07:40 +0000 (16:07 +1000)]
gl/colorconvert: fix YUY2/UYVY download for RG/LA textures
Matthew Waters [Thu, 29 May 2014 05:50:56 +0000 (15:50 +1000)]
gl/colorconvert: allocate output buffers
Allows the nop optimisation by simply reffing the input buffer.
Matthew Waters [Wed, 28 May 2014 13:21:07 +0000 (23:21 +1000)]
tests: update for recent glupload changes
GstGLUploadMeta object is now the GstVideoGLTextureUploadMeta
provider.
Matthew Waters [Wed, 28 May 2014 04:43:43 +0000 (14:43 +1000)]
gl/upload: fix incorrect type in macros
Matthew Waters [Wed, 28 May 2014 04:40:10 +0000 (14:40 +1000)]
gl/upload: add GstGLUploadMeta object
That simply deals with the provider aspect of GstVideoGLTextureUploadMeta.
Matthew Waters [Tue, 27 May 2014 14:56:05 +0000 (00:56 +1000)]
gl/win32: make send_message reentrant
I could not find a comparable win32API function so keep the running
thread pointer to compare against.
https://bugzilla.gnome.org/show_bug.cgi?id=730782
Tim-Philipp Müller [Tue, 27 May 2014 12:56:34 +0000 (13:56 +0100)]
glcolorconvert: fix compiler warning
gstglcolorconvert.c:1133:11: error: 'j' may be used uninitialized in this function
Was used uninitialized when jumping to out label
in error case.
Matthew Waters [Tue, 27 May 2014 08:20:29 +0000 (18:20 +1000)]
gl/colorconvert: operate on buffers instead of memories
Julien Isorce [Tue, 27 May 2014 10:28:27 +0000 (11:28 +0100)]
glimagesink: make it actually honor show-preroll-frame property
https://bugzilla.gnome.org/show_bug.cgi?id=730802
Julien Isorce [Tue, 27 May 2014 07:54:20 +0000 (08:54 +0100)]
gl: add missing cgl and eagl context type
https://bugzilla.gnome.org/show_bug.cgi?id=729245
Julien Isorce [Tue, 27 May 2014 07:46:16 +0000 (08:46 +0100)]
gl: rename platform cocoa to cgl
Before:
GST_GL_PLATFORM=cocoa GST_GL_WINDOW=cocoa
gst-launch-1.0 videotestsrc ! glimagesink
After:
GST_GL_PLATFORM=cgl GST_GL_WINDOW=cocoa
gst-launch-1.0 videotestsrc ! glimagesink
but still pass --enable-cocoa to configure script
because currently it can only be used with cocoa API.
We could later have cgl/gstglcontext_cgl.h that manages
a CGLContextObj directly and cocoa/gstglcontext_cocoa.h
would just wrap it.
So that it could be used with other Apple's window APIs.
https://bugzilla.gnome.org/show_bug.cgi?id=729245
Matthew Waters [Tue, 27 May 2014 03:55:15 +0000 (13:55 +1000)]
gl/mixer: don't segfault when we don't have a buffer
https://bugzilla.gnome.org/show_bug.cgi?id=729257
Matthew Waters [Tue, 27 May 2014 03:04:39 +0000 (13:04 +1000)]
gl/window_x11: avoid BadDrawable error on shutdown
Matthew Waters [Tue, 27 May 2014 00:47:25 +0000 (10:47 +1000)]
gl/context_egl: pass the vars in the right order to DestroySurface
https://bugzilla.gnome.org/show_bug.cgi?id=728514
Nicolas Dufresne [Sun, 25 May 2014 13:03:32 +0000 (09:03 -0400)]
glfilter: Remove format information to allow color convert again
We also need to remove the format information, as glfilter can do
color convertion. This code was imported from videoconvert.
https://bugzilla.gnome.org/show_bug.cgi?id=729861
Matthew Waters [Sun, 25 May 2014 01:44:57 +0000 (11:44 +1000)]
gl/memory: allocate the correct memory size
and avoid wasting resources we will never need
https://bugzilla.gnome.org/show_bug.cgi?id=730703
Nicolas Dufresne [Sat, 24 May 2014 03:02:32 +0000 (23:02 -0400)]
glcolorconvert: Fix YUY2 and UYVY support with luminance_alpha
https://bugzilla.gnome.org/show_bug.cgi?id=730666
Matthew Waters [Fri, 23 May 2014 02:07:50 +0000 (12:07 +1000)]
gl/memory: provide compatability defines
fixes build on android/OS X
Matthew Waters [Fri, 23 May 2014 01:01:06 +0000 (11:01 +1000)]
gl/colorconvert: remove scratch texture for YUY2/UYVY
We can get all our data from the one RG/LA texture with some shader magic.
https://bugzilla.gnome.org/show_bug.cgi?id=728890
Matthew Waters [Fri, 23 May 2014 00:59:05 +0000 (10:59 +1000)]
gl/memory: RGBA/UNSIGNED_BYTE only format supported by ReadPixels GLES2
Error out in case we attempt to read with any other invalid format.
Matthew Waters [Fri, 23 May 2014 00:57:24 +0000 (10:57 +1000)]
gl/memory: generate textures with a sized internal format
Required in order to generate RG and RED textured with GLES3.
Matthew Waters [Wed, 21 May 2014 11:47:45 +0000 (21:47 +1000)]
gl/memory: implement GL_EXT_texture_rg support
Which is used by default over the Luminance formats due to it
being color renderable with fbos (and deprecation/removal with
GL 3.x).
https://bugzilla.gnome.org/show_bug.cgi?id=729750
https://bugzilla.gnome.org/show_bug.cgi?id=704222
https://bugzilla.gnome.org/show_bug.cgi?id=728890
Matthew Waters [Wed, 21 May 2014 11:44:40 +0000 (21:44 +1000)]
gl/context: add gl extension checking to check_feature()
Useful for extensions that do not define any new GL API entrypoints
but can still modify behaviour when used.
Matthew Waters [Wed, 21 May 2014 10:36:37 +0000 (20:36 +1000)]
gl/download: fixup YUY2/UYVY download
Regression from
2da979831ec3b1a8d993eb6f2d3999c5810c4d67 as it did
not update the download code to reflect the change in texture format.
Matthew Waters [Wed, 21 May 2014 09:47:22 +0000 (19:47 +1000)]
gl/filter: fixup passthrough bufferpool
In a pipeline like so:
videotestsrc ! gleffects ! videoconvert ! sink
gleffects was simply passing the videoconvert bufferpool to videotestsrc
and not creating a glbufferpool. videobufferpool would then fail
to allocate from the glallocator.
Matthew Waters [Wed, 21 May 2014 00:26:21 +0000 (10:26 +1000)]
gl/upload: switch the 'master' texture for YUY2, UYVY
From
d4bcef3204709159713ff1630978ecac0bd91dc9 on, using a RGBA
texture to hold the data causes the glmemory to have half width
and a scaling of [2, 1]. Using a LA texture solves this problem
however cannot be attached to the framebuffer for copying into
a RGBA texture. Which will be solved by moving to EXT_texture_rg.
https://bugzilla.gnome.org/show_bug.cgi?id=728890
Matthew Waters [Wed, 14 May 2014 07:59:52 +0000 (17:59 +1000)]
gl/eglimage: add eglimage context feature
Allows us to selectively use EGLImages only when available
https://bugzilla.gnome.org/show_bug.cgi?id=728234
Matthew Waters [Wed, 14 May 2014 07:33:21 +0000 (17:33 +1000)]
gl/context: add generic feature checking
At the moment it simply delegates to the subclass.
Sebastian Dröge [Mon, 19 May 2014 10:25:51 +0000 (12:25 +0200)]
glimagesink: Check if context creation failed before trying to use it
Otherwise we will cause assertions everywhere by passing NULL to functions
and eventually crash when dereferencing a NULL pointer.
https://bugzilla.gnome.org/show_bug.cgi?id=730069
Sebastian Dröge [Mon, 19 May 2014 10:21:13 +0000 (12:21 +0200)]
glcontext: Add more assertions to make sure that everything sets the GError during context creation if something fails
Matthew Waters [Tue, 13 May 2014 04:13:57 +0000 (14:13 +1000)]
gl/download: update to be similar to the glupload semantics
Matthew Waters [Tue, 13 May 2014 04:07:39 +0000 (14:07 +1000)]
gl/colorconvert: fix up alpha clobbering
Previously it would only work if the alpha value was in the last
component (RGBx, BGRx). Now it works wherever the alpha value may
be (xRGB, xBGR, etc).
Nicolas Dufresne [Tue, 13 May 2014 17:16:34 +0000 (13:16 -0400)]
glfilter: Fix building without EGL support
This fixes the OSX build and any builds with --disable-egl. That issue
was introduced in "glfilter: rewrite transform_caps to preserve caps fields".
https://bugzilla.gnome.org/show_bug.cgi?id=729861
Julien Isorce [Tue, 13 May 2014 12:30:47 +0000 (13:30 +0100)]
glfilter: rewrite transform_caps to preserve caps fields
https://bugzilla.gnome.org/show_bug.cgi?id=729861
Matthew Waters [Tue, 13 May 2014 00:53:19 +0000 (10:53 +1000)]
gl/colorconvert: use the texture scaling from the gl memory
The colorconvert values were not being used at all.
https://bugzilla.gnome.org/show_bug.cgi?id=729896
Nicolas Dufresne [Mon, 12 May 2014 23:29:45 +0000 (19:29 -0400)]
glmemory: Fix handling of stride with alignement larger then 8
Setting a scaled factor for X coordinate is not enough as the indexer
will still think stride is shorter and will not fully skip it. Instead,
update width, so the lines are as expected. Combined with the scale, it
will hide the cropped portion.
https://bugzilla.gnome.org/show_bug.cgi?id=729896
Nicolas Dufresne [Mon, 12 May 2014 17:50:47 +0000 (13:50 -0400)]
glupload: Ensure we still have a texture after upload_set_format()
gst_gl_upload_set_format() resets the upload, hence the texture.
So we need to ensure we have a texture after this call when
uploading.
Nicolas Dufresne [Mon, 12 May 2014 16:59:59 +0000 (12:59 -0400)]
glupload: Correctly update the video info from video meta
Using gst_video_info_set_format() isn't complete when updating
a video info from video meta.
Nicolas Dufresne [Mon, 12 May 2014 16:57:18 +0000 (12:57 -0400)]
glupload: Correctly update video info in upload fallback
When the upload accelerated method fails, we fallback to an upload,
but the video info was not correctly updated.
Julien Isorce [Mon, 12 May 2014 12:32:31 +0000 (13:32 +0100)]
gl/upload: set out_tex after reset, not before
Fix a regression introduced recently with the lazy init.
It was happening when calling gst_video_gl_texture_upload_meta_upload
from an aplication. So not using gst_gl_upload_perform_with_buffer.
Matthew Waters [Sun, 11 May 2014 02:48:52 +0000 (12:48 +1000)]
gl/upload: update the video info on mapping a video frame
The buffer should contain the most specific data on how the data is
formatted. We should use this information.
https://bugzilla.gnome.org/show_bug.cgi?id=729896
Matthew Waters [Mon, 12 May 2014 11:56:06 +0000 (21:56 +1000)]
gl/convert: clobber alpha channel when needed
Needed in the conversion from padded RGB formats to formats with an
alpha channel. e.g. BGRx -> ABGR, etc
https://bugzilla.gnome.org/show_bug.cgi?id=729742
Matthew Waters [Mon, 12 May 2014 11:51:38 +0000 (21:51 +1000)]
gl/upload: avoid performing color conversion when there is no need
One such example is when the buffer contains GstGLMemory in the
RGBA format
https://bugzilla.gnome.org/show_bug.cgi?id=729278
Matthew Waters [Sun, 11 May 2014 04:02:34 +0000 (14:02 +1000)]
gl/colorconvert: choose the right alpha component for AYUV -> RGBA
Matthew Waters [Sun, 11 May 2014 00:27:02 +0000 (10:27 +1000)]
gl/upload: update the respective state when we cache textures/data
Matthew Waters [Sat, 10 May 2014 13:33:24 +0000 (23:33 +1000)]
gl/upload: cache the textures that we are using
Matthew Waters [Sat, 10 May 2014 12:48:05 +0000 (22:48 +1000)]
gl/upload: avoid recreating the GLMemory struct for output textures
Nicolas Dufresne [Fri, 9 May 2014 22:59:46 +0000 (18:59 -0400)]
gl: Fix some of the error handling
Nicolas Dufresne [Fri, 9 May 2014 21:59:43 +0000 (17:59 -0400)]
glupload: Update GstVideoInfo after the buffer is mapped
gst_video_frame_map() will store an updated video info base
on the video meta. In order to have the right stride and offset
we should update that video info accordingly.
Sebastian Dröge [Fri, 9 May 2014 13:42:08 +0000 (15:42 +0200)]
gl: Fix memory leak
CID #1212171
Matthew Waters [Fri, 9 May 2014 12:22:43 +0000 (22:22 +1000)]
gl/colorconvert: preserve alpha in AYUV <-> RGBA conversions
https://bugzilla.gnome.org/show_bug.cgi?id=729743
Matthew Waters [Fri, 9 May 2014 08:07:03 +0000 (18:07 +1000)]
gl/colorconvert: implement lazy init
Julien Isorce [Thu, 8 May 2014 14:38:24 +0000 (15:38 +0100)]
gl/upload: set initted to TRUE when _init_upload succeeded
Sebastian Dröge [Thu, 8 May 2014 20:49:33 +0000 (22:49 +0200)]
gldisplay: Use GST_STR_NULL() for printing possibly NULL strings and print all variables we use
Fixes compiler warning about set but not used platform_choice variable
among other things.
Julien Isorce [Thu, 8 May 2014 15:08:08 +0000 (16:08 +0100)]
gleffects: use gl_vtable
Matthew Waters [Thu, 8 May 2014 07:28:11 +0000 (17:28 +1000)]
gl/upload: fix compilation on OS X
Matthew Waters [Thu, 8 May 2014 05:40:33 +0000 (15:40 +1000)]
gl/upload: fail propoerly if init fails
Matthew Waters [Thu, 8 May 2014 05:30:49 +0000 (15:30 +1000)]
gl: make all GObjects inherit from GstObject
Aids memory leak debugging with GST_TRACE=mem-live
Matthew Waters [Thu, 8 May 2014 03:46:29 +0000 (13:46 +1000)]
gl/upload: implement lazy init
Rename init_format to set_format
Matthew Waters [Wed, 7 May 2014 14:59:42 +0000 (00:59 +1000)]
gl/upload: add get_format method
Simply retreives the format set by init_format
Matthew Waters [Wed, 7 May 2014 14:48:07 +0000 (00:48 +1000)]
gl/filter: attempt to passthrough the pool if the caps are the same
Reduces the number of glbufferpool instances required for >=2
consecutive GL elements in a pipeline.
Matthew Waters [Wed, 7 May 2014 14:43:14 +0000 (00:43 +1000)]
gl/filter: always initialize the upload object
Matthew Waters [Wed, 7 May 2014 11:45:53 +0000 (21:45 +1000)]
gl: advertise GstGLMemory usage in the caps as capsfeatures
https://bugzilla.gnome.org/show_bug.cgi?id=729658
Matthew Waters [Wed, 7 May 2014 10:12:23 +0000 (20:12 +1000)]
gl/examples: fix compilation for clutter examples
ClutterX11TexturePixmap is deprecated in Clutter 1.6 and we ask for
at least 1.8
Matthew Waters [Wed, 7 May 2014 09:05:55 +0000 (19:05 +1000)]
gl/display: avoid endless recursion for cocoa