gl: enable glvideomixer on GLES2

This commit is contained in:
Julien Isorce 2014-06-22 13:14:27 +01:00 committed by Tim-Philipp Müller
parent d86208e6ad
commit c18a109b42
3 changed files with 11 additions and 8 deletions

View file

@ -29,8 +29,6 @@ OPENGL_SOURCES = \
gstgltestsrc.h \
gstglmosaic.c \
gstglmosaic.h \
gstglvideomixer.c \
gstglvideomixer.h \
effects/gstgleffectscurves.h \
effects/gstgleffectstretch.c \
effects/gstgleffecttunnel.c \
@ -74,6 +72,8 @@ libgstopengl_la_SOURCES = \
effects/gstgleffectsqueeze.c \
gstglcolorscale.c \
gstglcolorscale.h \
gstglvideomixer.c \
gstglvideomixer.h \
$(OPENGL_SOURCES)
if HAVE_GRAPHENE

View file

@ -81,6 +81,9 @@ static const gchar *video_mixer_v_src =
/* fragment source */
static const gchar *video_mixer_f_src =
"#ifdef GL_ES\n"
"precision mediump float;\n"
"#endif\n"
"uniform sampler2D texture; \n"
"uniform float alpha;\n"
"varying vec2 v_texCoord; \n"

View file

@ -48,6 +48,7 @@
#include "gstglfiltercube.h"
#include "gstgleffects.h"
#include "gstglcolorscale.h"
#include "gstglvideomixer.h"
#if HAVE_GRAPHENE
#include "gstgltransformation.h"
#endif
@ -63,7 +64,6 @@
#include "gstglfiltersobel.h"
#include "gstgldeinterlace.h"
#include "gstglmosaic.h"
#include "gstglvideomixer.h"
#if HAVE_PNG
#include "gstgldifferencematte.h"
#include "gstglbumper.h"
@ -124,6 +124,11 @@ plugin_init (GstPlugin * plugin)
GST_RANK_NONE, GST_TYPE_GL_COLORSCALE)) {
return FALSE;
}
if (!gst_element_register (plugin, "glvideomixer",
GST_RANK_NONE, GST_TYPE_GL_VIDEO_MIXER)) {
return FALSE;
}
#if GST_GL_HAVE_OPENGL
if (!gst_element_register (plugin, "gltestsrc",
GST_RANK_NONE, GST_TYPE_GL_TEST_SRC)) {
@ -174,11 +179,6 @@ plugin_init (GstPlugin * plugin)
GST_RANK_NONE, GST_TYPE_GL_MOSAIC)) {
return FALSE;
}
if (!gst_element_register (plugin, "glvideomixer",
GST_RANK_NONE, GST_TYPE_GL_VIDEO_MIXER)) {
return FALSE;
}
#if HAVE_PNG
if (!gst_element_register (plugin, "gldifferencematte",
GST_RANK_NONE, gst_gl_differencematte_get_type ())) {