Search
SailfishOS Open Build Service
>
Projects
>
home:sledge
:
branches:nemo:devel:hw:ti:omap4:common
>
gst-plugins-base
> 0020-video-fix-endianess-issue-for-16bit-RGB-formats.patch
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File 0020-video-fix-endianess-issue-for-16bit-RGB-formats.patch of Package gst-plugins-base
From 134bbd3bd49b2bcc6e5a8281862474fcd003eb54 Mon Sep 17 00:00:00 2001 From: Rob Clark <rob@ti.com> Date: Mon, 13 Sep 2010 19:05:56 -0500 Subject: [PATCH 20/38] video: fix endianess issue for 16bit RGB formats --- gst-libs/gst/video/video.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/gst-libs/gst/video/video.c b/gst-libs/gst/video/video.c index 262677f..b73011a 100644 --- a/gst-libs/gst/video/video.c +++ b/gst-libs/gst/video/video.c @@ -636,6 +636,7 @@ gst_video_format_new_caps_simple (GstVideoFormat format, int rowstride, int depth = 0; int bpp = 0; gboolean have_alpha; + int endianness = G_BIG_ENDIAN; unsigned int mask = 0; switch (format) { @@ -734,6 +735,7 @@ gst_video_format_new_caps_simple (GstVideoFormat format, int rowstride, default: return NULL; } + endianness = G_BYTE_ORDER; } else if (bpp != 8) { return NULL; } @@ -745,7 +747,7 @@ gst_video_format_new_caps_simple (GstVideoFormat format, int rowstride, if (bpp != 8) { gst_structure_set (s, - "endianness", G_TYPE_INT, G_BIG_ENDIAN, + "endianness", G_TYPE_INT, endianness, "red_mask", G_TYPE_INT, red_mask, "green_mask", G_TYPE_INT, green_mask, "blue_mask", G_TYPE_INT, blue_mask, NULL); -- 1.7.5.4