MythTV  master
Public Member Functions | Protected Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | List of all members
MythBDBuffer Class Reference

#include <mythbdbuffer.h>

Inheritance diagram for MythBDBuffer:
Inheritance graph
[legend]
Collaboration diagram for MythBDBuffer:
Collaboration graph
[legend]

Public Member Functions

 MythBDBuffer (const QString &Filename)
 
 ~MythBDBuffer () override
 
bool GetNameAndSerialNum (QString &Name, QString &SerialNum) override
 
void IgnoreWaitStates (bool Ignore) override
 
bool StartFromBeginning (void) override
 
long long GetReadPosition (void) const override
 
bool IsOpen (void) const override
 
bool IsInStillFrame (void) const override
 
bool HandleAction (const QStringList &Actions, mpeg::chrono::pts Pts) override
 
bool OpenFile (const QString &Filename, std::chrono::milliseconds Retry=kDefaultOpenTimeout) override
 Opens a bluray device for reading. More...
 
void ProgressUpdate (void)
 
bool BDWaitingForPlayer (void) const
 
void SkipBDWaitingForPlayer (void)
 
bool GetBDStateSnapshot (QString &State)
 Get a snapshot of the current BD state. More...
 
bool RestoreBDStateSnapshot (const QString &State)
 Restore a BD snapshot. More...
 
void ClearOverlays (void)
 
MythBDOverlayGetOverlay (void)
 
void SubmitOverlay (const bd_overlay_s *Overlay)
 
void SubmitARGBOverlay (const bd_argb_overlay_s *Overlay)
 
uint32_t GetNumTitles (void) const
 
int GetCurrentTitle (void)
 
uint64_t GetCurrentAngle (void) const
 
std::chrono::seconds GetTitleDuration (int Title)
 
uint64_t GetTitleSize (void) const
 
std::chrono::seconds GetTotalTimeOfTitle (void) const
 
std::chrono::seconds GetCurrentTime (void) const
 
uint64_t GetTotalReadPosition (void)
 
uint32_t GetNumChapters (void)
 
uint32_t GetCurrentChapter (void)
 
uint64_t GetNumAngles (void) const
 
std::chrono::milliseconds GetChapterStartTimeMs (uint32_t Chapter)
 
std::chrono::seconds GetChapterStartTime (uint32_t Chapter)
 
uint64_t GetChapterStartFrame (uint32_t Chapter)
 
bool IsHDMVNavigation (void) const
 
bool TitleChanged (void)
 
bool IsValidStream (uint StreamId)
 
void UnblockReading (void)
 
bool IsReadingBlocked (void)
 
int64_t AdjustTimestamp (int64_t Timestamp) const
 
void GetDescForPos (QString &Desc)
 
double GetFrameRate (void)
 
int GetAudioLanguage (uint StreamID)
 
int GetSubtitleLanguage (uint StreamID)
 
void Close (void)
 
bool GoToMenu (const QString &Menu, mpeg::chrono::pts Pts)
 jump to a Blu-ray root or popup menu More...
 
bool SwitchTitle (uint32_t Index)
 
bool SwitchPlaylist (uint32_t Index)
 
bool SwitchAngle (uint Angle)
 
- Public Member Functions inherited from MythOpticalBuffer
 MythOpticalBuffer (MythBufferType Type)
 
bool IsInMenu (void) const override
 
bool IsStreamed (void) override
 
- Public Member Functions inherited from MythMediaBuffer
 ~MythMediaBuffer () override=0
 Deletes. More...
 
MythBufferType GetType () const
 
void SetOldFile (bool Old)
 Tell RingBuffer if this is an old file or not. More...
 
void UpdateRawBitrate (uint RawBitrate)
 Set the raw bit rate, to allow RingBuffer adjust effective bitrate. More...
 
void UpdatePlaySpeed (float PlaySpeed)
 Set the play speed, to allow RingBuffer adjust effective bitrate. More...
 
void EnableBitrateMonitor (bool Enable)
 
void SetBufferSizeFactors (bool EstBitrate, bool Matroska)
 Tells RingBuffer that the raw bitrate may be inaccurate and the underlying container is matroska, both of which may require a larger buffer size. More...
 
void SetWaitForWrite (void)
 
QString GetSafeFilename (void)
 
QString GetFilename (void) const
 
QString GetSubtitleFilename (void) const
 
QString GetLastError (void) const
 
bool GetCommsError (void) const
 
void ResetCommsError (void)
 
bool GetStopReads (void) const
 
QString GetDecoderRate (void)
 
QString GetStorageRate (void)
 
QString GetAvailableBuffer (void)
 
uint GetBufferSize (void) const
 
bool IsNearEnd (double Framerate, uint Frames) const
 
long long GetWritePosition (void) const
 Returns how far into a ThreadedFileWriter file we have written. More...
 
long long GetRealFileSize (void) const
 
bool IsDisc (void) const
 
bool IsDVD (void) const
 
bool IsBD (void) const
 
const MythDVDBufferDVD (void) const
 
MythDVDBufferDVD (void)
 
const MythBDBufferBD (void) const
 
MythBDBufferBD (void)
 
int Read (void *Buffer, int Count)
 This is the public method for reading from a file, it calls the appropriate read method if the file is remote or buffered, or a BD/DVD. More...
 
int Peek (void *Buffer, int Count)
 
int Peek (std::vector< char > &Buffer)
 
void Reset (bool Full=false, bool ToAdjust=false, bool ResetInternal=false)
 Resets the read-ahead thread and our position in the file. More...
 
void Pause (void)
 Pauses the read-ahead thread. Calls StopReads(void). More...
 
void Unpause (void)
 Unpauses the read-ahead thread. Calls StartReads(void). More...
 
void WaitForPause (void)
 Waits for Pause(void) to take effect. More...
 
void Start (void)
 Starts the read-ahead thread. More...
 
void StopReads (void)
 
void StartReads (void)
 
long long Seek (long long Position, int Whence, bool HasLock=false)
 
long long SetAdjustFilesize (void)
 
int GetReadBufAvail (void) const
 Returns number of bytes available for reading from buffer. More...
 
bool SetReadInternalMode (bool Mode)
 
bool IsReadInternalMode (void) const
 
bool LiveMode (void) const
 Returns true if this RingBuffer has been assigned a LiveTVChain. More...
 
void SetLiveMode (LiveTVChain *Chain)
 Assigns a LiveTVChain to this RingBuffer. More...
 
void IgnoreLiveEOF (bool Ignore)
 Tells RingBuffer whether to ignore the end-of-file. More...
 
int Write (const void *Buffer, uint Count)
 Writes buffer to ThreadedFileWriter::Write(const void*,uint) More...
 
bool IsIOBound (void) const
 
void WriterFlush (void)
 Calls ThreadedFileWriter::Flush(void) More...
 
void Sync (void)
 Calls ThreadedFileWriter::Sync(void) More...
 
long long WriterSeek (long long Position, int Whence, bool HasLock=false)
 Calls ThreadedFileWriter::Seek(long long,int). More...
 
bool WriterSetBlocking (bool Lock=true)
 Calls ThreadedFileWriter::SetBlocking(bool) More...
 
virtual bool IsSeekingAllowed (void)
 
virtual bool IsBookmarkAllowed (void)
 
virtual int BestBufferSize (void)
 
virtual bool IsInDiscMenuOrStillFrame (void) const
 
virtual bool ReOpen (const QString &="")
 

Protected Member Functions

int SafeRead (void *Buffer, uint Size) override
 
long long SeekInternal (long long Position, int Whence) override
 
uint64_t SeekInternal (uint64_t Position)
 
- Protected Member Functions inherited from MythMediaBuffer
 MythMediaBuffer (MythBufferType Type)
 
void run (void) override
 Runs the Qt event loop unless we have a QRunnable, in which case we run the runnable run instead. More...
 
void CreateReadAheadBuffer (void)
 
void CalcReadAheadThresh (void)
 Calculates m_fillMin, m_fillThreshold, and m_readBlockSize from the estimated effective bitrate of the stream. More...
 
bool PauseAndWait (void)
 
int ReadPriv (void *Buffer, int Count, bool Peek)
 When possible reads from the read-ahead buffer, otherwise reads directly from the device. More...
 
int ReadDirect (void *Buffer, int Count, bool Peek)
 
bool WaitForReadsAllowed (void)
 
int WaitForAvail (int Count, std::chrono::milliseconds Timeout)
 
int ReadBufFree (void) const
 Returns number of bytes available for reading into buffer. More...
 
int ReadBufAvail (void) const
 Returns number of bytes available for reading from buffer. More...
 
void ResetReadAhead (long long NewInternal)
 Restart the read-ahead thread at the 'newinternal' position. More...
 
void KillReadAheadThread (void)
 Stops the read-ahead thread, and waits for it to stop. More...
 
uint64_t UpdateDecoderRate (uint64_t Latest=0)
 
uint64_t UpdateStorageRate (uint64_t Latest=0)
 
virtual long long GetRealFileSizeInternal (void) const
 
- Protected Member Functions inherited from MThread
int exec (void)
 Enters the qt event loop. call exit or quit to exit thread. More...
 
 MThread (const QString &objectName)
 Standard constructor. More...
 
 MThread (const QString &objectName, QRunnable *runnable)
 Use this constructor if you want the default run() method to run the QRunnable's run() method instead of entering the Qt event loop. More...
 
virtual ~MThread ()
 
 MThread (const MThread &)=delete
 
MThreadoperator= (const MThread &)=delete
 
void RunProlog (void)
 Sets up a thread, call this if you reimplement run(). More...
 
void RunEpilog (void)
 Cleans up a thread's resources, call this if you reimplement run(). More...
 
QThread * qthread (void)
 Returns the thread, this will always return the same pointer no matter how often you restart the thread. More...
 
void setObjectName (const QString &name)
 
QString objectName (void) const
 
void setPriority (QThread::Priority priority)
 
QThread::Priority priority (void) const
 
bool isFinished (void) const
 
bool isRunning (void) const
 
void setStackSize (uint stackSize)
 
uint stackSize (void) const
 
void exit (int retcode=0)
 Use this to exit from the thread if you are using a Qt event loop. More...
 
void start (QThread::Priority p=QThread::InheritPriority)
 Tell MThread to start running the thread in the near future. More...
 
void terminate (void)
 Kill a thread unsafely. More...
 
void quit (void)
 calls exit(0) More...
 
bool wait (std::chrono::milliseconds time=std::chrono::milliseconds::max())
 Wait for the MThread to exit, with a maximum timeout. More...
 

Private Member Functions

void WaitForPlayer (void)
 
bool UpdateTitleInfo (void)
 
BLURAY_TITLE_INFO * GetTitleInfo (uint32_t Index)
 
BLURAY_TITLE_INFO * GetPlaylistInfo (uint32_t Index)
 
void PressButton (int32_t Key, mpeg::chrono::pts Pts)
 
void ClickButton (int64_t Pts, uint16_t X, uint16_t Y)
 
bool HandleBDEvents (void)
 
void HandleBDEvent (BD_EVENT &Event)
 

Static Private Member Functions

static const BLURAY_STREAM_INFO * FindStream (uint StreamID, BLURAY_STREAM_INFO *Streams, int StreamCount)
 Find the stream with the given ID from an array of streams. More...
 

Private Attributes

BLURAY * m_bdnav { nullptr }
 
bool m_isHDMVNavigation { false }
 
bool m_tryHDMVNavigation { false }
 
bool m_topMenuSupported { false }
 
bool m_firstPlaySupported { false }
 
uint32_t m_numTitles { 0 }
 
uint32_t m_mainTitle { 0 }
 
mpeg::chrono::pts m_currentTitleLength { 0_pts }
 
BLURAY_TITLE_INFO * m_currentTitleInfo { nullptr }
 
uint64_t m_titlesize { 0 }
 
uint64_t m_currentTitleAngleCount { 0 }
 
mpeg::chrono::pts m_currentTime { 0_pts }
 
int m_imgHandle { -1 }
 
int m_currentTitle { -1 }
 
int m_currentPlaylist { 0 }
 
int m_currentPlayitem { 0 }
 
int m_currentChapter { 0 }
 
int m_currentAudioStream { 0 }
 
int m_currentIGStream { 0 }
 
int m_currentPGTextSTStream { 0 }
 
int m_currentSecondaryAudioStream { 0 }
 
int m_currentSecondaryVideoStream { 0 }
 
bool m_pgTextSTEnabled { false }
 
bool m_secondaryAudioEnabled { false }
 
bool m_secondaryVideoEnabled { false }
 
bool m_secondaryVideoIsFullscreen { false }
 
bool m_titleChanged { false }
 
bool m_playerWait { false }
 
bool m_ignorePlayerWait { true }
 
QMutex m_overlayLock
 
QList< MythBDOverlay * > m_overlayImages
 
QVector< MythBDOverlay * > m_overlayPlanes
 
std::chrono::seconds m_stillTime { 0 }
 
int m_stillMode { BLURAY_STILL_NONE}
 
BD_EVENT m_lastEvent { BD_EVENT_NONE, 0}
 
QByteArray m_pendingData
 
int64_t m_timeDiff { 0 }
 
QHash< uint32_t, BLURAY_TITLE_INFO * > m_cachedTitleInfo
 
QHash< uint32_t, BLURAY_TITLE_INFO * > m_cachedPlaylistInfo
 
QRecursiveMutex m_infoLock
 
QThread * m_mainThread { nullptr }
 

Additional Inherited Members

- Static Public Member Functions inherited from MythMediaBuffer
static MythMediaBufferCreate (const QString &Filename, bool Write, bool UseReadAhead=true, std::chrono::milliseconds Timeout=kDefaultOpenTimeout, bool StreamOnly=false)
 Creates a RingBuffer instance. More...
 
static QString BitrateToString (uint64_t Rate, bool Hz=false)
 
static void AVFormatInitNetwork (void)
 
- Static Public Attributes inherited from MythMediaBuffer
static constexpr std::chrono::milliseconds kDefaultOpenTimeout { 2s }
 
static constexpr std::chrono::milliseconds kLiveTVOpenTimeout { 10s }
 
- Protected Types inherited from MythOpticalBuffer
enum  MythOpticalState { PROCESS_NORMAL, PROCESS_REPROCESS, PROCESS_WAIT }
 
- Static Protected Member Functions inherited from MThread
static void setTerminationEnabled (bool enabled=true)
 
static void usleep (std::chrono::microseconds time)
 
template<typename R , typename P >
static std::enable_if_t< std::chrono::treat_as_floating_point< R >::value, void > usleep (std::chrono::duration< R, P > time)
 
static void ThreadSetup (const QString &name)
 This is to be called on startup in those few threads that haven't been ported to MThread. More...
 
static void ThreadCleanup (void)
 This is to be called on exit in those few threads that haven't been ported to MThread. More...
 
static void Cleanup (void)
 This will print out all the running threads, call exit(1) on each and then wait up to 5 seconds total for all the threads to exit. More...
 
static void GetAllThreadNames (QStringList &list)
 
static void GetAllRunningThreadNames (QStringList &list)
 
- Protected Attributes inherited from MythOpticalBuffer
MythOpticalState m_processState { PROCESS_NORMAL }
 
int m_currentAngle { 0 }
 
bool m_inMenu { false }
 
QString m_discName
 
QString m_discSerialNumber
 
- Protected Attributes inherited from MythMediaBuffer
MythBufferType m_type
 
QReadWriteLock m_posLock
 
long long m_readPos { 0 }
 
long long m_writePos { 0 }
 
long long m_internalReadPos { 0 }
 
long long m_ignoreReadPos { -1 }
 
QReadWriteLock m_rbrLock
 
int m_rbrPos { 0 }
 
QReadWriteLock m_rbwLock
 
int m_rbwPos { 0 }
 
volatile bool m_stopReads {false}
 
QString m_safeFilename
 
QReadWriteLock m_rwLock
 
QString m_filename
 
QString m_subtitleFilename
 
QString m_lastError
 
ThreadedFileWriterm_tfw { nullptr }
 
int m_fd2 { -1 }
 
bool m_writeMode { false }
 
RemoteFilem_remotefile { nullptr }
 
uint m_bufferSize { BUFFER_SIZE_MINIMUM }
 
bool m_lowBuffers { false }
 
bool m_fileIsMatroska { false }
 
bool m_unknownBitrate { false }
 
bool m_startReadAhead { false }
 
char * m_readAheadBuffer { nullptr }
 
bool m_readAheadRunning { false }
 
bool m_reallyRunning { false }
 
bool m_requestPause { false }
 
bool m_paused { false }
 
bool m_ateof { false }
 
bool m_waitForWrite { false }
 
bool m_beingWritten { false }
 
bool m_readsAllowed { false }
 
bool m_readsDesired { false }
 
volatile bool m_recentSeek { true }
 
bool m_setSwitchToNext { false }
 
uint m_rawBitrate { 8000 }
 
float m_playSpeed { 1.0F }
 
int m_fillThreshold { 65536 }
 
int m_fillMin { -1 }
 
int m_readBlockSize { DEFAULT_CHUNK_SIZE}
 
int m_wantToRead { 0 }
 
int m_numFailures { 0 }
 
bool m_commsError { false }
 
bool m_oldfile { false }
 
LiveTVChainm_liveTVChain { nullptr }
 
bool m_ignoreLiveEOF { false }
 
long long m_readAdjust { 0 }
 
int m_readOffset { 0 }
 
bool m_readInternalMode { false }
 
bool m_bitrateMonitorEnabled { false }
 
QMutex m_decoderReadLock
 
QMap< std::chrono::milliseconds, uint64_t > m_decoderReads
 
QMutex m_storageReadLock
 
QMap< std::chrono::milliseconds, uint64_t > m_storageReads
 
QWaitCondition m_generalWait
 Condition to signal that the read ahead thread is running. More...
 
- Protected Attributes inherited from MThread
MThreadInternalm_thread {nullptr}
 
QRunnable * m_runnable {nullptr}
 
bool m_prologExecuted {true}
 
bool m_epilogExecuted {true}
 

Detailed Description

A class to allow a MythMediaBuffer to read from BDs.

Definition at line 19 of file mythbdbuffer.h.

Constructor & Destructor Documentation

◆ MythBDBuffer()

MythBDBuffer::MythBDBuffer ( const QString &  Filename)
explicit

Definition at line 79 of file mythbdbuffer.cpp.

◆ ~MythBDBuffer()

MythBDBuffer::~MythBDBuffer ( )
override

Definition at line 88 of file mythbdbuffer.cpp.

Member Function Documentation

◆ GetNameAndSerialNum()

bool MythBDBuffer::GetNameAndSerialNum ( QString &  Name,
QString &  SerialNum 
)
overridevirtual

◆ IgnoreWaitStates()

void MythBDBuffer::IgnoreWaitStates ( bool  Ignore)
overridevirtual

Reimplemented from MythMediaBuffer.

Definition at line 1242 of file mythbdbuffer.cpp.

◆ StartFromBeginning()

bool MythBDBuffer::StartFromBeginning ( void  )
overridevirtual

Reimplemented from MythMediaBuffer.

Definition at line 1247 of file mythbdbuffer.cpp.

◆ GetReadPosition()

long long MythBDBuffer::GetReadPosition ( void  ) const
overridevirtual

Implements MythMediaBuffer.

Definition at line 540 of file mythbdbuffer.cpp.

◆ IsOpen()

bool MythBDBuffer::IsOpen ( void  ) const
overridevirtual

◆ IsInStillFrame()

bool MythBDBuffer::IsInStillFrame ( void  ) const
overridevirtual

Reimplemented from MythMediaBuffer.

Definition at line 1168 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::DisplayPauseFrame(), and MythBDPlayer::VideoLoop().

◆ HandleAction()

bool MythBDBuffer::HandleAction ( const QStringList &  Actions,
mpeg::chrono::pts  Pts 
)
overridevirtual

Reimplemented from MythMediaBuffer.

Definition at line 190 of file mythbdbuffer.cpp.

◆ OpenFile()

bool MythBDBuffer::OpenFile ( const QString &  Filename,
std::chrono::milliseconds  Retry = kDefaultOpenTimeout 
)
overridevirtual

Opens a bluray device for reading.

Parameters
lfilenamePath of the bluray device to read.
retry_msIgnored. This value is part of the API inherited from the parent class.
Returns
Returns true if the bluray was opened.

Implements MythMediaBuffer.

Definition at line 271 of file mythbdbuffer.cpp.

Referenced by MythBDBuffer().

◆ ProgressUpdate()

void MythBDBuffer::ProgressUpdate ( void  )

Definition at line 241 of file mythbdbuffer.cpp.

Referenced by FileOpenedCallback().

◆ BDWaitingForPlayer()

bool MythBDBuffer::BDWaitingForPlayer ( void  ) const

Definition at line 253 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::VideoLoop().

◆ SkipBDWaitingForPlayer()

void MythBDBuffer::SkipBDWaitingForPlayer ( void  )

Definition at line 258 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::VideoLoop().

◆ GetBDStateSnapshot()

bool MythBDBuffer::GetBDStateSnapshot ( QString &  State)

Get a snapshot of the current BD state.

Definition at line 1268 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::SetBookmark().

◆ RestoreBDStateSnapshot()

bool MythBDBuffer::RestoreBDStateSnapshot ( const QString &  State)

Restore a BD snapshot.

Definition at line 1282 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::VideoStart().

◆ ClearOverlays()

void MythBDBuffer::ClearOverlays ( void  )

Definition at line 1323 of file mythbdbuffer.cpp.

Referenced by Close().

◆ GetOverlay()

MythBDOverlay * MythBDBuffer::GetOverlay ( void  )

Definition at line 1347 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::DisplayMenu().

◆ SubmitOverlay()

void MythBDBuffer::SubmitOverlay ( const bd_overlay_s *  Overlay)

Definition at line 1355 of file mythbdbuffer.cpp.

Referenced by HandleOverlayCallback().

◆ SubmitARGBOverlay()

void MythBDBuffer::SubmitARGBOverlay ( const bd_argb_overlay_s *  Overlay)

Definition at line 1435 of file mythbdbuffer.cpp.

Referenced by HandleARGBOverlayCallback().

◆ GetNumTitles()

uint32_t MythBDBuffer::GetNumTitles ( void  ) const

Definition at line 593 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::GetNumTitles(), and GetTitleDuration().

◆ GetCurrentTitle()

int MythBDBuffer::GetCurrentTitle ( void  )

Definition at line 598 of file mythbdbuffer.cpp.

Referenced by GetBDStateSnapshot(), and MythBDPlayer::GetCurrentTitle().

◆ GetCurrentAngle()

uint64_t MythBDBuffer::GetCurrentAngle ( void  ) const

Definition at line 604 of file mythbdbuffer.cpp.

Referenced by GetBDStateSnapshot(), and MythBDPlayer::GetCurrentAngle().

◆ GetTitleDuration()

std::chrono::seconds MythBDBuffer::GetTitleDuration ( int  Title)

Definition at line 609 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::GetTitleDuration().

◆ GetTitleSize()

uint64_t MythBDBuffer::GetTitleSize ( void  ) const

Definition at line 623 of file mythbdbuffer.cpp.

◆ GetTotalTimeOfTitle()

std::chrono::seconds MythBDBuffer::GetTotalTimeOfTitle ( void  ) const

Definition at line 628 of file mythbdbuffer.cpp.

Referenced by DecoderBase::PosMapFromDb(), and DecoderBase::SyncPositionMap().

◆ GetCurrentTime()

std::chrono::seconds MythBDBuffer::GetCurrentTime ( void  ) const

◆ GetTotalReadPosition()

uint64_t MythBDBuffer::GetTotalReadPosition ( void  )

Definition at line 802 of file mythbdbuffer.cpp.

Referenced by DecoderBase::PosMapFromDb().

◆ GetNumChapters()

uint32_t MythBDBuffer::GetNumChapters ( void  )

◆ GetCurrentChapter()

uint32_t MythBDBuffer::GetCurrentChapter ( void  )

Definition at line 560 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::GetCurrentChapter().

◆ GetNumAngles()

uint64_t MythBDBuffer::GetNumAngles ( void  ) const

Definition at line 797 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::GetNumAngles().

◆ GetChapterStartTimeMs()

std::chrono::milliseconds MythBDBuffer::GetChapterStartTimeMs ( uint32_t  Chapter)

Definition at line 567 of file mythbdbuffer.cpp.

Referenced by UpdateTitleInfo().

◆ GetChapterStartTime()

std::chrono::seconds MythBDBuffer::GetChapterStartTime ( uint32_t  Chapter)

Definition at line 576 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::GetChapterTimes().

◆ GetChapterStartFrame()

uint64_t MythBDBuffer::GetChapterStartFrame ( uint32_t  Chapter)

Definition at line 585 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::GetChapter(), and UpdateTitleInfo().

◆ IsHDMVNavigation()

bool MythBDBuffer::IsHDMVNavigation ( void  ) const

◆ TitleChanged()

bool MythBDBuffer::TitleChanged ( void  )

Definition at line 779 of file mythbdbuffer.cpp.

Referenced by MythBDDecoder::StreamChangeCheck().

◆ IsValidStream()

bool MythBDBuffer::IsValidStream ( uint  StreamId)

Definition at line 1191 of file mythbdbuffer.cpp.

Referenced by MythBDDecoder::IsValidStream().

◆ UnblockReading()

void MythBDBuffer::UnblockReading ( void  )

Definition at line 1210 of file mythbdbuffer.cpp.

Referenced by MythBDDecoder::ReadPacket().

◆ IsReadingBlocked()

bool MythBDBuffer::IsReadingBlocked ( void  )

Definition at line 1215 of file mythbdbuffer.cpp.

Referenced by MythBDDecoder::ReadPacket().

◆ AdjustTimestamp()

int64_t MythBDBuffer::AdjustTimestamp ( int64_t  Timestamp) const

Definition at line 809 of file mythbdbuffer.cpp.

Referenced by MythBDDecoder::ReadPacket().

◆ GetDescForPos()

void MythBDBuffer::GetDescForPos ( QString &  Desc)

Definition at line 182 of file mythbdbuffer.cpp.

◆ GetFrameRate()

double MythBDBuffer::GetFrameRate ( void  )

◆ GetAudioLanguage()

int MythBDBuffer::GetAudioLanguage ( uint  StreamID)

Definition at line 891 of file mythbdbuffer.cpp.

Referenced by MythBDDecoder::GetAudioLanguage().

◆ GetSubtitleLanguage()

int MythBDBuffer::GetSubtitleLanguage ( uint  StreamID)

Definition at line 913 of file mythbdbuffer.cpp.

Referenced by MythBDDecoder::GetSubtitleLanguage().

◆ Close()

void MythBDBuffer::Close ( void  )

Definition at line 94 of file mythbdbuffer.cpp.

Referenced by OpenFile(), and ~MythBDBuffer().

◆ GoToMenu()

bool MythBDBuffer::GoToMenu ( const QString &  Menu,
mpeg::chrono::pts  Pts 
)

jump to a Blu-ray root or popup menu

Definition at line 954 of file mythbdbuffer.cpp.

Referenced by MythBDPlayer::GoToMenu().

◆ SwitchTitle()

bool MythBDBuffer::SwitchTitle ( uint32_t  Index)

Definition at line 638 of file mythbdbuffer.cpp.

Referenced by OpenFile(), RestoreBDStateSnapshot(), and MythBDPlayer::SwitchTitle().

◆ SwitchPlaylist()

bool MythBDBuffer::SwitchPlaylist ( uint32_t  Index)

Definition at line 651 of file mythbdbuffer.cpp.

Referenced by HandleBDEvent().

◆ SwitchAngle()

bool MythBDBuffer::SwitchAngle ( uint  Angle)

Definition at line 786 of file mythbdbuffer.cpp.

Referenced by RestoreBDStateSnapshot(), and MythBDPlayer::SwitchAngle().

◆ SafeRead()

int MythBDBuffer::SafeRead ( void *  Buffer,
uint  Size 
)
overrideprotectedvirtual

Implements MythMediaBuffer.

Definition at line 817 of file mythbdbuffer.cpp.

◆ SeekInternal() [1/2]

long long MythBDBuffer::SeekInternal ( long long  Position,
int  Whence 
)
overrideprotectedvirtual

Implements MythMediaBuffer.

Definition at line 119 of file mythbdbuffer.cpp.

Referenced by RestoreBDStateSnapshot().

◆ SeekInternal() [2/2]

uint64_t MythBDBuffer::SeekInternal ( uint64_t  Position)
protected

Definition at line 173 of file mythbdbuffer.cpp.

◆ WaitForPlayer()

void MythBDBuffer::WaitForPlayer ( void  )
private

Definition at line 1225 of file mythbdbuffer.cpp.

Referenced by HandleBDEvent().

◆ UpdateTitleInfo()

bool MythBDBuffer::UpdateTitleInfo ( void  )
private

Definition at line 709 of file mythbdbuffer.cpp.

Referenced by SwitchPlaylist(), and SwitchTitle().

◆ GetTitleInfo()

BLURAY_TITLE_INFO * MythBDBuffer::GetTitleInfo ( uint32_t  Index)
private

Definition at line 668 of file mythbdbuffer.cpp.

Referenced by GetTitleDuration(), OpenFile(), and SwitchTitle().

◆ GetPlaylistInfo()

BLURAY_TITLE_INFO * MythBDBuffer::GetPlaylistInfo ( uint32_t  Index)
private

Definition at line 690 of file mythbdbuffer.cpp.

Referenced by SwitchPlaylist().

◆ PressButton()

void MythBDBuffer::PressButton ( int32_t  Key,
mpeg::chrono::pts  Pts 
)
private

Definition at line 933 of file mythbdbuffer.cpp.

Referenced by GoToMenu(), and HandleAction().

◆ ClickButton()

void MythBDBuffer::ClickButton ( int64_t  Pts,
uint16_t  X,
uint16_t  Y 
)
private

Definition at line 943 of file mythbdbuffer.cpp.

◆ HandleBDEvents()

bool MythBDBuffer::HandleBDEvents ( void  )
private

Definition at line 984 of file mythbdbuffer.cpp.

Referenced by SafeRead().

◆ HandleBDEvent()

void MythBDBuffer::HandleBDEvent ( BD_EVENT &  Event)
private

Definition at line 1005 of file mythbdbuffer.cpp.

Referenced by HandleBDEvents(), and SafeRead().

◆ FindStream()

const BLURAY_STREAM_INFO * MythBDBuffer::FindStream ( uint  StreamID,
BLURAY_STREAM_INFO *  Streams,
int  StreamCount 
)
staticprivate

Find the stream with the given ID from an array of streams.

Parameters
streamidThe stream ID (pid) to look for
streamsPointer to an array of streams
streamCountNumber of streams in the array
Returns
Pointer to the matching stream if found, otherwise nullptr.

Definition at line 1180 of file mythbdbuffer.cpp.

Referenced by GetAudioLanguage(), GetSubtitleLanguage(), and IsValidStream().

Member Data Documentation

◆ m_bdnav

BLURAY* MythBDBuffer::m_bdnav { nullptr }
private

◆ m_isHDMVNavigation

bool MythBDBuffer::m_isHDMVNavigation { false }
private

◆ m_tryHDMVNavigation

bool MythBDBuffer::m_tryHDMVNavigation { false }
private

Definition at line 98 of file mythbdbuffer.h.

Referenced by MythBDBuffer(), and OpenFile().

◆ m_topMenuSupported

bool MythBDBuffer::m_topMenuSupported { false }
private

Definition at line 99 of file mythbdbuffer.h.

Referenced by GoToMenu(), and OpenFile().

◆ m_firstPlaySupported

bool MythBDBuffer::m_firstPlaySupported { false }
private

Definition at line 100 of file mythbdbuffer.h.

Referenced by OpenFile().

◆ m_numTitles

uint32_t MythBDBuffer::m_numTitles { 0 }
private

Definition at line 101 of file mythbdbuffer.h.

Referenced by GetNumTitles(), GetTitleInfo(), and OpenFile().

◆ m_mainTitle

uint32_t MythBDBuffer::m_mainTitle { 0 }
private

Definition at line 102 of file mythbdbuffer.h.

Referenced by OpenFile().

◆ m_currentTitleLength

mpeg::chrono::pts MythBDBuffer::m_currentTitleLength { 0_pts }
private

Definition at line 103 of file mythbdbuffer.h.

Referenced by GetTotalTimeOfTitle(), OpenFile(), and UpdateTitleInfo().

◆ m_currentTitleInfo

BLURAY_TITLE_INFO* MythBDBuffer::m_currentTitleInfo { nullptr }
private

◆ m_titlesize

uint64_t MythBDBuffer::m_titlesize { 0 }
private

Definition at line 105 of file mythbdbuffer.h.

Referenced by GetTitleSize(), OpenFile(), and UpdateTitleInfo().

◆ m_currentTitleAngleCount

uint64_t MythBDBuffer::m_currentTitleAngleCount { 0 }
private

Definition at line 106 of file mythbdbuffer.h.

Referenced by GetNumAngles(), OpenFile(), and UpdateTitleInfo().

◆ m_currentTime

mpeg::chrono::pts MythBDBuffer::m_currentTime { 0_pts }
private

Definition at line 107 of file mythbdbuffer.h.

Referenced by GetBDStateSnapshot(), GetCurrentTime(), OpenFile(), SafeRead(), and SeekInternal().

◆ m_imgHandle

int MythBDBuffer::m_imgHandle { -1 }
private

Definition at line 108 of file mythbdbuffer.h.

Referenced by Close(), and OpenFile().

◆ m_currentTitle

int MythBDBuffer::m_currentTitle { -1 }
private

◆ m_currentPlaylist

int MythBDBuffer::m_currentPlaylist { 0 }
private

Definition at line 110 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_currentPlayitem

int MythBDBuffer::m_currentPlayitem { 0 }
private

Definition at line 111 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), OpenFile(), and UpdateTitleInfo().

◆ m_currentChapter

int MythBDBuffer::m_currentChapter { 0 }
private

Definition at line 112 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_currentAudioStream

int MythBDBuffer::m_currentAudioStream { 0 }
private

Definition at line 113 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_currentIGStream

int MythBDBuffer::m_currentIGStream { 0 }
private

Definition at line 114 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_currentPGTextSTStream

int MythBDBuffer::m_currentPGTextSTStream { 0 }
private

Definition at line 115 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_currentSecondaryAudioStream

int MythBDBuffer::m_currentSecondaryAudioStream { 0 }
private

Definition at line 116 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_currentSecondaryVideoStream

int MythBDBuffer::m_currentSecondaryVideoStream { 0 }
private

Definition at line 117 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_pgTextSTEnabled

bool MythBDBuffer::m_pgTextSTEnabled { false }
private

Definition at line 118 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_secondaryAudioEnabled

bool MythBDBuffer::m_secondaryAudioEnabled { false }
private

Definition at line 119 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_secondaryVideoEnabled

bool MythBDBuffer::m_secondaryVideoEnabled { false }
private

Definition at line 120 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_secondaryVideoIsFullscreen

bool MythBDBuffer::m_secondaryVideoIsFullscreen { false }
private

Definition at line 121 of file mythbdbuffer.h.

Referenced by HandleBDEvent(), and OpenFile().

◆ m_titleChanged

bool MythBDBuffer::m_titleChanged { false }
private

Definition at line 122 of file mythbdbuffer.h.

Referenced by TitleChanged(), and UpdateTitleInfo().

◆ m_playerWait

bool MythBDBuffer::m_playerWait { false }
private

Definition at line 123 of file mythbdbuffer.h.

Referenced by BDWaitingForPlayer(), SkipBDWaitingForPlayer(), and WaitForPlayer().

◆ m_ignorePlayerWait

bool MythBDBuffer::m_ignorePlayerWait { true }
private

Definition at line 124 of file mythbdbuffer.h.

Referenced by IgnoreWaitStates(), and WaitForPlayer().

◆ m_overlayLock

QMutex MythBDBuffer::m_overlayLock
private

Definition at line 125 of file mythbdbuffer.h.

Referenced by ClearOverlays(), GetOverlay(), SubmitARGBOverlay(), and SubmitOverlay().

◆ m_overlayImages

QList<MythBDOverlay*> MythBDBuffer::m_overlayImages
private

Definition at line 126 of file mythbdbuffer.h.

Referenced by ClearOverlays(), GetOverlay(), SubmitARGBOverlay(), and SubmitOverlay().

◆ m_overlayPlanes

QVector<MythBDOverlay*> MythBDBuffer::m_overlayPlanes
private

Definition at line 127 of file mythbdbuffer.h.

Referenced by ClearOverlays(), SubmitARGBOverlay(), and SubmitOverlay().

◆ m_stillTime

std::chrono::seconds MythBDBuffer::m_stillTime { 0 }
private

Definition at line 128 of file mythbdbuffer.h.

Referenced by IsInStillFrame(), OpenFile(), and UpdateTitleInfo().

◆ m_stillMode

int MythBDBuffer::m_stillMode { BLURAY_STILL_NONE}
private

Definition at line 129 of file mythbdbuffer.h.

Referenced by IsInStillFrame(), OpenFile(), and UpdateTitleInfo().

◆ m_lastEvent

BD_EVENT MythBDBuffer::m_lastEvent { BD_EVENT_NONE, 0}
private

Definition at line 130 of file mythbdbuffer.h.

Referenced by HandleBDEvents(), and OpenFile().

◆ m_pendingData

QByteArray MythBDBuffer::m_pendingData
private

Definition at line 131 of file mythbdbuffer.h.

Referenced by SafeRead().

◆ m_timeDiff

int64_t MythBDBuffer::m_timeDiff { 0 }
private

Definition at line 132 of file mythbdbuffer.h.

Referenced by AdjustTimestamp(), HandleBDEvent(), OpenFile(), and UpdateTitleInfo().

◆ m_cachedTitleInfo

QHash<uint32_t,BLURAY_TITLE_INFO*> MythBDBuffer::m_cachedTitleInfo
private

Definition at line 133 of file mythbdbuffer.h.

Referenced by Close(), and GetTitleInfo().

◆ m_cachedPlaylistInfo

QHash<uint32_t,BLURAY_TITLE_INFO*> MythBDBuffer::m_cachedPlaylistInfo
private

Definition at line 134 of file mythbdbuffer.h.

Referenced by Close(), and GetPlaylistInfo().

◆ m_infoLock

QRecursiveMutex MythBDBuffer::m_infoLock
private

◆ m_mainThread

QThread* MythBDBuffer::m_mainThread { nullptr }
private

Definition at line 136 of file mythbdbuffer.h.

Referenced by MythBDBuffer(), and ProgressUpdate().


The documentation for this class was generated from the following files: