MythTV  master
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
PlayerContext Class Reference

#include <playercontext.h>

Collaboration diagram for PlayerContext:
Collaboration graph
[legend]

Public Member Functions

 PlayerContext (QString inUseID=QString("Unknown"))
 
 ~PlayerContext ()
 
bool CreatePlayer (TV *tv, QWidget *widget, TVState desiredState, bool embed, const QRect &embedBounds=QRect(), bool muted=false)
 
void TeardownPlayer (void)
 
bool StartPlaying (int maxWait=-1)
 Starts player, must be called after StartRecorder(). More...
 
void StopPlaying (void) const
 
void UpdateTVChain (const QStringList &data=QStringList())
 
bool ReloadTVChain (void)
 
bool StartEmbedding (const QRect &rect) const
 
void StopEmbedding (void) const
 
void PushPreviousChannel (void)
 most recently selected channel to the previous channel list More...
 
QString PopPreviousChannel (void)
 
void ChangeState (TVState newState)
 Puts a state change on the nextState queue. More...
 
void ForceNextStateNone (void)
 Removes any pending state changes, and puts kState_None on the queue. More...
 
TVState DequeueNextState (void)
 
void ResizePIPWindow (void)
 
bool HandlePlayerSpeedChangeFFRew (void)
 
bool HandlePlayerSpeedChangeEOF (void)
 
void LockState (void) const
 
void UnlockState (void) const
 
void LockPlayingInfo (const char *file, int line) const
 
void UnlockPlayingInfo (const char *file, int line) const
 
void LockDeletePlayer (const char *file, int line) const
 prevent MythPlayer from being deleted used to ensure player can only be deleted after osd in TV() is unlocked. More...
 
void UnlockDeletePlayer (const char *file, int line) const
 allow player to be deleted. More...
 
void LockOSD (void) const
 
void UnlockOSD (void) const
 
void SetInitialTVState (bool islivetv)
 determine initial tv state and playgroup for the recording More...
 
void SetPlayer (MythPlayer *newplayer)
 
void SetRecorder (RemoteEncoder *rec)
 
void SetTVChain (LiveTVChain *chain)
 
void SetRingBuffer (MythMediaBuffer *Buffer)
 
void SetPlayingInfo (const ProgramInfo *info)
 assign programinfo to the context More...
 
void SetPlayGroup (const QString &group)
 
void SetPseudoLiveTV (const ProgramInfo *pi, PseudoState new_state)
 
void SetPlayerChangingBuffers (bool val)
 
void SetNoHardwareDecoders (bool Disallow=true)
 
QString GetPreviousChannel (void) const
 
bool CalcPlayerSliderPosition (osdInfo &info, bool paddedFields=false) const
 
uint GetCardID (void) const
 
QString GetFilters (const QString &baseFilters) const
 
QString GetPlayMessage (void) const
 
TVState GetState (void) const
 
bool GetPlayingInfoMap (InfoMap &infoMap) const
 
bool IsPlayerChangingBuffers (void) const
 
bool IsEmbedding (void) const
 
bool HasPlayer (void) const
 
bool IsPlayerErrored (void) const
 
bool IsPlayerPlaying (void) const
 
bool IsRecorderErrored (void) const
 
bool InStateChange (void) const
 
bool IsErrored (void) const
 This is set if the player encountered some irrecoverable error. More...
 
bool IsSameProgram (const ProgramInfo &p) const
 
bool IsValidLiveTV (void) const
 

Public Attributes

QString m_recUsage
 
MythPlayerm_player {nullptr}
 
volatile bool m_playerUnsafe {false}
 
RemoteEncoderm_recorder {nullptr}
 
LiveTVChainm_tvchain {nullptr}
 
MythMediaBufferm_buffer {nullptr}
 
ProgramInfom_playingInfo {nullptr}
 Currently playing info. More...
 
long long m_playingLen {0}
 Initial CalculateLength() More...
 
bool m_nohardwaredecoders {false}
 
int m_lastCardid {-1}
 CardID of current/last recorder. More...
 
int m_ffRewState {0}
 0 == normal, +1 == fast forward, -1 == rewind More...
 
int m_ffRewIndex {0}
 Index into m_ffRewSpeeds for FF and Rewind speeds. More...
 
int m_ffRewSpeed {0}
 Caches value of m_ffRewSpeeds[m_ffRewIndex]. More...
 
TVState m_playingState {kState_None}
 
bool m_errored {false}
 
StringDeque m_prevChan
 Previous channels. More...
 
ProgramInfom_pseudoLiveTVRec {nullptr}
 
PseudoState m_pseudoLiveTVState {kPseudoNormalLiveTV}
 
int m_fftime {0}
 
int m_rewtime {0}
 
int m_jumptime {0}
 
float m_tsNormal {1.0F}
 Time stretch speed, 1.0F for normal playback. More...
 
float m_tsAlt {1.5F}
 
QMutex m_playingInfoLock {QMutex::Recursive}
 
QMutex m_deletePlayerLock {QMutex::Recursive}
 
QMutex m_stateLock {QMutex::Recursive}
 
QStringList m_lastSignalMsg
 
MythTimer m_lastSignalMsgTime
 
InfoMap m_lastSignalUIInfo
 
MythTimer m_lastSignalUIInfoTime
 
MythDeque< TVStatem_nextState
 

Static Public Attributes

static const uint kSMExitTimeout = 2000
 Timeout after last Signal Monitor message for ignoring OSD when exiting. More...
 
static const uint kMaxChannelHistory = 30
 

Detailed Description

Definition at line 48 of file playercontext.h.

Constructor & Destructor Documentation

◆ PlayerContext()

PlayerContext::PlayerContext ( QString  inUseID = QString("Unknown"))
explicit

Definition at line 30 of file playercontext.cpp.

◆ ~PlayerContext()

PlayerContext::~PlayerContext ( )

Definition at line 37 of file playercontext.cpp.

Member Function Documentation

◆ CreatePlayer()

bool PlayerContext::CreatePlayer ( TV tv,
QWidget *  widget,
TVState  desiredState,
bool  embed,
const QRect &  embedBounds = QRect(),
bool  muted = false 
)

Definition at line 191 of file playercontext.cpp.

Referenced by TV::StartPlayer(), and TV::SwitchInputs().

◆ TeardownPlayer()

void PlayerContext::TeardownPlayer ( void  )

Definition at line 43 of file playercontext.cpp.

Referenced by TV::ScheduleStateChange(), ~PlayerContext(), and TV::~TV().

◆ StartPlaying()

bool PlayerContext::StartPlaying ( int  maxWait = -1)

Starts player, must be called after StartRecorder().

Parameters
maxWaitHow long to wait for MythPlayer to start playing.
Returns
true when successful, false otherwise.

Definition at line 252 of file playercontext.cpp.

Referenced by CreatePlayer().

◆ StopPlaying()

void PlayerContext::StopPlaying ( void  ) const

Definition at line 286 of file playercontext.cpp.

Referenced by SetPlayer(), StartPlaying(), TV::StopStuff(), and TV::SwitchInputs().

◆ UpdateTVChain()

void PlayerContext::UpdateTVChain ( const QStringList &  data = QStringList())

Definition at line 292 of file playercontext.cpp.

Referenced by TV::customEvent().

◆ ReloadTVChain()

bool PlayerContext::ReloadTVChain ( void  )

◆ StartEmbedding()

bool PlayerContext::StartEmbedding ( const QRect &  rect) const

Definition at line 99 of file playercontext.cpp.

Referenced by TV::StartEmbedding().

◆ StopEmbedding()

void PlayerContext::StopEmbedding ( void  ) const

Definition at line 122 of file playercontext.cpp.

Referenced by TV::StopEmbedding().

◆ PushPreviousChannel()

void PlayerContext::PushPreviousChannel ( void  )

most recently selected channel to the previous channel list

Definition at line 321 of file playercontext.cpp.

Referenced by TV::ChangeChannel(), PopPreviousChannel(), TV::SwitchInputs(), and TV::UnpauseLiveTV().

◆ PopPreviousChannel()

QString PlayerContext::PopPreviousChannel ( void  )

Definition at line 340 of file playercontext.cpp.

Referenced by TV::PopPreviousChannel().

◆ ChangeState()

void PlayerContext::ChangeState ( TVState  newState)

Puts a state change on the nextState queue.

Definition at line 462 of file playercontext.cpp.

Referenced by TV::customEvent(), and SetInitialTVState().

◆ ForceNextStateNone()

void PlayerContext::ForceNextStateNone ( void  )

Removes any pending state changes, and puts kState_None on the queue.

Definition at line 477 of file playercontext.cpp.

Referenced by TV::ForceNextStateNone().

◆ DequeueNextState()

TVState PlayerContext::DequeueNextState ( void  )

Definition at line 468 of file playercontext.cpp.

Referenced by TV::HandleStateChange().

◆ ResizePIPWindow()

void PlayerContext::ResizePIPWindow ( void  )

◆ HandlePlayerSpeedChangeFFRew()

bool PlayerContext::HandlePlayerSpeedChangeFFRew ( void  )

Definition at line 148 of file playercontext.cpp.

Referenced by TV::HandleSpeedChangeTimerEvent().

◆ HandlePlayerSpeedChangeEOF()

bool PlayerContext::HandlePlayerSpeedChangeEOF ( void  )

Definition at line 161 of file playercontext.cpp.

Referenced by TV::HandleSpeedChangeTimerEvent().

◆ LockState()

void PlayerContext::LockState ( void  ) const

Definition at line 430 of file playercontext.cpp.

Referenced by TV::HandleStateChange().

◆ UnlockState()

void PlayerContext::UnlockState ( void  ) const

Definition at line 435 of file playercontext.cpp.

Referenced by TV::HandleStateChange().

◆ LockPlayingInfo()

void PlayerContext::LockPlayingInfo ( const char *  file,
int  line 
) const

Definition at line 374 of file playercontext.cpp.

Referenced by TVBrowseHelper::BrowseStart(), TV::ChangeChannel(), TV::CommitQueuedInput(), TV::customEvent(), MythPlayer::DisableEdit(), TV::DoEditSchedule(), TV::DoQueueTranscode(), MythPlayer::EnableEdit(), MythPlayer::EventLoop(), MythPlayer::EventStart(), MythBDPlayer::EventStart(), MythDVDPlayer::EventStart(), MythPlayer::FileChanged(), TV::FillOSDMenuJumpRec(), MythPlayer::GetBookmark(), MythBDPlayer::GetBookmark(), MythDVDPlayer::GetBookmark(), GetFilters(), GetPlayingInfoMap(), MythCommFlagPlayer::GetRawVideoFrame(), TV::GetRecordingGroup(), TV::GetStatus(), TV::HandleOSDAlreadyEditing(), TV::HandleStateChange(), TV::IsBookmarkAllowed(), TV::IsDeleteAllowed(), DeleteMap::IsFileEditing(), MythPlayer::IsNearEnd(), IsSameProgram(), DeleteMap::IsSaved(), TV::ITVRestart(), DeleteMap::LoadAutoSaveMap(), DeleteMap::LoadMap(), CommBreakMap::LoadMap(), MythPlayer::OpenDummy(), MythPlayer::OpenFile(), TV::PlaybackMenuInit(), TV::ProcessNetworkControlCommand(), TV::QuickRecord(), MythCommFlagPlayer::RebuildSeekTable(), MythCCExtractorPlayer::run(), DeleteMap::SaveMap(), MythBDPlayer::SetBookmark(), MythPlayer::SetBookmark(), MythDVDPlayer::SetBookmark(), DeleteMap::SetFileEditing(), SetInitialTVState(), MythPlayer::SetPlayingInfo(), MythPlayer::SetWatched(), TV::ShowLCDChannelInfo(), TV::ShowOSDPromptDeleteRecording(), TV::ShowOSDStopWatchingRecording(), TV::StartProgramEditMode(), TV::SwitchInputs(), TV::ToggleAutoExpire(), MythPlayer::TranscodeGetNextFrame(), and DeleteMap::UpdateOSD().

◆ UnlockPlayingInfo()

void PlayerContext::UnlockPlayingInfo ( const char *  file,
int  line 
) const

Definition at line 386 of file playercontext.cpp.

Referenced by TVBrowseHelper::BrowseStart(), TV::ChangeChannel(), TV::CommitQueuedInput(), TV::customEvent(), MythPlayer::DisableEdit(), TV::DoEditSchedule(), TV::DoQueueTranscode(), MythPlayer::EnableEdit(), MythPlayer::EventLoop(), MythPlayer::EventStart(), MythBDPlayer::EventStart(), MythDVDPlayer::EventStart(), MythPlayer::FileChanged(), TV::FillOSDMenuJumpRec(), MythPlayer::GetBookmark(), MythBDPlayer::GetBookmark(), MythDVDPlayer::GetBookmark(), GetFilters(), GetPlayingInfoMap(), MythCommFlagPlayer::GetRawVideoFrame(), TV::GetRecordingGroup(), TV::GetStatus(), TV::HandleOSDAlreadyEditing(), TV::HandleStateChange(), TV::IsBookmarkAllowed(), TV::IsDeleteAllowed(), DeleteMap::IsFileEditing(), MythPlayer::IsNearEnd(), IsSameProgram(), DeleteMap::IsSaved(), TV::ITVRestart(), DeleteMap::LoadAutoSaveMap(), DeleteMap::LoadMap(), CommBreakMap::LoadMap(), MythPlayer::OpenDummy(), MythPlayer::OpenFile(), TV::PlaybackMenuInit(), TV::ProcessNetworkControlCommand(), TV::QuickRecord(), MythCommFlagPlayer::RebuildSeekTable(), MythCCExtractorPlayer::run(), DeleteMap::SaveMap(), MythBDPlayer::SetBookmark(), MythPlayer::SetBookmark(), MythDVDPlayer::SetBookmark(), DeleteMap::SetFileEditing(), SetInitialTVState(), MythPlayer::SetPlayingInfo(), MythPlayer::SetWatched(), TV::ShowLCDChannelInfo(), TV::ShowOSDPromptDeleteRecording(), TV::ShowOSDStopWatchingRecording(), TV::StartProgramEditMode(), TV::SwitchInputs(), TV::ToggleAutoExpire(), MythPlayer::TranscodeGetNextFrame(), and DeleteMap::UpdateOSD().

◆ LockDeletePlayer()

void PlayerContext::LockDeletePlayer ( const char *  file,
int  line 
) const

prevent MythPlayer from being deleted used to ensure player can only be deleted after osd in TV() is unlocked.

Definition at line 403 of file playercontext.cpp.

Referenced by TV::ActiveHandleAction(), TV::ActivePostQHandleAction(), TV::ChangeAudioSync(), TV::ChangeChannel(), TV::ChangeSpeed(), TV::ChangeSubtitleDelay(), TV::ChangeSubtitleZoom(), TV::ChangeTimeStretch(), TV::ChangeVolume(), TV::ChannelEditXDSFill(), TV::ContextIsPaused(), TV::customEvent(), TV::DoArbSeek(), TV::DoChangePictureAttribute(), TV::DoEditSchedule(), TV::DoJumpChapter(), TV::DoPlay(), TV::DoPlayerSeek(), TV::DoPlayerSeekToFrame(), TV::DoSeek(), TV::DoSeekAbsolute(), TV::DoSkipCommercials(), TV::DoSwitchAngle(), TV::DoSwitchTitle(), TV::DoToggleNightMode(), TV::DoTogglePause(), TV::DoTogglePauseStart(), TV::DoTogglePictureAttribute(), TV::DVDJumpBack(), TV::DVDJumpForward(), TV::EnableUpmix(), TV::EnableVisualisation(), TV::event(), TV::GetAngleName(), TV::GetChapterTimes(), TV::GetCurrentAngle(), TV::GetCurrentChapter(), TV::GetCurrentTitle(), TV::GetNumAngles(), TV::GetNumChapters(), TV::GetNumTitles(), TV::GetOSDL(), TV::GetStatus(), TV::GetTitleDuration(), TV::GetTitleName(), TV::Handle3D(), TV::HandleEndOfRecordingExitPromptTimerEvent(), TV::HandleIsNearEndWhenEmbeddingTimerEvent(), TV::HandleOSDAlreadyEditing(), TV::HandleOSDClosed(), TV::HandleOSDVideoExit(), TV::HandleSaveLastPlayPosEvent(), TV::HandleTrackAction(), IsEmbedding(), TV::IsPaused(), TV::ITVRestart(), TV::ManualZoomHandleAction(), TV::MenuItemDisplayCutlist(), TV::MenuItemDisplayPlayback(), TV::NormalSpeed(), TV::OSDDialogEvent(), TV::OverrideScan(), TV::PauseAudioUntilBuffered(), TV::PauseLiveTV(), TV::PlaybackLoop(), TV::PlaybackMenuInit(), TV::PrepareToExitPlayer(), TV::ProcessKeypressOrGesture(), TV::ProcessNetworkControlCommand(), TV::SaveBottomLine(), TV::SeekHandleAction(), TV::SetAutoCommercialSkip(), TV::SetBookmark(), TV::SetFFRew(), StartEmbedding(), TV::StartProgramEditMode(), TV::StartTV(), TV::StopEmbedding(), StopEmbedding(), TV::StopFFRew(), TV::StopStuff(), TV::SwitchInputs(), TV::ToggleAdjustFill(), TV::ToggleAspectOverride(), TV::ToggleMoveBottomLine(), TV::ToggleMute(), TV::UnpauseLiveTV(), and TV::UpdateNavDialog().

◆ UnlockDeletePlayer()

void PlayerContext::UnlockDeletePlayer ( const char *  file,
int  line 
) const

allow player to be deleted.

Definition at line 418 of file playercontext.cpp.

Referenced by TV::ActiveHandleAction(), TV::ActivePostQHandleAction(), TV::ChangeAudioSync(), TV::ChangeChannel(), TV::ChangeSpeed(), TV::ChangeSubtitleDelay(), TV::ChangeSubtitleZoom(), TV::ChangeTimeStretch(), TV::ChangeVolume(), TV::ChannelEditXDSFill(), TV::ContextIsPaused(), TV::customEvent(), TV::DoArbSeek(), TV::DoChangePictureAttribute(), TV::DoEditSchedule(), TV::DoJumpChapter(), TV::DoPlay(), TV::DoPlayerSeek(), TV::DoPlayerSeekToFrame(), TV::DoSeek(), TV::DoSeekAbsolute(), TV::DoSkipCommercials(), TV::DoSwitchAngle(), TV::DoSwitchTitle(), TV::DoToggleNightMode(), TV::DoTogglePause(), TV::DoTogglePauseStart(), TV::DoTogglePictureAttribute(), TV::DVDJumpBack(), TV::DVDJumpForward(), TV::EnableUpmix(), TV::EnableVisualisation(), TV::event(), TV::GetAngleName(), TV::GetChapterTimes(), TV::GetCurrentAngle(), TV::GetCurrentChapter(), TV::GetCurrentTitle(), TV::GetNumAngles(), TV::GetNumChapters(), TV::GetNumTitles(), TV::GetOSDL(), TV::GetStatus(), TV::GetTitleDuration(), TV::GetTitleName(), TV::Handle3D(), TV::HandleEndOfRecordingExitPromptTimerEvent(), TV::HandleIsNearEndWhenEmbeddingTimerEvent(), TV::HandleOSDAlreadyEditing(), TV::HandleOSDClosed(), TV::HandleOSDVideoExit(), TV::HandleSaveLastPlayPosEvent(), TV::HandleTrackAction(), IsEmbedding(), TV::IsPaused(), TV::ITVRestart(), TV::ManualZoomHandleAction(), TV::MenuItemDisplayCutlist(), TV::MenuItemDisplayPlayback(), TV::NormalSpeed(), TV::OSDDialogEvent(), TV::OverrideScan(), TV::PauseAudioUntilBuffered(), TV::PauseLiveTV(), TV::PlaybackLoop(), TV::PlaybackMenuInit(), TV::PrepareToExitPlayer(), TV::ProcessKeypressOrGesture(), TV::ProcessNetworkControlCommand(), TV::ReturnOSDLock(), TV::SaveBottomLine(), TV::SeekHandleAction(), TV::SetAutoCommercialSkip(), TV::SetBookmark(), TV::SetFFRew(), StartEmbedding(), TV::StartProgramEditMode(), TV::StartTV(), TV::StopEmbedding(), StopEmbedding(), TV::StopFFRew(), TV::StopStuff(), TV::SwitchInputs(), TV::ToggleAdjustFill(), TV::ToggleAspectOverride(), TV::ToggleMoveBottomLine(), TV::ToggleMute(), TV::UnpauseLiveTV(), and TV::UpdateNavDialog().

◆ LockOSD()

void PlayerContext::LockOSD ( void  ) const

Definition at line 440 of file playercontext.cpp.

Referenced by TV::GetOSDL().

◆ UnlockOSD()

void PlayerContext::UnlockOSD ( void  ) const

Definition at line 445 of file playercontext.cpp.

Referenced by TV::GetOSDL(), and TV::ReturnOSDLock().

◆ SetInitialTVState()

void PlayerContext::SetInitialTVState ( bool  islivetv)

determine initial tv state and playgroup for the recording

Parameters
islivetvtrue if recording is livetv

Definition at line 61 of file playercontext.cpp.

Referenced by TV::LiveTV(), and TV::Playback().

◆ SetPlayer()

void PlayerContext::SetPlayer ( MythPlayer newplayer)

Definition at line 601 of file playercontext.cpp.

Referenced by CreatePlayer(), TV::SwitchInputs(), and TeardownPlayer().

◆ SetRecorder()

void PlayerContext::SetRecorder ( RemoteEncoder rec)

◆ SetTVChain()

void PlayerContext::SetTVChain ( LiveTVChain chain)

Definition at line 627 of file playercontext.cpp.

Referenced by SetInitialTVState(), and TeardownPlayer().

◆ SetRingBuffer()

void PlayerContext::SetRingBuffer ( MythMediaBuffer Buffer)

Definition at line 652 of file playercontext.cpp.

Referenced by TV::HandleStateChange(), TV::SwitchInputs(), and TeardownPlayer().

◆ SetPlayingInfo()

void PlayerContext::SetPlayingInfo ( const ProgramInfo info)

assign programinfo to the context

Definition at line 666 of file playercontext.cpp.

Referenced by TV::Playback(), ReloadTVChain(), MythPlayer::SetPlayingInfo(), and TeardownPlayer().

◆ SetPlayGroup()

void PlayerContext::SetPlayGroup ( const QString &  group)

Definition at line 689 of file playercontext.cpp.

Referenced by SetInitialTVState().

◆ SetPseudoLiveTV()

void PlayerContext::SetPseudoLiveTV ( const ProgramInfo pi,
PseudoState  new_state 
)

Definition at line 698 of file playercontext.cpp.

Referenced by TV::customEvent(), TV::QuickRecord(), and TV::SwitchInputs().

◆ SetPlayerChangingBuffers()

void PlayerContext::SetPlayerChangingBuffers ( bool  val)
inline

◆ SetNoHardwareDecoders()

void PlayerContext::SetNoHardwareDecoders ( bool  Disallow = true)
inline

Definition at line 100 of file playercontext.h.

◆ GetPreviousChannel()

QString PlayerContext::GetPreviousChannel ( void  ) const

Definition at line 360 of file playercontext.cpp.

Referenced by TV::PlaybackMenuInit(), and TV::ShowPreviousChannel().

◆ CalcPlayerSliderPosition()

bool PlayerContext::CalcPlayerSliderPosition ( osdInfo info,
bool  paddedFields = false 
) const

◆ GetCardID()

uint PlayerContext::GetCardID ( void  ) const
inline

◆ GetFilters()

QString PlayerContext::GetFilters ( const QString &  baseFilters) const

Definition at line 544 of file playercontext.cpp.

◆ GetPlayMessage()

QString PlayerContext::GetPlayMessage ( void  ) const

◆ GetState()

TVState PlayerContext::GetState ( void  ) const

◆ GetPlayingInfoMap()

bool PlayerContext::GetPlayingInfoMap ( InfoMap infoMap) const

◆ IsPlayerChangingBuffers()

bool PlayerContext::IsPlayerChangingBuffers ( void  ) const
inline

◆ IsEmbedding()

bool PlayerContext::IsEmbedding ( void  ) const

Definition at line 112 of file playercontext.cpp.

Referenced by TV::StartEmbedding(), and TV::StopEmbedding().

◆ HasPlayer()

bool PlayerContext::HasPlayer ( void  ) const

◆ IsPlayerErrored()

bool PlayerContext::IsPlayerErrored ( void  ) const

Definition at line 136 of file playercontext.cpp.

Referenced by TV::HandleStateChange(), and TV::timerEvent().

◆ IsPlayerPlaying()

bool PlayerContext::IsPlayerPlaying ( void  ) const

Definition at line 142 of file playercontext.cpp.

Referenced by TV::HandleEndOfPlaybackTimerEvent().

◆ IsRecorderErrored()

bool PlayerContext::IsRecorderErrored ( void  ) const

Definition at line 186 of file playercontext.cpp.

Referenced by MythPlayer::EventLoop(), and TV::timerEvent().

◆ InStateChange()

bool PlayerContext::InStateChange ( void  ) const

Definition at line 450 of file playercontext.cpp.

Referenced by TV::GetState(), and TV::HandlePseudoLiveTVTimerEvent().

◆ IsErrored()

bool PlayerContext::IsErrored ( void  ) const
inline

This is set if the player encountered some irrecoverable error.

Definition at line 121 of file playercontext.h.

Referenced by TV::HandleStateChange(), TV::IsPaused(), and TV::timerEvent().

◆ IsSameProgram()

bool PlayerContext::IsSameProgram ( const ProgramInfo p) const

Definition at line 534 of file playercontext.cpp.

Referenced by TV::IsSameProgram().

◆ IsValidLiveTV()

bool PlayerContext::IsValidLiveTV ( void  ) const
inline

Definition at line 123 of file playercontext.h.

Member Data Documentation

◆ m_recUsage

QString PlayerContext::m_recUsage

Definition at line 127 of file playercontext.h.

Referenced by SetPlayingInfo().

◆ m_player

MythPlayer* PlayerContext::m_player {nullptr}

Definition at line 128 of file playercontext.h.

Referenced by TV::ActiveHandleAction(), TV::ActivePostQHandleAction(), CalcPlayerSliderPosition(), TV::ChangeAudioSync(), TV::ChangeChannel(), TV::ChangeSpeed(), TV::ChangeSubtitleDelay(), TV::ChangeSubtitleZoom(), TV::ChangeTimeStretch(), TV::ChangeVolume(), TV::ChannelEditXDSFill(), DeleteMap::CleanMap(), TV::ContextIsPaused(), TV::customEvent(), TV::DiscMenuHandleAction(), TV::DoArbSeek(), TV::DoChangePictureAttribute(), TV::DoEditSchedule(), TV::DoJumpChapter(), TV::DoPlay(), TV::DoPlayerSeek(), TV::DoPlayerSeekToFrame(), TV::DoSeek(), TV::DoSeekAbsolute(), TV::DoSkipCommercials(), TV::DoSwitchAngle(), TV::DoSwitchTitle(), TV::DoToggleNightMode(), TV::DoTogglePause(), TV::DoTogglePauseStart(), TV::DoTogglePictureAttribute(), TV::DVDJumpBack(), TV::DVDJumpForward(), TV::EnableUpmix(), TV::EnableVisualisation(), TV::event(), TV::GetAngleName(), TV::GetChapterTimes(), TV::GetCurrentAngle(), TV::GetCurrentChapter(), TV::GetCurrentTitle(), DeleteMap::GetLastFrame(), DeleteMap::GetNearestMark(), TV::GetNumAngles(), TV::GetNumChapters(), TV::GetNumTitles(), TV::GetOSDL(), Transcode::GetPlayer(), GetPlayingInfoMap(), TV::GetStatus(), TV::GetTitleDuration(), TV::GetTitleName(), TV::Handle3D(), DeleteMap::HandleAction(), TV::HandleEndOfRecordingExitPromptTimerEvent(), TV::HandleIsNearEndWhenEmbeddingTimerEvent(), TV::HandleOSDAlreadyEditing(), TV::HandleOSDClosed(), TV::HandleOSDCutpoint(), TV::HandleOSDVideoExit(), HandlePlayerSpeedChangeEOF(), HandlePlayerSpeedChangeFFRew(), TV::HandleSaveLastPlayPosEvent(), TV::HandleStateChange(), TV::HandleTrackAction(), HasPlayer(), IsEmbedding(), TV::IsPaused(), IsPlayerErrored(), IsPlayerPlaying(), TV::ITVRestart(), LockOSD(), TV::ManualZoomHandleAction(), TV::MenuItemDisplayCutlist(), TV::MenuItemDisplayPlayback(), DeleteMap::Move(), DeleteMap::NewCut(), TV::NormalSpeed(), TV::OSDDialogEvent(), TV::OverrideScan(), TV::PauseAudioUntilBuffered(), TV::PauseLiveTV(), TV::PlaybackLoop(), TV::PlaybackMenuInit(), TV::PrepareToExitPlayer(), TV::ProcessKeypressOrGesture(), TV::ProcessNetworkControlCommand(), TV::SaveBottomLine(), TV::SeekHandleAction(), TV::SetAutoCommercialSkip(), TV::SetBookmark(), TV::SetFFRew(), SetPlayer(), TV::ShowOSDPromptDeleteRecording(), StartEmbedding(), StartPlaying(), TV::StartProgramEditMode(), TV::StartTV(), TV::StopEmbedding(), StopEmbedding(), TV::StopFFRew(), StopPlaying(), TV::SwitchInputs(), TV::timerEvent(), TV::ToggleAdjustFill(), TV::ToggleAspectOverride(), TV::ToggleMoveBottomLine(), TV::ToggleMute(), TV::ToggleOSDDebug(), DeleteMap::TrackerReset(), DeleteMap::TranslatePositionFrameToMs(), DeleteMap::TranslatePositionMsToFrame(), UnlockOSD(), TV::UnpauseLiveTV(), TV::UpdateNavDialog(), DeleteMap::UpdateOSD(), TV::UpdateOSDDebug(), and UpdateTVChain().

◆ m_playerUnsafe

volatile bool PlayerContext::m_playerUnsafe {false}

Definition at line 129 of file playercontext.h.

◆ m_recorder

RemoteEncoder* PlayerContext::m_recorder {nullptr}

◆ m_tvchain

LiveTVChain* PlayerContext::m_tvchain {nullptr}

◆ m_buffer

MythMediaBuffer* PlayerContext::m_buffer {nullptr}

Definition at line 132 of file playercontext.h.

Referenced by TV::ActiveHandleAction(), MythDVDPlayer::CalcMaxFFTime(), MythDVDPlayer::ChangeSpeed(), TV::ChangeVolume(), MythDVDPlayer::CreateDecoder(), MythPlayer::CreateDecoder(), MythBDPlayer::CreateDecoder(), CreatePlayer(), TV::customEvent(), MythDVDPlayer::DecoderGetFrameREW(), MythDVDPlayer::DisableCaptions(), TV::DiscMenuHandleAction(), MythDVDPlayer::DisplayDVDButton(), MythBDPlayer::DisplayMenu(), MythBDPlayer::DisplayPauseFrame(), MythDVDPlayer::DisplayPauseFrame(), MythPlayer::DoFastForward(), MythDVDPlayer::DoJumpChapter(), TV::DoPlayerSeek(), TV::DoPlayerSeekToFrame(), MythPlayer::DoRewind(), TV::DoTogglePauseFinish(), TV::DoTogglePauseStart(), TV::DVDJumpBack(), TV::DVDJumpForward(), MythDVDPlayer::EnableCaptions(), MythDVDPlayer::EventEnd(), MythPlayer::EventLoop(), MythBDPlayer::EventStart(), MythDVDPlayer::EventStart(), MythPlayer::FileChanged(), MythPlayer::GetBookmark(), MythBDPlayer::GetBookmark(), MythDVDPlayer::GetBookmark(), MythBDPlayer::GetChapter(), MythBDPlayer::GetChapterTimes(), MythDVDPlayer::GetChapterTimes(), MythBDPlayer::GetCurrentAngle(), MythDVDPlayer::GetCurrentAngle(), MythBDPlayer::GetCurrentChapter(), MythDVDPlayer::GetCurrentChapter(), MythBDPlayer::GetCurrentTitle(), MythBDPlayer::GetNumAngles(), MythDVDPlayer::GetNumAngles(), MythBDPlayer::GetNumChapters(), MythDVDPlayer::GetNumChapters(), MythBDPlayer::GetNumTitles(), MythPlayer::GetPlaybackData(), MythDVDPlayer::GetSecondsPlayed(), MythBDPlayer::GetTitleDuration(), MythDVDPlayer::GoToDVDProgram(), MythBDPlayer::GoToMenu(), MythDVDPlayer::GoToMenu(), TV::HandleLCDTimerEvent(), TV::HandleStateChange(), MythDVDPlayer::InitialSeek(), TV::IsBookmarkAllowed(), MythPlayer::IsReallyNearEnd(), MythPlayer::JumpToProgram(), MythPlayer::JumpToStream(), MythBDPlayer::NextTitle(), MythPlayer::OpenFile(), TV::OSDDialogEvent(), MythPlayer::PauseBuffer(), TV::PauseLiveTV(), TV::PlaybackMenuInit(), MythDVDPlayer::PrepareAudioSample(), MythBDPlayer::PrevTitle(), TV::ProcessKeypressOrGesture(), TV::ProcessNetworkControlCommand(), MythDVDPlayer::ReleaseNextVideoFrame(), MythDVDPlayer::SeekForScreenGrab(), MythBDPlayer::SetBookmark(), MythDVDPlayer::SetBookmark(), TV::SetFFRew(), SetRingBuffer(), MythPlayer::SetStream(), MythDVDPlayer::SetTrack(), TV::ShowLCDDVDInfo(), TV::ShowOSDStopWatchingRecording(), MythDVDPlayer::StillFrameCheck(), TV::StopStuff(), MythBDPlayer::SwitchAngle(), MythDVDPlayer::SwitchAngle(), TV::SwitchInputs(), MythBDPlayer::SwitchTitle(), MythPlayer::SwitchToProgram(), TV::timerEvent(), TV::ToggleOSDDebug(), MythPlayer::UnpauseBuffer(), TV::UnpauseLiveTV(), MythBDPlayer::VideoLoop(), MythDVDPlayer::VideoLoop(), MythBDPlayer::VideoStart(), and MythDVDPlayer::VideoStart().

◆ m_playingInfo

ProgramInfo* PlayerContext::m_playingInfo {nullptr}

Currently playing info.

Definition at line 133 of file playercontext.h.

Referenced by TVBrowseHelper::BrowseStart(), TV::ChangeChannel(), TV::CommitQueuedInput(), MythDVDPlayer::CreateDecoder(), MythPlayer::CreateDecoder(), MythBDPlayer::CreateDecoder(), TV::customEvent(), MythPlayer::DisableEdit(), TV::DoEditSchedule(), TV::DoPlay(), TV::DoQueueTranscode(), TV::DoTogglePause(), MythPlayer::EnableEdit(), MythPlayer::EventLoop(), MythPlayer::EventStart(), MythBDPlayer::EventStart(), MythDVDPlayer::EventStart(), MythPlayer::FileChanged(), TV::FillOSDMenuJumpRec(), get_chanid(), MythPlayer::GetBookmark(), MythBDPlayer::GetBookmark(), MythDVDPlayer::GetBookmark(), GetFilters(), GetPlayingInfoMap(), MythCommFlagPlayer::GetRawVideoFrame(), TV::GetRecordingGroup(), TV::GetStatus(), TV::HandleOSDAlreadyEditing(), TV::HandleSaveLastPlayPosEvent(), TV::HandleStateChange(), TV::IsBookmarkAllowed(), TV::IsDeleteAllowed(), DeleteMap::IsFileEditing(), MythPlayer::IsNearEnd(), IsSameProgram(), DeleteMap::IsSaved(), TV::ITVRestart(), DeleteMap::LoadAutoSaveMap(), DeleteMap::LoadMap(), CommBreakMap::LoadMap(), MythPlayer::OpenDummy(), MythPlayer::OpenFile(), TV::PlaybackMenuInit(), TV::PrepareToExitPlayer(), TV::ProcessNetworkControlCommand(), TV::QuickRecord(), MythCommFlagPlayer::RebuildSeekTable(), MythCCExtractorPlayer::run(), DeleteMap::SaveMap(), MythBDPlayer::SetBookmark(), MythPlayer::SetBookmark(), MythDVDPlayer::SetBookmark(), DeleteMap::SetFileEditing(), SetInitialTVState(), SetPlayingInfo(), MythPlayer::SetWatched(), TV::ShowLCDChannelInfo(), TV::ShowOSDPromptDeleteRecording(), TV::ShowOSDStopWatchingRecording(), TV::StartProgramEditMode(), TV::SwitchInputs(), TV::ToggleAutoExpire(), MythPlayer::TranscodeGetNextFrame(), and DeleteMap::UpdateOSD().

◆ m_playingLen

long long PlayerContext::m_playingLen {0}

Initial CalculateLength()

Definition at line 134 of file playercontext.h.

Referenced by CreatePlayer(), and SetPlayingInfo().

◆ m_nohardwaredecoders

bool PlayerContext::m_nohardwaredecoders {false}

Definition at line 135 of file playercontext.h.

Referenced by CreatePlayer().

◆ m_lastCardid

int PlayerContext::m_lastCardid {-1}

CardID of current/last recorder.

Definition at line 136 of file playercontext.h.

Referenced by TVBrowseHelper::BrowseChannel(), and SetRecorder().

◆ m_ffRewState

int PlayerContext::m_ffRewState {0}

◆ m_ffRewIndex

int PlayerContext::m_ffRewIndex {0}

Index into m_ffRewSpeeds for FF and Rewind speeds.

Definition at line 140 of file playercontext.h.

Referenced by TV::ChangeFFRew(), HandlePlayerSpeedChangeFFRew(), TV::Init(), TV::SetFFRew(), TV::StopFFRew(), and TeardownPlayer().

◆ m_ffRewSpeed

int PlayerContext::m_ffRewSpeed {0}

◆ m_playingState

TVState PlayerContext::m_playingState {kState_None}

Definition at line 143 of file playercontext.h.

Referenced by GetPlayingInfoMap(), GetState(), and TV::HandleStateChange().

◆ m_errored

bool PlayerContext::m_errored {false}

Definition at line 145 of file playercontext.h.

Referenced by TV::PlaybackLoop(), TV::SetErrored(), and TV::StartTV().

◆ m_prevChan

StringDeque PlayerContext::m_prevChan

◆ m_pseudoLiveTVRec

ProgramInfo* PlayerContext::m_pseudoLiveTVRec {nullptr}

Definition at line 151 of file playercontext.h.

Referenced by TV::HandlePseudoLiveTVTimerEvent(), and SetPseudoLiveTV().

◆ m_pseudoLiveTVState

PseudoState PlayerContext::m_pseudoLiveTVState {kPseudoNormalLiveTV}

◆ m_fftime

int PlayerContext::m_fftime {0}

◆ m_rewtime

int PlayerContext::m_rewtime {0}

◆ m_jumptime

int PlayerContext::m_jumptime {0}

◆ m_tsNormal

float PlayerContext::m_tsNormal {1.0F}

Time stretch speed, 1.0F for normal playback.

Begins at 1.0F meaning normal playback, but can be increased or decreased to speedup or slowdown playback. Ignored when doing Fast Forward or Rewind.

Definition at line 163 of file playercontext.h.

Referenced by TV::ChangeSpeed(), TV::ChangeTimeStretch(), CreatePlayer(), TV::DoPlay(), TV::DoTogglePauseStart(), GetPlayMessage(), HandlePlayerSpeedChangeEOF(), TV::Init(), TV::NormalSpeed(), TV::OSDDialogEvent(), TV::PlaybackMenuInit(), TV::ProcessNetworkControlCommand(), SetPlayGroup(), TV::StopFFRew(), TeardownPlayer(), TV::ToggleTimeStretch(), and TV::UnpauseLiveTV().

◆ m_tsAlt

float PlayerContext::m_tsAlt {1.5F}

Definition at line 164 of file playercontext.h.

Referenced by SetPlayGroup(), and TV::ToggleTimeStretch().

◆ m_playingInfoLock

QMutex PlayerContext::m_playingInfoLock {QMutex::Recursive}
mutable

Definition at line 166 of file playercontext.h.

Referenced by LockPlayingInfo(), SetPlayingInfo(), and UnlockPlayingInfo().

◆ m_deletePlayerLock

QMutex PlayerContext::m_deletePlayerLock {QMutex::Recursive}
mutable

◆ m_stateLock

QMutex PlayerContext::m_stateLock {QMutex::Recursive}
mutable

◆ m_lastSignalMsg

QStringList PlayerContext::m_lastSignalMsg
mutable

Definition at line 171 of file playercontext.h.

Referenced by TV::PauseLiveTV(), TV::timerEvent(), and TV::UpdateOSDSignal().

◆ m_lastSignalMsgTime

MythTimer PlayerContext::m_lastSignalMsgTime
mutable

Definition at line 172 of file playercontext.h.

Referenced by TV::ActiveHandleAction(), PlayerContext(), and TV::UpdateOSDSignal().

◆ m_lastSignalUIInfo

InfoMap PlayerContext::m_lastSignalUIInfo
mutable

◆ m_lastSignalUIInfoTime

MythTimer PlayerContext::m_lastSignalUIInfoTime
mutable

Definition at line 174 of file playercontext.h.

Referenced by TV::UpdateOSDSignal().

◆ m_nextState

MythDeque<TVState> PlayerContext::m_nextState

◆ kSMExitTimeout

const uint PlayerContext::kSMExitTimeout = 2000
static

Timeout after last Signal Monitor message for ignoring OSD when exiting.

Definition at line 180 of file playercontext.h.

Referenced by TV::ActiveHandleAction(), and PlayerContext().

◆ kMaxChannelHistory

const uint PlayerContext::kMaxChannelHistory = 30
static

Definition at line 181 of file playercontext.h.

Referenced by PushPreviousChannel().


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