From 0e310c57a4af9e3b3bc87816a60b01790e2c6b89 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sun, 20 Aug 2006 18:00:00 +0200 Subject: =?UTF-8?q?Version=201.4.1-5=20-=20Replaced=20the=20"quick=20worka?= =?UTF-8?q?round=20for=20additional=20live=20audio=20PIDs"=20in=20=20=20cD?= =?UTF-8?q?vbDevice::SetChannelDevice()=20with=20an=20actual=20solution=20?= =?UTF-8?q?in=20=20=20cDvbDevice::SetAudioTrackDevice()=20in=20order=20to?= =?UTF-8?q?=20prevent=20sticky=20PIDs=20in=20CAMs,=20=20=20which=20caused?= =?UTF-8?q?=20long=20switching=20times=20or=20completely=20blank=20screens?= =?UTF-8?q?=20when=20switching=20=20=20between=20encrypted=20channels=20on?= =?UTF-8?q?=20the=20same=20transponder=20(reported=20by=20Tomas=20Berglund?= =?UTF-8?q?).=20-=20Adapted=20cThread::ThreadId()=20to=20recent=20kernels?= =?UTF-8?q?=20(thanks=20to=20Ville=20Skytt=C3=A4).=20-=20Added=20--remove-?= =?UTF-8?q?destination=20to=20the=20'cp'=20command=20for=20binaries=20in?= =?UTF-8?q?=20the=20Makefile=20to=20=20=20avoid=20a=20crash=20in=20case=20?= =?UTF-8?q?a=20new=20version=20is=20installed=20on=20a=20running=20system?= =?UTF-8?q?=20(suggested=20=20=20by=20Petri=20Hintukainen).=20-=20Fixed=20?= =?UTF-8?q?handling=20"Ca=20Info"=20in=20case=20the=20CAM=20sends=20this?= =?UTF-8?q?=20again=20if=20the=20smart=20card=20is=20=20=20replaced=20with?= =?UTF-8?q?=20a=20different=20one.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- dvbdevice.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'dvbdevice.c') diff --git a/dvbdevice.c b/dvbdevice.c index 9ae8dfa..fb8ec93 100644 --- a/dvbdevice.c +++ b/dvbdevice.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: dvbdevice.c 1.159 2006/06/11 09:03:55 kls Exp $ + * $Id: dvbdevice.c 1.160 2006/08/14 09:38:32 kls Exp $ */ #include "dvbdevice.h" @@ -853,11 +853,6 @@ bool cDvbDevice::SetChannelDevice(const cChannel *Channel, bool LiveView) esyslog("ERROR: failed to set PIDs for channel %d on device %d", Channel->Number(), CardIndex() + 1); return false; } - //XXX quick workaround for additional live audio PIDs: - if (ciHandler) { - ciHandler->SetPid(Channel->Apid(1), true); - ciHandler->SetPid(Channel->Dpid(0), true); - } if (IsPrimaryDevice()) AddPid(Channel->Tpid(), ptTeletext); CHECK(ioctl(fd_audio, AUDIO_SET_MUTE, true)); // actually one would expect 'false' here, but according to Marco Schlüßler this works @@ -927,8 +922,14 @@ void cDvbDevice::SetAudioTrackDevice(eTrackType Type) if (IS_AUDIO_TRACK(Type) || (IS_DOLBY_TRACK(Type) && SetAudioBypass(true))) { if (pidHandles[ptAudio].pid && pidHandles[ptAudio].pid != TrackId->id) { DetachAll(pidHandles[ptAudio].pid); + if (ciHandler) + ciHandler->SetPid(pidHandles[ptAudio].pid, false); pidHandles[ptAudio].pid = TrackId->id; SetPid(&pidHandles[ptAudio], ptAudio, true); + if (ciHandler) { + ciHandler->SetPid(pidHandles[ptAudio].pid, true); + ciHandler->StartDecrypting(); + } } } else if (IS_DOLBY_TRACK(Type)) { -- cgit v1.2.3