summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2012-03-16 12:01:31 +0100
committerKlaus Schmidinger <vdr@tvdr.de>2012-03-16 12:01:31 +0100
commit6504e55b76fe8118c6309131a423c143c818c372 (patch)
treee9d1347c9002cf6d9f548282b184299e6df3399f
parentc8b0ee3289849ab0d5778c58d65771f5c0270314 (diff)
downloadvdr-6504e55b76fe8118c6309131a423c143c818c372.tar.gz
vdr-6504e55b76fe8118c6309131a423c143c818c372.tar.bz2
Fixed reduced bpp support for DVB subtitles
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY1
-rw-r--r--dvbsubtitle.c24
3 files changed, 13 insertions, 13 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index 7b3b6941..1a0ca47e 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -1139,6 +1139,7 @@ Rolf Ahrenberg <rahrenbe@cc.hut.fi>
texts of its own
for suggesting to change the Green button in the "Edit timer" menu from "Once"
to "Single"
+ for fixing reduced bpp support for DVB subtitles
Ralf Klueber <ralf.klueber@vodafone.com>
for reporting a bug in cutting a recording if there is only a single editing mark
diff --git a/HISTORY b/HISTORY
index 092d6efa..304eed40 100644
--- a/HISTORY
+++ b/HISTORY
@@ -7046,3 +7046,4 @@ Video Disk Recorder Revision History
- Moved setting LC_NUMERIC further up to make sure any floating point numbers use a
decimal point (suggested by Tobias Grimm).
- Added missing channel locking to cEIT.
+- Fixed reduced bpp support for DVB subtitles (thanks to Rolf Ahrenberg).
diff --git a/dvbsubtitle.c b/dvbsubtitle.c
index ca3a6929..ab755c4b 100644
--- a/dvbsubtitle.c
+++ b/dvbsubtitle.c
@@ -7,7 +7,7 @@
* Original author: Marco Schluessler <marco@lordzodiac.de>
* With some input from the "subtitle plugin" by Pekka Virtanen <pekka.virtanen@sci.fi>
*
- * $Id: dvbsubtitle.c 2.30 2012/03/13 15:37:03 kls Exp $
+ * $Id: dvbsubtitle.c 2.31 2012/03/16 11:56:56 kls Exp $
*/
@@ -1281,9 +1281,16 @@ void cDvbSubtitleConverter::FinishPage(cDvbSubtitlePage *Page)
else
return; // unable to draw bitmaps
}
- if (Reduced) {
- for (int i = 0; i < NumAreas; i++) {
- cSubtitleRegion *sr = Page->regions.Get(i);
+ cDvbSubtitleBitmaps *Bitmaps = new cDvbSubtitleBitmaps(Page->Pts(), Page->Timeout(), Areas, NumAreas, osdFactorX, osdFactorY);
+ bitmaps->Add(Bitmaps);
+ for (int i = 0; i < NumAreas; i++) {
+ cSubtitleRegion *sr = Page->regions.Get(i);
+ cSubtitleClut *clut = Page->GetClutById(sr->ClutId());
+ if (!clut)
+ continue;
+ sr->Replace(*clut->GetPalette(sr->Bpp()));
+ sr->UpdateTextData(clut);
+ if (Reduced) {
if (sr->Bpp() != Areas[i].bpp) {
if (sr->Level() <= Areas[i].bpp) {
//TODO this is untested - didn't have any such subtitle stream
@@ -1299,15 +1306,6 @@ void cDvbSubtitleConverter::FinishPage(cDvbSubtitlePage *Page)
}
}
}
- }
- cDvbSubtitleBitmaps *Bitmaps = new cDvbSubtitleBitmaps(Page->Pts(), Page->Timeout(), Areas, NumAreas, osdFactorX, osdFactorY);
- bitmaps->Add(Bitmaps);
- for (cSubtitleRegion *sr = Page->regions.First(); sr; sr = Page->regions.Next(sr)) {
- cSubtitleClut *clut = Page->GetClutById(sr->ClutId());
- if (!clut)
- continue;
- sr->Replace(*clut->GetPalette(sr->Bpp()));
- sr->UpdateTextData(clut);
int posX = sr->HorizontalAddress();
int posY = sr->VerticalAddress();
if (sr->Width() > 0 && sr->Height() > 0) {