diff options
author | Xavier Claessens <xavier.claessens@collabora.com> | 2015-05-26 15:04:34 -0400 |
---|---|---|
committer | Nicolas Dufresne <nicolas.dufresne@collabora.com> | 2015-05-26 16:49:55 -0400 |
commit | 02b2c2edf633ab4723cc1b5a56b3b9fa536f1ae4 (patch) | |
tree | c5189e9578d11e2b00c919f46f2d1e7eb6502d79 /ext/gl/gstgloverlay.c | |
parent | 7bfd2703c6e34e29cd616d4970ad2c52e2032a72 (diff) |
gloverlay: remove unused type_file field
https://bugzilla.gnome.org/show_bug.cgi?id=749846
Diffstat (limited to 'ext/gl/gstgloverlay.c')
-rw-r--r-- | ext/gl/gstgloverlay.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/ext/gl/gstgloverlay.c b/ext/gl/gstgloverlay.c index 720962165..68db50aaf 100644 --- a/ext/gl/gstgloverlay.c +++ b/ext/gl/gstgloverlay.c @@ -73,8 +73,8 @@ static void gst_gl_overlay_before_transform (GstBaseTransform * trans, static gboolean gst_gl_overlay_filter_texture (GstGLFilter * filter, guint in_tex, guint out_tex); -static gint gst_gl_overlay_load_png (GstGLFilter * filter); -static gint gst_gl_overlay_load_jpeg (GstGLFilter * filter); +static gboolean gst_gl_overlay_load_png (GstGLFilter * filter); +static gboolean gst_gl_overlay_load_jpeg (GstGLFilter * filter); enum { @@ -581,8 +581,8 @@ gst_gl_overlay_filter_texture (GstGLFilter * filter, guint in_tex, overlay->image_memory = NULL; } if (overlay->location != NULL) { - if ((overlay->type_file = gst_gl_overlay_load_png (filter)) == 0) { - if ((overlay->type_file = gst_gl_overlay_load_jpeg (filter)) == 0) { + if (!gst_gl_overlay_load_png (filter)) { + if (!gst_gl_overlay_load_jpeg (filter)) { return FALSE; } } @@ -617,7 +617,7 @@ user_warning_fn (png_structp png_ptr, png_const_charp warning_msg) #define LOAD_ERROR(msg) { GST_WARNING ("unable to load %s: %s", overlay->location, msg); return FALSE; } -static gint +static gboolean gst_gl_overlay_load_jpeg (GstGLFilter * filter) { GstGLOverlay *overlay = GST_GL_OVERLAY (filter); @@ -633,7 +633,7 @@ gst_gl_overlay_load_jpeg (GstGLFilter * filter) fp = fopen (overlay->location, "rb"); if (!fp) { g_error ("error: couldn't open file!\n"); - return 0; + return FALSE; } jpeg_create_decompress (&cinfo); cinfo.err = jpeg_std_error (&jerr); @@ -671,10 +671,10 @@ gst_gl_overlay_load_jpeg (GstGLFilter * filter) jpeg_destroy_decompress (&cinfo); gst_memory_unmap ((GstMemory *) overlay->image_memory, &map_info); fclose (fp); - return 2; + return TRUE; } -static gint +static gboolean gst_gl_overlay_load_png (GstGLFilter * filter) { GstGLOverlay *overlay = GST_GL_OVERLAY (filter); @@ -696,7 +696,7 @@ gst_gl_overlay_load_png (GstGLFilter * filter) gint n_read; if (!GST_GL_BASE_FILTER (filter)->context) - return 1; + return FALSE; if ((fp = fopen (overlay->location, "rb")) == NULL) LOAD_ERROR ("file not found"); @@ -777,5 +777,5 @@ gst_gl_overlay_load_png (GstGLFilter * filter) png_destroy_read_struct (&png_ptr, &info_ptr, png_infopp_NULL); fclose (fp); - return 1; + return TRUE; } |