summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2014-06-22 10:15:41 +0900
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2014-06-22 10:15:41 +0900
commit3236aeb8e7515ca7e50d0936dec910f4f7ea1630 (patch)
tree89c1cf0d7aac2b43da181d13f143e78675eb875a
parent40cba1e8947776050fb253e266bea6642a1f2076 (diff)
downloadevas_generic_loaders-3236aeb8e7515ca7e50d0936dec910f4f7ea1630.tar.gz
gst1 support fixed now to do argb properly
-rw-r--r--src/bin/gst/main.c14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/bin/gst/main.c b/src/bin/gst/main.c
index 526e1a6..3dffbb2 100644
--- a/src/bin/gst/main.c
+++ b/src/bin/gst/main.c
@@ -23,7 +23,11 @@
#define D(fmt, args...)
#endif
-#define CAPS "video/x-raw,format=RGB"
+#ifdef WORDS_BIGENDIAN
+# define CAPS "video/x-raw,format=ARGB"
+#else
+# define CAPS "video/x-raw,format=BGRA"
+#endif
static GstElement *pipeline = NULL;
static GstElement *sink = NULL;
@@ -107,7 +111,7 @@ _gst_init(const char *filename)
ret = gst_element_get_state((pipeline), NULL, NULL, GST_CLOCK_TIME_NONE);
if (ret == GST_STATE_CHANGE_FAILURE)
{
- D("could not complete pause\n");
+ D("could not complete pause\n");
goto unref_pipeline;
}
@@ -115,14 +119,14 @@ _gst_init(const char *filename)
gst_element_query_duration (pipeline, format, &duration);
if (duration == -1)
{
- D("could not retrieve the duration, set it to 1s\n");
+ D("could not retrieve the duration, set it to 1s\n");
duration = 1 * GST_SECOND;
}
pad = gst_element_get_static_pad(sink, "sink");
if (!pad)
{
- D("could not retrieve the sink pad\n");
+ D("could not retrieve the sink pad\n");
goto unref_pipeline;
}
@@ -243,7 +247,7 @@ main(int argc, char **argv)
}
timeout_init(10);
-
+
D("_gst_init_file\n");
if (!_gst_init(file))