summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorscop <scop>2005-04-18 14:56:51 +0000
committerscop <scop>2005-04-18 14:56:51 +0000
commit679fb41b95bd77bc38f0170147f38cf9f402625b (patch)
treef3abe6961e1e8aa80b348c4197f4d0611f1e4538
parent3def0b5096a7c80e527b105741d26f9fbe7529e6 (diff)
downloadvdr-plugin-dxr3-679fb41b95bd77bc38f0170147f38cf9f402625b.tar.gz
vdr-plugin-dxr3-679fb41b95bd77bc38f0170147f38cf9f402625b.tar.bz2
Set audiomode to unknown when releasing devices, fixes digital sound after MPlayer plugin (Luca Olivetti, Kimmo Vuorinen).
-rw-r--r--CONTRIBUTORS1
-rw-r--r--HISTORY4
-rw-r--r--dxr3interface.c9
3 files changed, 9 insertions, 5 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index aa74272..1691f20 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -25,5 +25,6 @@ Stephan Skrodzki
Ville Skyttä
Mikko Tuumanen
Sascha Volkenandt
+Kimmo Vuorinen
Thank you very much :)
diff --git a/HISTORY b/HISTORY
index 5e338d7..f6edde0 100644
--- a/HISTORY
+++ b/HISTORY
@@ -287,4 +287,6 @@ NOTE: I havent found time to include all of the languages, will be done in pre2
- improved GetSTC(): fixes DVB subtitles sync problems (Mikko Tuumanen)
- fix compilation with -fPIC, kudos to ffmpeg (Ville Skyttä)
- eliminate some compiler warnings (Ville Skyttä)
-- fix aspect ratio after returning from the MPlayer plugin (Luca Olivetti)
+- set aspect ratio and audio mode to unknown when releasing devices, fixes
+ the setup eg. after returning from the MPlayer plugin
+ (Luca Olivetti, Kimmo Vuorinen)
diff --git a/dxr3interface.c b/dxr3interface.c
index ff2101c..0ca9d1f 100644
--- a/dxr3interface.c
+++ b/dxr3interface.c
@@ -32,6 +32,7 @@
const int LPCM_HEADER_LENGTH = 7;
const int ZEROBUFFER_SIZE = 4096;
uint8_t zerobuffer[ZEROBUFFER_SIZE] = {0};
+const uint32_t UNKNOWN_AUDIO_MODE = 9; // default, unused value
// ==================================
//! default spu palette
@@ -114,8 +115,7 @@ m_fdControl(-1), m_fdVideo(-1), m_fdAudio(-1), m_fdSpu(-1)
m_audioDataRate = 0;
m_audioSampleSize = 0;
- // default value 9 = unused value
- m_audioMode = 9;
+ m_audioMode = UNKNOWN_AUDIO_MODE;
m_aspectRatio = UNKNOWN_ASPECT_RATIO;
m_spuMode = EM8300_SPUMODE_OFF;
@@ -429,7 +429,7 @@ void cDxr3Interface::DisableAudio()
m_AudioActive = false;
- // we wirte zero buffers to dxr3
+ // we write zero buffers to dxr3
if (!m_ExternalReleased)
{
if (write(m_fdAudio, zerobuffer, ZEROBUFFER_SIZE) < 0) Resuscitation();
@@ -446,7 +446,7 @@ void cDxr3Interface::EnableOverlay()
{
Lock();
- // first we check, if it is enable yet
+ // first we check, if it is enabled yet
if (m_OverlayActive)
{
return;
@@ -812,6 +812,7 @@ void cDxr3Interface::ExternalReleaseDevices()
if (m_fdAudio > -1) close(m_fdAudio);
m_fdControl = m_fdVideo = m_fdSpu = m_fdAudio = -1;
m_aspectRatio = UNKNOWN_ASPECT_RATIO;
+ m_audioMode = UNKNOWN_AUDIO_MODE;
m_ExternalReleased = true;