don't constantly hammer demuxer to get stream count
authorpopcornmix <popcornmix@gmail.com>
Mon, 18 Nov 2013 17:54:31 +0000 (17:54 +0000)
committerJoakim Plate <elupus@ecce.se>
Thu, 21 Nov 2013 21:49:27 +0000 (22:49 +0100)
Note this could cause regressions in files where streams show
up during playback, but i think the demuxer signals such
situations now.

xbmc/cores/omxplayer/OMXPlayer.cpp

index ad31325..43316fe 100644 (file)
@@ -3042,8 +3042,6 @@ float COMXPlayer::GetSubTitleDelay()
 // priority: 1: libdvdnav, 2: external subtitles, 3: muxed subtitles
 int COMXPlayer::GetSubtitleCount()
 {
-  OMXStreamLock lock(this);
-  m_SelectionStreams.Update(m_pInputStream, m_pDemuxer);
   return m_SelectionStreams.Count(STREAM_SUBTITLE);
 }
 
@@ -3095,8 +3093,6 @@ void COMXPlayer::SetSubtitleVisible(bool bVisible)
 
 int COMXPlayer::GetAudioStreamCount()
 {
-  OMXStreamLock lock(this);
-  m_SelectionStreams.Update(m_pInputStream, m_pDemuxer);
   return m_SelectionStreams.Count(STREAM_AUDIO);
 }