diff options
author | Reynaldo H. Verdejo Pinochet <reynaldo@collabora.com> | 2012-05-24 10:19:38 -0400 |
---|---|---|
committer | Reynaldo H. Verdejo Pinochet <reynaldo@collabora.com> | 2012-08-15 01:13:35 -0400 |
commit | 9bd3e78c346a368b00a6128f9aec192ce8d076e8 (patch) | |
tree | 4bd95a919991302563e71487d1a99c58741cce03 | |
parent | 08071dc7c947805d920af3ff9d80cde592ff5fe1 (diff) |
Minor cleanups
-rw-r--r-- | sys/android/gstvidroidsink.c | 54 | ||||
-rw-r--r-- | sys/android/gstvidroidsink.h | 2 |
2 files changed, 29 insertions, 27 deletions
diff --git a/sys/android/gstvidroidsink.c b/sys/android/gstvidroidsink.c index 25c7fd965..0d342e40c 100644 --- a/sys/android/gstvidroidsink.c +++ b/sys/android/gstvidroidsink.c @@ -45,24 +45,29 @@ /** * SECTION:element-vidroidsink * - * GStreamer vout sink using GLES/EGL - * + * This is a vout sink for Android using GLESv2/EGL. It also + * works on a X11/Mesa environment provided it's base set of + * requirements are met. + * * <refsect2> - * <title>Example launch line</title> - * |[ - * gst-launch -v -m fakesrc ! vidroidsink ! fakesink silent=TRUE - * ]| - * </refsect2> - */ - -/* Rationale on OpenGL ES version - * + * <title>Rationale on OpenGL ES version</title> + * <para> * Android supports OpenGL ES 1.0 / 1.1 and since 2.2 * (API level 8) it supports OpenGL ES 2.0. Most widely * supported version is OpenGL ES 1.1 according to * http://developer.android.com/resources/dashboard/opengl.html - * + * </para> + * <para> * This Sink uses GLESv2 + * </para> + * </refsect2> + * + * <refsect2> + * <title>Example launch line</title> + * |[ + * gst-launch -v -m videotestsrc ! vidroidsink silent=TRUE + * ]| + * </refsect2> */ #ifdef HAVE_CONFIG_H @@ -86,8 +91,9 @@ GST_DEBUG_CATEGORY_STATIC (gst_vidroidsink_debug); #define GST_CAT_DEFAULT gst_vidroidsink_debug -/* These should be defined per model. - * Galaxy Nexus: +/* XXX: These should be defined per model someway + * but the Galaxy Nexus's were taken as a reference + * for now on: */ #define VIDROIDSINK_MAX_FRAME_WIDTH 1280 #define VIDROIDSINK_MAX_FRAME_HEIGHT 720 @@ -280,7 +286,7 @@ gst_vidroidbuffer_destroy (GstViDroidBuffer * vidroidbuffer) vidroidsink = vidroidbuffer->vidroidsink; if (G_UNLIKELY (vidroidsink == NULL)) - goto no_sink; + goto NO_SINK; g_return_if_fail (GST_IS_VIDROIDSINK (vidroidsink)); @@ -306,11 +312,9 @@ gst_vidroidbuffer_destroy (GstViDroidBuffer * vidroidbuffer) return; -no_sink: - { - GST_WARNING ("no sink found"); - return; - } +NO_SINK: + GST_WARNING ("no sink found"); + return; } /* XXX: Missing implementation. @@ -327,7 +331,7 @@ gst_vidroidbuffer_finalize (GstViDroidBuffer * vidroidbuffer) vidroidsink = vidroidbuffer->vidroidsink; if (G_UNLIKELY (vidroidsink == NULL)) - goto no_sink; + goto NO_SINK; g_return_if_fail (GST_IS_VIDROIDSINK (vidroidsink)); @@ -335,11 +339,9 @@ gst_vidroidbuffer_finalize (GstViDroidBuffer * vidroidbuffer) return; -no_sink: - { - GST_WARNING ("no sink found"); - return; - } +NO_SINK: + GST_WARNING ("no sink found"); + return; } static void diff --git a/sys/android/gstvidroidsink.h b/sys/android/gstvidroidsink.h index c02aac3e1..250f0a192 100644 --- a/sys/android/gstvidroidsink.h +++ b/sys/android/gstvidroidsink.h @@ -87,6 +87,7 @@ struct _GstViDroidImageFmt GstCaps *caps; }; +/* XXX: Maybe use GstVideoRectangle for the image data? */ struct _GstViDroidBuffer { GstBuffer buffer; @@ -102,7 +103,6 @@ struct _GstViDroidBuffer struct _GstViDroidSink { GstVideoSink videosink; - GstVideoRectangle render_area; GstVideoFormat format; GstCaps *current_caps; GstPad *sink; |