[rbp/omxplayer] fixed edl marks. for omx we have to do a full flush. fixes #13672...
authorgimli <ebsi4711@gmail.com>
Sat, 22 Dec 2012 10:56:02 +0000 (11:56 +0100)
committergimli <ebsi4711@gmail.com>
Sat, 22 Dec 2012 10:56:02 +0000 (11:56 +0100)
xbmc/cores/omxplayer/OMXPlayer.cpp
xbmc/cores/omxplayer/OMXPlayerAudio.cpp
xbmc/cores/omxplayer/OMXPlayerAudio.h
xbmc/cores/omxplayer/OMXPlayerVideo.cpp
xbmc/cores/omxplayer/OMXPlayerVideo.h

index a230d9c..5d3cd5c 100644 (file)
@@ -1880,7 +1880,7 @@ void COMXPlayer::CheckAutoSceneSkip()
     /*
      * Seeking is NOT flushed so any content up to the demux point is retained when playing forwards.
      */
-    m_messenger.Put(new CDVDMsgPlayerSeek((int)seek, true, false, true, false, true));
+    m_messenger.Put(new CDVDMsgPlayerSeek((int)seek, true, true, true, false, true));
     /*
      * Seek doesn't always work reliably. Last physical seek time is recorded to prevent looping
      * if there was an error with seeking and it landed somewhere unexpected, perhaps back in the
@@ -1898,7 +1898,7 @@ void COMXPlayer::CheckAutoSceneSkip()
     /*
      * Seeking is NOT flushed so any content up to the demux point is retained when playing forwards.
      */
-    m_messenger.Put(new CDVDMsgPlayerSeek(cut.end + 1, true, false, true, false, true));
+    m_messenger.Put(new CDVDMsgPlayerSeek(cut.end + 1, true, true, true, false, true));
     /*
      * Each commercial break is only skipped once so poorly detected commercial breaks can be
      * manually re-entered. Start and end are recorded to prevent looping and to allow seeking back
index c962f43..e39aad9 100644 (file)
@@ -147,7 +147,6 @@ void OMXPlayerAudio::OpenStream(CDVDStreamInfo &hints, COMXAudioCodecOMX *codec)
   m_errortime       = CurrentHostCounter();
   m_silence         = false;
   m_started         = false;
-  m_flush           = false;
   m_nChannels       = 0;
   m_synctype        = SYNC_DISCON;
   m_stalled         = m_messageQueue.GetPacketCount(CDVDMsg::DEMUXER_PACKET) == 0;
@@ -369,12 +368,6 @@ bool OMXPlayerAudio::Decode(DemuxPacket *pkt, bool bDropPacket)
 
       while(!m_bStop)
       {
-        if(m_flush)
-        {
-          m_flush = false;
-          break;
-        }
-
         if(m_omxAudio.GetSpace() < (unsigned int)pkt->iSize)
         {
           Sleep(10);
@@ -417,12 +410,6 @@ bool OMXPlayerAudio::Decode(DemuxPacket *pkt, bool bDropPacket)
 
     while(!m_bStop)
     {
-      if(m_flush)
-      {
-        m_flush = false;
-        break;
-      }
-
       if(m_omxAudio.GetSpace() < (unsigned int)pkt->iSize)
       {
         Sleep(10);
@@ -623,7 +610,6 @@ void OMXPlayerAudio::Process()
 
 void OMXPlayerAudio::Flush()
 {
-  m_flush = true;
   m_messageQueue.Flush();
   m_messageQueue.Put( new CDVDMsg(CDVDMsg::GENERAL_FLUSH), 1);
 }
index 505e91f..40725fd 100644 (file)
@@ -81,7 +81,6 @@ protected:
 
   struct timespec           m_starttime, m_endtime;
   bool                      m_buffer_empty;
-  bool                      m_flush;
   //SYNC_DISCON, SYNC_SKIPDUP, SYNC_RESAMPLE
   int                       m_synctype;
   int                       m_nChannels;
index 6455419..065cd73 100644 (file)
@@ -76,7 +76,6 @@ OMXPlayerVideo::OMXPlayerVideo(OMXClock *av_clock,
   m_open                  = false;
   m_stream_id             = -1;
   m_fFrameRate            = 25.0f;
-  m_flush                 = false;
   m_hdmi_clock_sync       = false;
   m_speed                 = DVD_PLAYSPEED_NORMAL;
   m_stalled               = false;
@@ -121,7 +120,6 @@ bool OMXPlayerVideo::OpenStream(CDVDStreamInfo &hints)
 
   m_hints       = hints;
   m_Deinterlace = ( g_settings.m_currentVideoSettings.m_DeinterlaceMode == VS_DEINTERLACEMODE_OFF ) ? false : true;
-  m_flush       = false;
   m_hdmi_clock_sync = (g_guiSettings.GetInt("videoplayer.adjustrefreshrate") != ADJUST_REFRESHRATE_OFF);
   m_started     = false;
   m_stalled     = m_messageQueue.GetPacketCount(CDVDMsg::DEMUXER_PACKET) == 0;
@@ -170,8 +168,6 @@ bool OMXPlayerVideo::OpenStream(CDVDStreamInfo &hints, COMXVideo *codec)
 
 bool OMXPlayerVideo::CloseStream(bool bWaitForBuffers)
 {
-  m_flush   = true;
-
   // wait until buffers are empty
   if (bWaitForBuffers && m_speed > 0) m_messageQueue.WaitUntilEmpty();
 
@@ -615,12 +611,6 @@ void OMXPlayerVideo::Process()
 
       while (!m_bStop)
       {
-        if(m_flush)
-        {
-          m_flush = false;
-          break;
-        }
-
         if((int)m_omxVideo.GetFreeSpace() < pPacket->iSize)
         {
           Sleep(10);
@@ -685,7 +675,6 @@ void OMXPlayerVideo::Process()
 
 void OMXPlayerVideo::Flush()
 {
-  m_flush = true;
   m_messageQueue.Flush();
   m_messageQueue.Put(new CDVDMsg(CDVDMsg::GENERAL_FLUSH), 1);
 }
index b2fc085..7ab5dcc 100644 (file)
@@ -53,7 +53,6 @@ protected:
   COMXVideo                 m_omxVideo;
   float                     m_fFrameRate;
   bool                      m_Deinterlace;
-  bool                      m_flush;
   bool                      m_hdmi_clock_sync;
   double                    m_iVideoDelay;
   int                       m_speed;