1
0
mirror of https://github.com/VDR4Arch/vdr.git synced 2023-10-10 13:36:52 +02:00

Keeping subtitles visible when pausing replay

This commit is contained in:
Klaus Schmidinger 2010-02-07 12:08:13 +01:00
parent 184db9ec8a
commit 978807e4d1
5 changed files with 52 additions and 40 deletions

View File

@ -1091,6 +1091,7 @@ Rolf Ahrenberg <rahrenbe@cc.hut.fi>
for a patch that was used to implement handling the "component descriptor" ("genre")
for a patch that was used to implement handling the "parental rating descriptor"
suggesting to add plain text error messages to log entries from cOsd::SetAreas()
for keeping subtitles visible when pausing replay
Ralf Klueber <ralf.klueber@vodafone.com>
for reporting a bug in cutting a recording if there is only a single editing mark

View File

@ -6309,7 +6309,7 @@ Video Disk Recorder Revision History
- The files "commands.conf" and "reccmd.conf" can now contain nested lists of
commands. See vdr.5 for information about the new file format.
2010-02-06: Version 1.7.13
2010-02-07: Version 1.7.13
- Updated the Italian OSD texts (thanks to Diego Pierotto).
- Changed the position of Sirius 4 to S4.8E in sources.conf (thanks to Alexander Gross).
@ -6352,3 +6352,4 @@ Video Disk Recorder Revision History
------------------------------------------------------------
- Added device definitions to the diseqc.conf file format, so that certain satellite
positions can be limited to a given list of devices.
- Keeping subtitles visible when pausing replay (thanks to Rolf Ahrenberg).

View File

@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: device.c 2.34 2010/02/06 14:34:18 kls Exp $
* $Id: device.c 2.35 2010/02/07 11:54:42 kls Exp $
*/
#include "device.h"
@ -1053,11 +1053,15 @@ void cDevice::Clear(void)
void cDevice::Play(void)
{
Audios.MuteAudio(mute);
if (dvbSubtitleConverter)
dvbSubtitleConverter->Freeze(false);
}
void cDevice::Freeze(void)
{
Audios.MuteAudio(true);
if (dvbSubtitleConverter)
dvbSubtitleConverter->Freeze(true);
}
void cDevice::Mute(void)

View File

@ -7,7 +7,7 @@
* Original author: Marco Schlüßler <marco@lordzodiac.de>
* With some input from the "subtitle plugin" by Pekka Virtanen <pekka.virtanen@sci.fi>
*
* $Id: dvbsubtitle.c 2.3 2009/12/05 16:11:54 kls Exp $
* $Id: dvbsubtitle.c 2.4 2010/02/07 12:08:13 kls Exp $
*/
#include "dvbsubtitle.h"
@ -658,6 +658,7 @@ cDvbSubtitleConverter::cDvbSubtitleConverter(void)
{
dvbSubtitleAssembler = new cDvbSubtitleAssembler;
osd = NULL;
frozen = false;
pages = new cList<cDvbSubtitlePage>;
bitmaps = new cList<cDvbSubtitleBitmaps>;
Start();
@ -685,6 +686,7 @@ void cDvbSubtitleConverter::Reset(void)
pages->Clear();
bitmaps->Clear();
DELETENULL(osd);
frozen = false;
Unlock();
}
@ -776,6 +778,8 @@ void cDvbSubtitleConverter::Action(void)
int LastSetupLevel = setupLevel;
cTimeMs Timeout;
while (Running()) {
int WaitMs = 100;
if (!frozen) {
if (osd) {
int NewSetupLevel = setupLevel;
if (Timeout.TimedOut() || LastSetupLevel != NewSetupLevel) {
@ -783,7 +787,6 @@ void cDvbSubtitleConverter::Action(void)
}
LastSetupLevel = NewSetupLevel;
}
int WaitMs = 100;
Lock();
if (cDvbSubtitleBitmaps *sb = bitmaps->First()) {
int64_t STC = cDevice::PrimaryDevice()->GetSTC();
@ -816,6 +819,7 @@ void cDvbSubtitleConverter::Action(void)
bitmaps->Del(sb);
}
Unlock();
}
cCondWait::SleepMs(WaitMs);
}
}

View File

@ -6,7 +6,7 @@
*
* Original author: Marco Schlüßler <marco@lordzodiac.de>
*
* $Id: dvbsubtitle.h 2.1 2008/05/25 14:36:52 kls Exp $
* $Id: dvbsubtitle.h 2.2 2010/02/07 11:55:14 kls Exp $
*/
#ifndef __DVBSUBTITLE_H
@ -25,6 +25,7 @@ private:
static int setupLevel;
cDvbSubtitleAssembler *dvbSubtitleAssembler;
cOsd *osd;
bool frozen;
cList<cDvbSubtitlePage> *pages;
cList<cDvbSubtitleBitmaps> *bitmaps;
tColor yuv2rgb(int Y, int Cb, int Cr);
@ -36,6 +37,7 @@ public:
virtual ~cDvbSubtitleConverter();
void Action(void);
void Reset(void);
void Freeze(bool Status) { frozen = Status; }
int ConvertFragments(const uchar *Data, int Length); // for legacy PES recordings
int Convert(const uchar *Data, int Length);
static void SetupChanged(void);