gl: move gl(base)mixer to library

For use by applications/libraries outside of the opengl plugin.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/4608>
This commit is contained in:
Matthew Waters 2023-05-08 13:40:01 +10:00 committed by GStreamer Marge Bot
parent 7613e50cbb
commit 007a602726
10 changed files with 21 additions and 10 deletions

View file

@ -42,6 +42,8 @@
#include "config.h"
#endif
#include <gst/gl/gstglfuncs.h>
#include "gstglelements.h"
#include "gstglmosaic.h"
#include "gstglutils.h"

View file

@ -21,7 +21,7 @@
#ifndef _GST_GL_MOSAIC_H_
#define _GST_GL_MOSAIC_H_
#include "gstglmixer.h"
#include <gst/gl/gstglmixer.h>
G_BEGIN_DECLS

View file

@ -22,7 +22,7 @@
#ifndef __GST_GL_STEREO_MIX_H__
#define __GST_GL_STEREO_MIX_H__
#include "gstglmixer.h"
#include <gst/gl/gstglmixer.h>
G_BEGIN_DECLS
@ -64,7 +64,7 @@ struct _GstGLStereoMix
{
GstGLMixer mixer;
GLuint out_tex_id;
guint out_tex_id;
GstGLViewConvert *viewconvert;
GstGLStereoDownmix downmix_mode;

View file

@ -21,7 +21,7 @@
#ifndef _GST_GL_VIDEO_MIXER_H_
#define _GST_GL_VIDEO_MIXER_H_
#include "gstglmixer.h"
#include <gst/gl/gstglmixer.h>
G_BEGIN_DECLS
@ -140,9 +140,9 @@ struct _GstGLVideoMixer
GstGLShader *shader;
GstGLShader *checker;
GLuint vao;
GLuint vbo_indices;
GLuint checker_vbo;
guint vao;
guint vbo_indices;
guint checker_vbo;
GstGLMemory *out_tex;
gboolean output_geo_change;

View file

@ -30,14 +30,12 @@ opengl_sources = [
'effects/gstgleffectblur.c',
'effects/gstgleffectsobel.c',
'effects/gstgleffectlaplacian.c',
'gstglbasemixer.c',
'gstglcolorscale.c',
'gstglcolorbalance.c',
'gstgldeinterlace.c',
'gstglfiltershader.c',
'gstglfilterapp.c',
'gstglmixerbin.c',
'gstglmixer.c',
'gstglvideomixer.c',
'gstglstereomix.c',
'gstglstereosplit.c',

View file

@ -54,6 +54,7 @@ struct _GstGLBaseMixerPadClass
GstVideoAggregatorPadClass parent_class;
};
GST_GL_API
GType gst_gl_base_mixer_pad_get_type (void);
#define GST_TYPE_GL_BASE_MIXER (gst_gl_base_mixer_get_type())
@ -95,8 +96,10 @@ struct _GstGLBaseMixerClass
gpointer _padding[GST_PADDING];
};
GST_GL_API
GType gst_gl_base_mixer_get_type(void);
GST_GL_API
GstGLContext * gst_gl_base_mixer_get_gl_context (GstGLBaseMixer * mix);
G_END_DECLS

View file

@ -30,6 +30,8 @@
#include "gstglmixer.h"
#include <gst/gl/gstglfuncs.h>
#define GST_CAT_DEFAULT gst_gl_mixer_debug
GST_DEBUG_CATEGORY (gst_gl_mixer_debug);

View file

@ -24,7 +24,6 @@
#include <gst/gst.h>
#include <gst/video/video.h>
#include <gst/gl/gl.h>
#include <gst/gl/gstglfuncs.h>
#include "gstglbasemixer.h"
G_BEGIN_DECLS
@ -61,6 +60,7 @@ struct _GstGLMixerPadClass
GstGLBaseMixerPadClass parent_class;
};
GST_GL_API
GType gst_gl_mixer_pad_get_type (void);
#define GST_TYPE_GL_MIXER (gst_gl_mixer_get_type())
@ -102,8 +102,10 @@ struct _GstGLMixerClass
GstGLMixerProcessTextures process_textures;
};
GST_GL_API
GType gst_gl_mixer_get_type(void);
GST_GL_API
gboolean gst_gl_mixer_process_textures (GstGLMixer * mix, GstBuffer * outbuf);
G_END_DECLS

View file

@ -14,6 +14,7 @@ gl_sources = files([
'gstglapi.c',
'gstglbasefilter.c',
'gstglbasememory.c',
'gstglbasemixer.c',
'gstglbasesrc.c',
'gstglcolorconvert.c',
'gstglbuffer.c',
@ -29,6 +30,7 @@ gl_sources = files([
'gstglframebuffer.c',
'gstglmemory.c',
'gstglmemorypbo.c',
'gstglmixer.c',
'gstgloverlaycompositor.c',
'gstglquery.c',
'gstglrenderbuffer.c',
@ -53,6 +55,7 @@ gir_gl_headers = files([
'gstglapi.h',
'gstglbasefilter.h',
'gstglbasememory.h',
'gstglbasemixer.h',
'gstglbasesrc.h',
'gstglbuffer.h',
'gstglbufferpool.h',
@ -67,6 +70,7 @@ gir_gl_headers = files([
'gstglframebuffer.h',
'gstglmemory.h',
'gstglmemorypbo.h',
'gstglmixer.h',
'gstgloverlaycompositor.h',
'gstglquery.h',
'gstglrenderbuffer.h',