[066/906] up

git-svn-id: svn://svn.wobow.com/GStreamer_playground/gst-plugins-gl@430 93df14bb-0f41-7a43-8087-d3e2a2f0e464
This commit is contained in:
Julien Isorce 2008-05-18 19:18:04 +00:00 committed by Matthew Waters
parent 4511a3c0bd
commit f509c88675
6 changed files with 31 additions and 23 deletions

View file

@ -13,7 +13,7 @@
//------------------------------------------------------------
//-------------------- Private déclarations ------------------
//-------------------- Private d<EFBFBD>clarations ------------------
//------------------------------------------------------------
static void gst_gl_display_finalize (GObject * object);
static gpointer gst_gl_display_glutThreadFunc (GstGLDisplay* display);
@ -379,7 +379,11 @@ gst_gl_display_glutCreateWindow (GstGLDisplay *display)
glutInitWindowSize(display->glcontext_width, display->glcontext_height);
//create opengl context
#if WIN32
sprintf_s(buffer, 5, "%d", glutWinId);
#else
sprintf(buffer, "%d", glutWinId);
#endif
display->title = g_string_append (display->title, buffer);
glutWinId = glutCreateWindow (display->title->str, display->winId);
@ -559,11 +563,18 @@ gst_gl_display_glutCreateWindow (GstGLDisplay *display)
g_print ("Context %d, ARB_fragment_program supported: yes\n", glutWinId);
//from video to texture
#if WIN32
sprintf_s (program, 2048, display->textFProgram_YUY2_UYVY, 'r', 'g', 'a');
#else
sprintf (program, display->textFProgram_YUY2_UYVY, 'r', 'g', 'a');
#endif
display->GLSLProgram_YUY2 = gst_gl_display_loadGLSLprogram (program);
#if WIN32
sprintf_s (program, 2048, display->textFProgram_YUY2_UYVY, 'a', 'b', 'r');
#else
sprintf (program, display->textFProgram_YUY2_UYVY, 'a', 'b', 'r');
#endif
display->GLSLProgram_UYVY = gst_gl_display_loadGLSLprogram (program);
display->GLSLProgram_I420_YV12 = gst_gl_display_loadGLSLprogram (display->textFProgram_I420_YV12);
@ -572,10 +583,10 @@ gst_gl_display_glutCreateWindow (GstGLDisplay *display)
//from texture to video
sprintf_s (program, 2048, display->textFProgram_to_YUY2_UYVY, "y2,u,y1,v");
sprintf (program, display->textFProgram_to_YUY2_UYVY, "y2,u,y1,v");
display->GLSLProgram_to_YUY2 = gst_gl_display_loadGLSLprogram (program);
sprintf_s (program, 2048, display->textFProgram_to_YUY2_UYVY, "v,y1,u,y2");
sprintf (program, display->textFProgram_to_YUY2_UYVY, "v,y1,u,y2");
display->GLSLProgram_to_UYVY = gst_gl_display_loadGLSLprogram (program);
display->GLSLProgram_to_I420_YV12 = gst_gl_display_loadGLSLprogram (display->textFProgram_to_I420_YV12);

View file

@ -6,8 +6,8 @@ AM_LIBS = $(GST_BASE_LIBS)
libgstopengl_la_SOURCES = \
gstopengl.c \
glimagesink.c \
glimagesink.h \
gstglimagesink.c \
gstglimagesink.h \
gstglgraphicmaker.c \
gstglgraphicmaker.h \
gstglvideomaker.c \
@ -21,6 +21,7 @@ libgstopengl_la_CFLAGS = $(GST_CFLAGS) $(X_CFLAGS) $(GST_BASE_CFLAGS) \
-I$(top_srcdir)/gst-libs/gst/freeglut \
-I$(top_srcdir)/gst-libs/gst/gl
libgstopengl_la_LIBADD = \
$(top_builddir)/gst-libs/gst/freeglut/libgstfreeglut-$(GST_MAJORMINOR).la \
$(top_builddir)/gst-libs/gst/gl/libgstgl-$(GST_MAJORMINOR).la \
$(GST_BASE_LIBS) \
$(GST_PLUGINS_BASE_LIBS) -lgstinterfaces-$(GST_MAJORMINOR)

View file

@ -196,7 +196,7 @@ gst_gl_graphicmaker_reset (GstGLGraphicmaker* graphicmaker)
static gboolean
gst_gl_graphicmaker_start (GstBaseTransform * bt)
{
GstGLGraphicmaker* graphicmaker = GST_GL_GRAPHICMAKER (bt);
//GstGLGraphicmaker* graphicmaker = GST_GL_GRAPHICMAKER (bt);
return TRUE;
}

View file

@ -22,7 +22,7 @@ gst_glimage_sink_change_state (GstElement * element, GstStateChange transition);
static void gst_glimage_sink_get_times (GstBaseSink * bsink, GstBuffer * buf,
GstClockTime * start, GstClockTime * end);
static GstCaps *gst_glimage_sink_get_caps (GstBaseSink * bsink);
//static GstCaps *gst_glimage_sink_get_caps (GstBaseSink * bsink);
static gboolean gst_glimage_sink_set_caps (GstBaseSink * bsink, GstCaps * caps);
static GstFlowReturn gst_glimage_sink_render (GstBaseSink * bsink,
GstBuffer * buf);

View file

@ -142,7 +142,7 @@ gst_gl_videomaker_reset (GstGLVideomaker* videomaker)
static gboolean
gst_gl_videomaker_start (GstBaseTransform* bt)
{
GstGLVideomaker* videomaker = GST_GL_VIDEOMAKER (bt);
//GstGLVideomaker* videomaker = GST_GL_VIDEOMAKER (bt);
return TRUE;
}

View file

@ -36,10 +36,6 @@ struct _GstGLVideomakerClass
GstBaseTransformClass base_transform_class;
};
typedef struct _GstGLVideomaker GstGLVideomaker;
typedef struct _GstGLVideomakerClass GstGLVideomakerClass;
GType gst_gl_videomaker_get_type (void);
G_END_DECLS