summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--HISTORY1
-rw-r--r--device.c5
-rw-r--r--dvbdevice.c6
3 files changed, 8 insertions, 4 deletions
diff --git a/HISTORY b/HISTORY
index ba37f11a..70be80d1 100644
--- a/HISTORY
+++ b/HISTORY
@@ -3366,3 +3366,4 @@ Video Disk Recorder Revision History
replay of a recording that has no Dolby Digital audio after switching to a channel
that has DD and selecting the DD audio track).
- Removed 'flags' from tTrackId (thought we would need this, but apparently we don't).
+- Making sure the "Mute" and "Volume+/-" keys don't interfere with digital audio.
diff --git a/device.c b/device.c
index 8d52a2c1..ad852d3a 100644
--- a/device.c
+++ b/device.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: device.c 1.83 2005/02/06 11:43:20 kls Exp $
+ * $Id: device.c 1.84 2005/02/06 12:30:01 kls Exp $
*/
#include "device.h"
@@ -646,6 +646,7 @@ void cDevice::ClrAvailableTracks(bool DescriptionsOnly)
memset(availableTracks, 0, sizeof(availableTracks));
pre_1_3_19_PrivateStream = false;
SetAudioChannel(0); // fall back to stereo
+ currentAudioTrackMissingCount = 0;
}
}
@@ -721,7 +722,7 @@ void cDevice::EnsureAudioTrack(bool Force)
}
// Make sure we're set to an available audio track:
const tTrackId *Track = GetTrack(GetCurrentAudioTrack());
- if (!Track || !Track->id || PreferredTrack != GetCurrentAudioTrack()) {
+ if (Force || !Track || !Track->id || PreferredTrack != GetCurrentAudioTrack()) {
dsyslog("setting audio track to %d", PreferredTrack);
SetCurrentAudioTrack(PreferredTrack);
}
diff --git a/dvbdevice.c b/dvbdevice.c
index e8862cb4..269c0a29 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.116 2005/01/16 12:05:13 kls Exp $
+ * $Id: dvbdevice.c 1.117 2005/02/06 12:30:14 kls Exp $
*/
#include "dvbdevice.h"
@@ -842,6 +842,8 @@ void cDvbDevice::SetAudioChannelDevice(int AudioChannel)
void cDvbDevice::SetVolumeDevice(int Volume)
{
if (HasDecoder()) {
+ if (digitalAudio)
+ Volume = 0;
audio_mixer_t am;
// conversion for linear volume response:
am.volume_left = am.volume_right = 2 * Volume - Volume * Volume / 255;
@@ -854,8 +856,8 @@ void cDvbDevice::SetDigitalAudioDevice(bool On)
if (digitalAudio != On) {
if (digitalAudio)
cCondWait::SleepMs(1000); // Wait until any leftover digital data has been flushed
- SetVolumeDevice(On || IsMute() ? 0 : CurrentVolume());
digitalAudio = On;
+ SetVolumeDevice(On || IsMute() ? 0 : CurrentVolume());
}
}