Matthew Waters
c06715bde6
glupload/download/convert: provide transform_caps functions
...
Allows finer grain decisions about formats and features at each
stage of the pipeline.
Also provide propose_allocation for glupload besed on the supported
methods.
2015-02-03 14:32:55 +11:00
Alessandro Decina
5f547c5600
gl: initial support for texture targets other than GL_TEXTURE_2D
...
Make GstGLMemory hold the texture target (tex_target) the texture it represents
(tex_id) is bound to. Modify gst_gl_memory_wrapped_texture and
gst_gl_download_perform_with_data to take the texture target as an argument.
This change is needed to support wrapping textures created outside libgstgl,
which might be bound to a target other than GL_TEXTURE_2D. For example on OSX
textures coming from VideoToolbox have target GL_TEXTURE_RECTANGLE.
With this change we still keep (and sometimes imply) GL_TEXTURE_2D as the
target of textures created with libgstgl.
API: modify GstGLMemory
API: modify gst_gl_memory_wrapped_texture
API: gst_gl_download_perform_with_data
2015-01-30 00:34:08 +11:00
Matthew Waters
9a55a3f98c
glmemory: use pbo's for download
...
In order to use pbo's efficiently, the transfer operation has to
be separated from the use of the downloaded data which requires some
rearchitecturing around glcolorconvert/gldownload and elements
2015-01-27 12:26:04 +11:00
Matthew Waters
d5c3693791
gl: split glcolorconvert usage from glupload
...
the separation allows the transfer operation to occur in a separate
thread/time which may increase performance in specific circumstances.
2015-01-14 22:22:13 +11:00
Nicolas Dufresne
9954de1ccd
gl: Add support for GstVideoAlignment
...
This allow saving a copy with libav video decoders or decoders with
similar padding requirement.
https://bugzilla.gnome.org/show_bug.cgi?id=740900
2014-12-19 12:11:08 -05:00
Matthew Waters
89636392fa
glmemory: use GstVideoInfo everywhere
...
Simplifies a lot of the calling code
https://bugzilla.gnome.org/show_bug.cgi?id=733717
2014-07-31 15:19:54 +10:00
Matthew Waters
7899b9af9f
gldownload: plug a memory leak
2014-06-15 15:17:07 +10:00
Matthew Waters
da35876537
glfeature: remove GST_GL_API_GLES3
...
instead check the gl version using gst_gl_context_check_gl_version()
2014-05-30 10:29:37 +10:00
Matthew Waters
9eb6f536b9
gl/download: use GstObject's lock instead of out own
2014-05-29 16:30:13 +10:00
Matthew Waters
f7f92e6d7a
gl/colorconvert: allocate output buffers
...
Allows the nop optimisation by simply reffing the input buffer.
2014-05-29 16:30:13 +10:00
Matthew Waters
60b6ef981e
gl/colorconvert: operate on buffers instead of memories
2014-05-27 21:59:12 +10:00
Matthew Waters
0fb0286553
gl/download: fixup YUY2/UYVY download
...
Regression from 2da979831e
as it did
not update the download code to reflect the change in texture format.
2014-05-22 23:55:30 +10:00
Matthew Waters
ce561913de
gl/download: update to be similar to the glupload semantics
2014-05-14 11:38:01 +10:00
Matthew Waters
34b55f33f2
gl/colorconvert: implement lazy init
2014-05-09 22:32:11 +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
Matthew Waters
a05d62d5ca
gl/color: pass large value by reference
...
Coverity 1199700
2014-04-12 18:18:08 +10:00
Matthew Waters
15d0c04933
gl/mem: allocate the memory per plane
...
This patch provides the basic infrastructure required for this.
Upload and Download has been ported to this.
Has the nice effect of allowing GstGLMemory to be our
refcounted texture object for any texture type (not just RGBA).
Should not lose any features/video formats.
2014-04-11 10:37:06 +10:00
Matthew Waters
95abfda139
gl: add colorconvert object that converts between color spaces/formats
...
Currently used by both upload and download objects separately.
2014-04-11 10:37:05 +10:00
Matthew Waters
48ef9402bf
gl/download: add support for the bt709 color matrix
2014-03-25 00:50:30 +11:00
Adrien SCH
08d71feaa4
[888/906] correct error handling in gstgldownload.c
2014-03-15 18:37:06 +01:00
Matthew Waters
b90d824626
[838/906] gl: Use GL_TEXTURE_2D instead of GL_TEXTURE_RECTANGLE
...
We create our textures (in Desktop GL) with GL_TEXTURE_RECTANGLE,
vaapi attempts to bind our texture to GL_TEXTURE_2D which throws a
GL_INVALID_OPERATION error and as thus, no video.
Also, by moving exclusively to GL_TEXTURE_2D and the npot extension
we also remove a difference between the Desktop GL and GLES2 code.
https://bugzilla.gnome.org/show_bug.cgi?id=712287
2014-03-15 18:37:03 +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
4f356f999c
[782/906] gldownload: Use strlen() instead of sizeof(char*)
...
gstgldownload.c:846:22: error: argument to 'sizeof' in 'memcpy' call is the same expression as the source; did you mean to provide an explicit length? [-Werror=sizeof-pointer-memaccess]
2014-03-15 18:37:00 +01:00
Matthew Waters
3130ac1596
[781/906] download: propogate errors from the GL thread
2014-03-15 18:37:00 +01:00
Matthew Waters
41a89bafce
[779/906] download: remove _thread variants of the API
2014-03-15 18:37:00 +01:00
Matthew Waters
26e46d449c
[776/906] download: fix compiler warning about missing string format
2014-03-15 18:37:00 +01:00
Sebastian Dröge
1a6b357b39
[759/906] gldownload: #ifdef some GLES2 specific code to fix compilation
2014-03-15 18:36:59 +01:00
Sebastian Dröge
7551b627e8
[756/906] gldownload: Reset the viewport after download RGB via GLES2
2014-03-15 18:36:59 +01:00
Sebastian Dröge
62f9105715
[755/906] gldownload: Unbind framebuffer after downloading RGB with GLES2
2014-03-15 18:36:59 +01:00
Sebastian Dröge
743ad83b06
[754/906] gldownload: Add support for RGB reordering when using GLES2
2014-03-15 18:36:58 +01:00
Sebastian Dröge
258bb6fb81
[748/906] glupload: GL_STENCIL_ATTACHMENT is needed for desktop GL, not GLES
2014-03-15 18:36:58 +01:00
Sebastian Dröge
f36efba6da
[747/906] gl: Constify YUV conversion shaders
2014-03-15 18:36:58 +01:00
Sebastian Dröge
01ce41f684
[745/906] gl: Simplify and optimize YUV conversion shaders a bit
2014-03-15 18:36:58 +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
13067b104c
[704/906] Use gst_object_[un]ref so we can get refcounts in the log
2014-03-15 18:36:56 +01:00
Matthew Waters
dbeb6a911b
[701/906] display: move context creation into window
2014-03-15 18:36:55 +01:00
Matthew Waters
96114e62cb
[699/906] display: remove list of upload and download objects
...
and only create an up/download object when needed.
2014-03-15 18:36:55 +01:00
Matthew Waters
3d75c3d5af
[655/906] download: remove erronous ReadBuffer call
...
- it was causing segfaults in mesa
- we didn't set the readbuffer so we shouldn't reset it
2014-03-15 18:36:53 +01:00
Matthew Waters
6bee1ffdd3
[651/906] up/download: fix some typos when removing GLEW
2014-03-15 18:36:52 +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
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
Matthew Waters
12bf1cfa27
[600/906] docs: add docs for new objects and expand on some existing ones
2014-03-15 18:36:49 +01:00
Matthew Waters
11508f6f7a
[599/906] GL|ES2: fix typos from recent changes and make downloading RGB formats work again
2014-03-15 18:36:49 +01:00
Matthew Waters
4716682c55
[590/906] up/download: fix scaling on transfer
...
i.e. uploading from a 10x10 video frame to a 20x20 texture into another 30x30 videoframe
2014-03-15 18:36:49 +01:00
Matthew Waters
cfafeea297
[579/906] download: fix YV12 format
...
same as I420 but plane 1+2 swapped
2014-03-15 18:36:48 +01:00
Matthew Waters
5aa048e53b
[578/906] {up,down}load: add variants that can be called in the gl thread
2014-03-15 18:36:48 +01:00
Matthew Waters
88cb7e3060
[573/906] add upload and download library objects
...
allows multiple upload pipelines that previously wasn't possible
(i.e. upload RGB and I420 and ... on the same GstGLDisplay)
2014-03-15 18:36:48 +01:00