MythTV  master
mythplayerstate.cpp
Go to the documentation of this file.
1 // MythTV
2 #include "audioplayer.h"
3 #include "osd.h"
4 #include "mythplayerstate.h"
5 
9 MythOverlayState::MythOverlayState(bool Browsing, bool Editing)
10  : m_browsing(Browsing),
11  m_editing(Editing)
12 {
13 }
14 
19 MythAudioState::MythAudioState(AudioPlayer* Player, std::chrono::milliseconds Offset)
20  : m_hasAudioOut(Player->HasAudioOut()),
21  m_volumeControl(Player->ControlsVolume()),
22  m_volume(Player->GetVolume()),
23  m_muteState(Player->GetMuteState()),
24  m_canUpmix(Player->CanUpmix()),
25  m_isUpmixing(Player->IsUpmixing()),
26  m_paused(Player->IsPaused()),
27  m_audioOffset(Offset)
28 {
29 }
30 
31 MythNavigationState::MythNavigationState(int CurrentChapter, std::vector<int64_t> ChapterTimes,
32  int CurrentTitle, std::vector<int64_t> TitleDurations, std::vector<QString> TitleNames,
33  int CurrentAngle, std::vector<QString> AngleNames)
34  : m_currentChapter(CurrentChapter),
35  m_chapterTimes(std::move(ChapterTimes)),
36  m_currentTitle(CurrentTitle),
37  m_titleDurations(std::move(TitleDurations)),
38  m_titleNames(std::move(TitleNames)),
39  m_currentAngle(CurrentAngle),
40  m_angleNames(std::move(AngleNames))
41 {
42 }
43 
45  float HorizScale, float VertScale, QPoint Move,
46  StereoscopicMode StereoOverride)
47  : m_adjustFillMode(AdjustFill),
48  m_aspectOverrideMode(AspectOverride),
49  m_manualHorizScale(HorizScale),
50  m_manualVertScale(VertScale),
51  m_manualMove(Move),
52  m_stereoOverride(StereoOverride)
53 {
54 }
55 
57  std::map<PictureAttribute, int> AttributeValues)
58  : m_supportedAttributes(Supported),
59  m_attributeValues(std::move(AttributeValues))
60 {
61 }
62 
64 {
65  if (auto attr = m_attributeValues.find(Attribute); attr != m_attributeValues.end())
66  return attr->second;
67  return -1;
68 }
69 
70 MythVisualiserState::MythVisualiserState(bool Embedding, bool Visualising,
71  QString Name, QStringList Visualisers)
72  : m_embedding(Embedding),
73  m_visualising(Visualising),
74  m_visualiserName(std::move(Name)),
75  m_visualiserList(std::move(Visualisers))
76 {
77 }
78 
79 MythEditorState::MythEditorState(uint64_t Current, uint64_t Previous, uint64_t Next, uint64_t Total,
80  bool InDelete, bool IsTemp, bool HasTemp,
81  bool HasUndo, QString Undo, bool HasRedo, QString Redo,
82  bool Saved)
83  : m_currentFrame(Current),
84  m_previousCut(Previous),
85  m_nextCut(Next),
86  m_totalFrames(Total),
87  m_frameInDelete(InDelete),
88  m_isTempMark(IsTemp),
89  m_hasTempMark(HasTemp),
90  m_hasUndo(HasUndo),
91  m_undoMessage(std::move(Undo)),
92  m_hasRedo(HasRedo),
93  m_redoMessage(std::move(Redo)),
94  m_saved(Saved)
95 {
96 }
mythplayerstate.h
PictureAttribute
PictureAttribute
Definition: videoouttypes.h:103
MythVideoColourState::m_attributeValues
std::map< PictureAttribute, int > m_attributeValues
Definition: mythplayerstate.h:123
AudioPlayer
Definition: audioplayer.h:22
MythVideoBoundsState::MythVideoBoundsState
MythVideoBoundsState()=default
AdjustFillMode
AdjustFillMode
Definition: videoouttypes.h:71
AdjustFill
static HostComboBoxSetting * AdjustFill()
Definition: globalsettings.cpp:2258
osd.h
PictureAttributeSupported
PictureAttributeSupported
Definition: videoouttypes.h:116
MythVideoColourState::MythVideoColourState
MythVideoColourState()=default
AspectOverrideMode
AspectOverrideMode
Definition: videoouttypes.h:60
MythVideoColourState::GetValue
int GetValue(PictureAttribute Attribute)
Definition: mythplayerstate.cpp:63
MythVisualiserState::MythVisualiserState
MythVisualiserState()=default
MythAudioState::MythAudioState
MythAudioState()=default
MythOverlayState::MythOverlayState
MythOverlayState()=default
MythNavigationState::MythNavigationState
MythNavigationState()=default
AspectOverride
static HostComboBoxSetting * AspectOverride()
Definition: globalsettings.cpp:2243
Name
Definition: channelsettings.cpp:71
audioplayer.h
Player
Definition: zmliveplayer.h:34
StereoscopicMode
StereoscopicMode
Definition: videoouttypes.h:134
MythEditorState::MythEditorState
MythEditorState()=default