summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CONTRIBUTORS3
-rw-r--r--HISTORY1
-rw-r--r--dvbspu.h7
3 files changed, 6 insertions, 5 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 578e0f5b..5e2ff170 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -1003,3 +1003,6 @@ Miko Wohlgemuth <weak@chello.at>
Michal Dobrzynski <michal_dobrzynski@mac.com>
for reporting a freezing picture when a recording starts on a system that always
uses 'Transfer Mode'
+
+Marco Schlüßler <marco@lordzodiac.de>
+ for fixing handling colors in cDvbSpuPalette::yuv2rgb()
diff --git a/HISTORY b/HISTORY
index 455a958a..bdbaac84 100644
--- a/HISTORY
+++ b/HISTORY
@@ -2862,3 +2862,4 @@ Video Disk Recorder Revision History
- Fixed the height of the channel display in the "Classic VDR" skin.
- Fixed handling descriptor loops in 'libsi', which had sometimes caused invalid
CA ids to be added to the channel definitions (thanks to Marcel Wiesweg).
+- Fixed handling colors in cDvbSpuPalette::yuv2rgb() (thanks to Marco Schlüßler).
diff --git a/dvbspu.h b/dvbspu.h
index 4c926df3..df717c1b 100644
--- a/dvbspu.h
+++ b/dvbspu.h
@@ -8,7 +8,7 @@
*
* parts of this file are derived from the OMS program.
*
- * $Id: dvbspu.h 1.3 2004/04/30 13:44:41 kls Exp $
+ * $Id: dvbspu.h 1.4 2004/05/31 08:49:20 kls Exp $
*/
#ifndef __DVBSPU_H
@@ -157,7 +157,6 @@ inline uint32_t cDvbSpuPalette::yuv2rgb(uint32_t yuv_color)
int Y, Cb, Cr;
int Ey, Epb, Epr;
int Eg, Eb, Er;
- uint32_t result;
Y = (yuv_color >> 16) & 0xff;
Cb = (yuv_color) & 0xff;
@@ -191,9 +190,7 @@ inline uint32_t cDvbSpuPalette::yuv2rgb(uint32_t yuv_color)
if (Er < 0)
Er = 0;
- result = (Eb << 16) | (Eg << 8) | Er;
-
- return result;
+ return Eb | (Eg << 8) | (Er << 16);
}
inline uint32_t cDvbSpuPalette::getColor(uint8_t idx, uint8_t trans) const