summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2003-03-30 12:42:23 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2003-03-30 12:42:23 +0200
commitc52b219131eee937c16b3dd9ebc3706d77df689c (patch)
tree217a979b47064d59de1003c572e3b22e68e61d94
parentf79a442f443edda16353a760b0b93eb4e63aaa42 (diff)
downloadvdr-c52b219131eee937c16b3dd9ebc3706d77df689c.tar.gz
vdr-c52b219131eee937c16b3dd9ebc3706d77df689c.tar.bz2
Added some missing cAudio handling calls
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY1
-rw-r--r--device.c16
-rw-r--r--dvbdevice.c6
4 files changed, 20 insertions, 4 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index ddba8241..b563f9c7 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -219,6 +219,7 @@ Werner Fink <werner@suse.de>
for improving thread locking in the ring buffer to avoid possible race conditions
under heavy load
for improving keyboard detection
+ for adding some missing cAudio handling calls
Rolf Hakenes <hakenes@hippomi.de>
for providing 'libdtv' and adapting the EIT mechanisms to it
diff --git a/HISTORY b/HISTORY
index f4587c1a..b95c5147 100644
--- a/HISTORY
+++ b/HISTORY
@@ -2003,3 +2003,4 @@ Video Disk Recorder Revision History
(thanks to Florian Bartels for reporting this one and Sascha Volkenandt for
helping to fix it).
- Modified LOF handling to allow for C-band reception (thanks to Malcolm Caldwell).
+- Added some missing cAudio handling calls (thanks to Werner Fink).
diff --git a/device.c b/device.c
index 0f99e13b..cfcf3d22 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.37 2003/03/09 14:05:23 kls Exp $
+ * $Id: device.c 1.38 2003/03/30 12:39:29 kls Exp $
*/
#include "device.h"
@@ -422,9 +422,16 @@ bool cDevice::ToggleMute(void)
{
int OldVolume = volume;
mute = !mute;
- SetVolume(0, mute);
+ //XXX why is it necessary to use different sequences???
+ if (mute) {
+ SetVolume(0, mute);
+ Audios.MuteAudio(mute); // Mute external audio after analog audio
+ }
+ else {
+ Audios.MuteAudio(mute); // Enable external audio before analog audio
+ SetVolume(0, mute);
+ }
volume = OldVolume;
- Audios.MuteAudio(mute);
return mute;
}
@@ -478,10 +485,12 @@ void cDevice::Clear(void)
void cDevice::Play(void)
{
+ Audios.MuteAudio(mute);
}
void cDevice::Freeze(void)
{
+ Audios.MuteAudio(true);
}
void cDevice::Mute(void)
@@ -520,6 +529,7 @@ void cDevice::Detach(cPlayer *Player)
player = NULL;
SetPlayMode(pmNone);
playerDetached = true;
+ Audios.ClearAudio();
}
}
diff --git a/dvbdevice.c b/dvbdevice.c
index 88bf4154..58307f89 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.48 2003/03/30 11:43:14 kls Exp $
+ * $Id: dvbdevice.c 1.49 2003/03/30 12:40:47 kls Exp $
*/
#include "dvbdevice.h"
@@ -829,6 +829,7 @@ void cDvbDevice::Clear(void)
CHECK(ioctl(fd_video, VIDEO_CLEAR_BUFFER));
if (fd_audio >= 0)
CHECK(ioctl(fd_audio, AUDIO_CLEAR_BUFFER));
+ cDevice::Clear();
}
void cDvbDevice::Play(void)
@@ -843,6 +844,7 @@ void cDvbDevice::Play(void)
if (fd_video >= 0)
CHECK(ioctl(fd_video, VIDEO_CONTINUE));
}
+ cDevice::Play();
}
void cDvbDevice::Freeze(void)
@@ -857,6 +859,7 @@ void cDvbDevice::Freeze(void)
if (fd_video >= 0)
CHECK(ioctl(fd_video, VIDEO_FREEZE));
}
+ cDevice::Freeze();
}
void cDvbDevice::Mute(void)
@@ -865,6 +868,7 @@ void cDvbDevice::Mute(void)
CHECK(ioctl(fd_audio, AUDIO_SET_AV_SYNC, false));
CHECK(ioctl(fd_audio, AUDIO_SET_MUTE, true));
}
+ cDevice::Mute();
}
void cDvbDevice::StillPicture(const uchar *Data, int Length)