summaryrefslogtreecommitdiffstats
path: root/patches/gst-plugins-bad-1.0.6/0001-remove-endianness-swapping.patch
blob: d9a018dc10accf649233a7b647089d1c2cfb8fbd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
From: Luotao Fu <lfu@pengutronix.de>
Date: Thu, 11 Dec 2008 11:57:48 +0100
Subject: [PATCH] remove endianness swapping

 Swapping r- g- and bmask here is weird. It turns i.E. RGB888 to BGR888. For
 formats like RGB666 it turns the mask into a mess. Seems that gstreamer
 treat all True color as Big Endian. Still I doubt that it makes sense to
 swap the masks. I'm however not quite sure about this, comments are highly
 welcome.

Signed-off-by: Luotao Fu <l.fu@pengutronix.de>
---
 sys/fbdev/gstfbdevsink.c | 14 +-------------
 1 file changed, 1 insertion(+), 13 deletions(-)

diff --git a/sys/fbdev/gstfbdevsink.c b/sys/fbdev/gstfbdevsink.c
index 639641d..6d06801 100644
--- a/sys/fbdev/gstfbdevsink.c
+++ b/sys/fbdev/gstfbdevsink.c
@@ -153,21 +153,9 @@ gst_fbdevsink_getcaps (GstBaseSink * bsink)
 
   switch (fbdevsink->varinfo.bits_per_pixel) {
     case 32:
-      /* swap endian of masks */
-      rmask = swapendian (rmask);
-      gmask = swapendian (gmask);
-      bmask = swapendian (bmask);
+    case 24:
       endianness = 4321;
       break;
-    case 24:{
-      /* swap red and blue masks */
-      uint32_t t = rmask;
-
-      rmask = bmask;
-      bmask = t;
-      endianness = 4321;
-      break;
-    }
     case 15:
     case 16:
       endianness = 1234;