aboutsummaryrefslogtreecommitdiff
path: root/lib/service/servicedvb.cpp
diff options
context:
space:
mode:
authorFelix Domke <felix.domke@multimedia-labs.de>2009-08-14 13:23:54 +0200
committerFelix Domke <felix.domke@multimedia-labs.de>2009-08-14 13:23:54 +0200
commit29c3340e877cfa1d1818a140f76f14270b84c3d2 (patch)
treeae02bbd3ff630338c701b76af62daf7fdec4a8d5 /lib/service/servicedvb.cpp
parentdf505deaccfced52c34c620e367b8659a0ec6fbd (diff)
parentdf662e86097ac84a001a1fd8c20e0a8454acd103 (diff)
downloadenigma2-29c3340e877cfa1d1818a140f76f14270b84c3d2.tar.gz
enigma2-29c3340e877cfa1d1818a140f76f14270b84c3d2.zip
Merge branch 'master' of git.opendreambox.org:/git/enigma2
Diffstat (limited to 'lib/service/servicedvb.cpp')
-rw-r--r--lib/service/servicedvb.cpp17
1 files changed, 11 insertions, 6 deletions
diff --git a/lib/service/servicedvb.cpp b/lib/service/servicedvb.cpp
index 497911c5..01169986 100644
--- a/lib/service/servicedvb.cpp
+++ b/lib/service/servicedvb.cpp
@@ -1795,21 +1795,26 @@ int eDVBServicePlay::selectAudioStream(int i)
return -4;
}
+ int rdsPid = apid;
+
/* if we are not in PVR mode, timeshift is not active and we are not in pip mode, check if we need to enable the rds reader */
if (!(m_is_pvr || m_timeshift_active || !m_is_primary))
- if (!m_rds_decoder)
+ {
+ int different_pid = program.videoStreams.empty() && program.audioStreams.size() == 1 && program.audioStreams[stream].rdsPid != -1;
+ if (different_pid)
+ rdsPid = program.audioStreams[stream].rdsPid;
+ if (!m_rds_decoder || m_rds_decoder->getPid() != rdsPid)
{
+ m_rds_decoder = 0;
ePtr<iDVBDemux> data_demux;
if (!h.getDataDemux(data_demux))
{
- m_rds_decoder = new eDVBRdsDecoder(data_demux);
+ m_rds_decoder = new eDVBRdsDecoder(data_demux, different_pid);
m_rds_decoder->connectEvent(slot(*this, &eDVBServicePlay::rdsDecoderEvent), m_rds_decoder_event_connection);
+ m_rds_decoder->start(rdsPid);
}
}
-
- /* if we decided that we need one, update the pid */
- if (m_rds_decoder)
- m_rds_decoder->start(apid);
+ }
/* store new pid as default only when:
a.) we have an entry in the service db for the current service,