Advertisement
Guest User

Preliminary patch to allow playback of stills with audio

a guest
Jan 8th, 2013
65
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Diff 2.63 KB | None | 0 0
  1. diff --git a/mythtv/libs/libmythtv/DVD/dvdringbuffer.cpp b/mythtv/libs/libmythtv/DVD/dvdringbuffer.cpp
  2. index 9beb59a..5cf0cff 100644
  3. --- a/mythtv/libs/libmythtv/DVD/dvdringbuffer.cpp
  4. +++ b/mythtv/libs/libmythtv/DVD/dvdringbuffer.cpp
  5. @@ -766,7 +766,13 @@ int DVDRingBuffer::safe_read(void *data, uint sz)
  6.                  }
  7.  
  8.                  // debug
  9. -                LOG(VB_PLAYBACK, LOG_DEBUG, LOC + "DVDNAV_NAV_PACKET");
  10. +                LOG(VB_PLAYBACK, LOG_DEBUG, LOC + QString("DVDNAV_NAV_PACKET - time:%1, pos:%2, vob:%3, cell:%4, seeking:%5, seektime:%6")
  11. +                    .arg(m_currentTime)
  12. +                    .arg(m_currentpos)
  13. +                    .arg(m_vobid)
  14. +                    .arg(m_cellid)
  15. +                    .arg(m_seeking)
  16. +                    .arg(m_seektime));
  17.  
  18.                  // release buffer
  19.                  if (blockBuf != m_dvdBlockWriteBuf)
  20. @@ -1895,7 +1901,7 @@ bool DVDRingBuffer::NewSequence(bool new_sequence)
  21.          return result;
  22.      }
  23.  
  24. -    result = m_newSequence && m_inMenu;
  25. +    result = m_newSequence;
  26.      m_newSequence = false;
  27.      if (result)
  28.          LOG(VB_PLAYBACK, LOG_INFO, LOC + "Asking for still frame");
  29. diff --git a/mythtv/libs/libmythtv/DVD/mythdvdplayer.cpp b/mythtv/libs/libmythtv/DVD/mythdvdplayer.cpp
  30. index 804aaf1..65744c3 100644
  31. --- a/mythtv/libs/libmythtv/DVD/mythdvdplayer.cpp
  32. +++ b/mythtv/libs/libmythtv/DVD/mythdvdplayer.cpp
  33. @@ -154,9 +154,8 @@ bool MythDVDPlayer::VideoLoop(void)
  34.              return !IsErrored();
  35.          }
  36.  
  37. -        // we need a custom presentation method for still frame menus with audio
  38. -        if (player_ctx->buffer->DVD()->IsInMenu() &&
  39. -            !player_ctx->buffer->DVD()->IsInStillFrame())
  40. +        // we need a custom presentation method for still frames with audio
  41. +        if (!player_ctx->buffer->DVD()->IsInStillFrame())
  42.          {
  43.              // ensure we refresh the pause frame
  44.              if (!dvd_stillframe_showing)
  45. @@ -166,9 +165,7 @@ bool MythDVDPlayer::VideoLoop(void)
  46.              DisplayLastFrame();
  47.              return !IsErrored();
  48.          }
  49. -
  50. -        // the still frame is treated as a pause frame
  51. -        if (player_ctx->buffer->DVD()->IsInStillFrame())
  52. +        else  // the still frame is treated as a pause frame
  53.          {
  54.              // ensure we refresh the pause frame
  55.              if (!dvd_stillframe_showing)
  56. @@ -195,10 +192,6 @@ bool MythDVDPlayer::VideoLoop(void)
  57.  
  58.              dvd_stillframe_showing = true;
  59.          }
  60. -        else
  61. -        {
  62. -            dvd_stillframe_showing = false;
  63. -        }
  64.      }
  65.  
  66.      // unpause the still frame if more frames become available
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement