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

Revisited 'Fixed calling cStatus::MsgChannelSwitch() in cDevice::SetChannel()' to allow keeping language codes in Trandfer Mode

This commit is contained in:
Klaus Schmidinger 2005-02-27 13:40:33 +01:00
parent 59c0cc2edd
commit 940d605f2e
3 changed files with 20 additions and 18 deletions

View File

@ -1151,6 +1151,9 @@ Marco Schl
for reporting a missing 'resultSkipped = 0' in cRemux::Clear()
for reporting a missing reset of the 'repacker' in cTS2PES::Clear()
for avoiding unnecessary calls to SetPid() in cDvbDevice::SetAudioTrackDevice()
for pointing out that EnsureAudioTrack() in cDevice::SetChannel() should not be
called if a Transfer Mode is started, to avoid setting the audio PID on the primary
device
for fixing calling cStatus::MsgChannelSwitch() in cDevice::SetChannel()
for increasing POLLTIMEOUTS_BEFORE_DEVICECLEAR in transfer.c to 6 to avoid problems
with the larger buffer reserve

View File

@ -3422,8 +3422,9 @@ Video Disk Recorder Revision History
cEvent::FixEpgBugs() (thanks to Wolfgang Rohdewald).
- Avoiding unnecessary calls to SetPid() in cDvbDevice::SetAudioTrackDevice()
(thanks to Marco Schlüßler).
- Fixed calling cStatus::MsgChannelSwitch() in cDevice::SetChannel() (thanks to
Marco Schlüßler).
- No longer calling EnsureAudioTrack() in cDevice::SetChannel() if a Transfer Mode is
started, to avoid setting the audio PID on the primary device (thanks to Marco
Schlüßler for pointing this out).
- Replaced the call to system("sync") in SpinUpDisk() with fdatasync(f) to avoid
problems on NPTL systems (thanks to Chris Warren for pointing this out).
- Increased POLLTIMEOUTS_BEFORE_DEVICECLEAR in transfer.c to 6 to avoid problems

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 1.97 2005/02/26 16:19:57 kls Exp $
* $Id: device.c 1.98 2005/02/27 13:35:34 kls Exp $
*/
#include "device.h"
@ -594,24 +594,22 @@ eSetChannelResult cDevice::SetChannel(const cChannel *Channel, bool LiveView)
else
Result = scrFailed;
Channels.Unlock();
if (Result == scrOk) {
if (LiveView && IsPrimaryDevice()) {
// Set the available audio tracks:
ClrAvailableTracks();
for (int i = 0; i < MAXAPIDS; i++)
SetAvailableTrack(ttAudio, i, Channel->Apid(i), Channel->Alang(i));
if (Setup.UseDolbyDigital) {
for (int i = 0; i < MAXDPIDS; i++)
SetAvailableTrack(ttDolby, i, Channel->Dpid(i), Channel->Dlang(i));
}
currentChannel = Channel->Number();
EnsureAudioTrack(true);
}
}
}
if (Result == scrOk) {
if (LiveView && IsPrimaryDevice())
if (LiveView && IsPrimaryDevice()) {
currentChannel = Channel->Number();
// Set the available audio tracks:
ClrAvailableTracks();
for (int i = 0; i < MAXAPIDS; i++)
SetAvailableTrack(ttAudio, i, Channel->Apid(i), Channel->Alang(i));
if (Setup.UseDolbyDigital) {
for (int i = 0; i < MAXDPIDS; i++)
SetAvailableTrack(ttDolby, i, Channel->Dpid(i), Channel->Dlang(i));
}
if (!NeedsTransferMode)
EnsureAudioTrack(true);
}
cStatus::MsgChannelSwitch(this, Channel->Number()); // only report status if channel switch successfull
}