MythTV  master
tv_rec.h
Go to the documentation of this file.
1 #ifndef TVREC_H
2 #define TVREC_H
3 
4 // C++ headers
5 #include <utility>
6 #include <vector> // for vector
7 
8 // Qt headers
9 #include <QWaitCondition>
10 #include <QStringList>
11 #include <QDateTime>
12 #include <QRunnable>
13 #include <QString>
14 #include <QMap>
15 #include <QMutex> // for QMutex
16 #include <QReadWriteLock>
17 #include <QHash> // for QHash
18 
19 // MythTV headers
20 #include "mythtimer.h"
21 #include "mthread.h"
22 #include "inputinfo.h"
23 #include "mythdeque.h"
24 
25 #include "recordinginfo.h"
26 #include "tv.h"
27 #include "signalmonitorlistener.h"
28 #include "mythtvexp.h" // for MTV_PUBLIC
29 #include "programtypes.h" // for RecStatus, RecStatus::Type, etc
30 #include "videoouttypes.h" // for PictureAttribute
31 
32 #include "mythconfig.h"
33 
34 // locking order
35 // setChannelLock -> stateChangeLock -> triggerEventLoopLock
36 // -> pendingRecLock
37 
38 class MythMediaBuffer;
39 class EITScanner;
40 class RecordingProfile;
41 class LiveTVChain;
42 
43 class RecorderBase;
44 class DTVRecorder;
45 class DVBRecorder;
46 class HDHRRecorder;
47 class ASIRecorder;
48 class CetonRecorder;
49 
50 class SignalMonitor;
51 class DTVSignalMonitor;
52 
53 class ChannelBase;
54 class DTVChannel;
55 class DVBChannel;
56 class FirewireChannel;
57 class V4LChannel;
58 class HDHRChannel;
59 class CetonChannel;
60 
61 class MPEGStreamData;
62 class ProgramMapTable;
63 class RecordingQuality;
64 
66 {
67  public:
68  GeneralDBOptions()= default;
69 
70  QString m_videoDev;
71  QString m_vbiDev;
72  QString m_audioDev;
73  QString m_inputType {"V4L"};
75  bool m_skipBtAudio {false};
78  bool m_waitForSeqstart {false};
79 };
80 
82 {
83  public:
84  DVBDBOptions() = default;
85 
86  bool m_dvbOnDemand {false};
87  std::chrono::milliseconds m_dvbTuningDelay {0ms};
88  bool m_dvbEitScan {true};
89 };
90 
92 {
93  public:
94  FireWireDBOptions() = default;
95 
96  int m_speed {-1};
97  int m_connection {-1};
98  QString m_model;
99 };
100 
102 {
103  public:
104  explicit TuningRequest(uint f) :
105  m_flags(f) {;}
107  m_flags(f), m_program(p) {;}
108  TuningRequest(uint f, QString ch, QString in = QString()) :
109  m_flags(f), m_channel(std::move(ch)), m_input(std::move(in)) {;}
110 
111  QString toString(void) const;
112 
113  bool IsOnSameMultiplex(void) const { return m_minorChan || (m_progNum >= 0); }
114 
115  public:
118  QString m_channel;
119  QString m_input;
122  int m_progNum {-1};
123 };
125 inline TuningRequest myth_deque_init(const TuningRequest */*request*/) { return (TuningRequest)(0); }
126 
128 {
129  public:
130  PendingInfo() = default;
131 
132  ProgramInfo *m_info {nullptr};
133  QDateTime m_recordingStart;
134  bool m_hasLaterShowing {false};
135  bool m_canceled {false};
136  bool m_ask {false};
137  bool m_doNotAsk {false};
138  std::vector<uint> m_possibleConflicts;
139 };
140 using PendingMap = QMap<uint,PendingInfo>;
141 
142 class MTV_PUBLIC TVRec : public SignalMonitorListener, public QRunnable
143 {
144  Q_DECLARE_TR_FUNCTIONS(TVRec)
145 
146  friend class TuningRequest;
147  friend class TVRecRecordThread;
148 
149  public:
150  explicit TVRec(int _inputid);
151  ~TVRec(void) override;
152 
153  bool Init(void);
154 
155  void RecordPending(const ProgramInfo *rcinfo, std::chrono::seconds secsleft, bool hasLater);
156  RecStatus::Type StartRecording(ProgramInfo *pginfo);
157  RecStatus::Type GetRecordingStatus(void) const;
158 
159  void StopRecording(bool killFile = false);
161  void FinishRecording(void) { SetFlags(kFlagFinishRecording,
162  __FILE__, __LINE__); }
164  void FrontendReady(void) { SetFlags(kFlagFrontendReady,
165  __FILE__, __LINE__); }
166  void CancelNextRecording(bool cancel);
167  ProgramInfo *GetRecording(void);
168 
170  bool IsRunning(void) const { return HasFlags(kFlagRunMainLoop); }
172  void Stop(void) { ClearFlags(kFlagRunMainLoop, __FILE__, __LINE__); }
173 
174  TVState GetState(void) const;
176  bool IsPlaying(void) { return StateIsPlaying(m_internalState); }
179  bool IsRecording(void) { return StateIsRecording(m_internalState); }
180 
181  bool SetVideoFiltersForChannel(uint sourceid, const QString &channum);
182 
183  bool IsBusy(InputInfo *busy_input = nullptr, std::chrono::seconds time_buffer = 5s) const;
184  bool IsReallyRecording(void);
185 
186  float GetFramerate(void);
187  long long GetFramesWritten(void);
188  long long GetFilePosition(void);
189  long long GetMaxBitrate(void) const;
190  int64_t GetKeyframePosition(uint64_t desired) const;
191  bool GetKeyframePositions(int64_t start, int64_t end, frm_pos_map_t &map) const;
192  bool GetKeyframeDurations(int64_t start, int64_t end, frm_pos_map_t &map) const;
193  void SpawnLiveTV(LiveTVChain *newchain, bool pip, QString startchan);
194  QString GetChainID(void);
195  void StopLiveTV(void);
196  void PauseRecorder(void);
197  void ToggleChannelFavorite(const QString &changroupname);
198 
199  void SetLiveRecording(int recording);
200 
201  QString GetInput(void) const;
202  uint GetSourceID(void) const;
203  QString SetInput(QString input);
204 
207  { SetChannel(QString("NextChannel %1").arg((int)dir)); }
208  void SetChannel(const QString& name, uint requestType = kFlagDetect);
209  bool QueueEITChannelChange(const QString &name);
210 
211  std::chrono::milliseconds SetSignalMonitoringRate(std::chrono::milliseconds rate, int notifyFrontend = 1);
212  int GetPictureAttribute(PictureAttribute attr);
213  int ChangePictureAttribute(PictureAdjustType type, PictureAttribute attr,
214  bool direction);
215  bool CheckChannel(const QString& name) const;
216  bool ShouldSwitchToAnotherInput(const QString& chanid) const;
217  bool CheckChannelPrefix(const QString &prefix, uint &complete_valid_channel_on_rec,
218  bool &is_extra_char_useful, QString &needed_spacer) const;
219  void GetNextProgram(BrowseDirection direction,
220  QString &title, QString &subtitle,
221  QString &desc, QString &category,
222  QString &starttime, QString &endtime,
223  QString &callsign, QString &iconpath,
224  QString &channum, uint &chanid,
225  QString &seriesid, QString &programid);
226  bool GetChannelInfo(uint &chanid, uint &sourceid,
227  QString &callsign, QString &channum,
228  QString &channame, QString &xmltvid) const;
229  bool SetChannelInfo(uint chanid, uint sourceid, const QString& oldchannum,
230  const QString& callsign, const QString& channum,
231  const QString& channame, const QString& xmltvid);
232 
234  uint GetInputId(void) const { return m_inputId; }
235  uint GetParentId(void) const { return m_parentId; }
236  uint GetMajorId(void) { return m_parentId ? m_parentId : m_inputId; }
238  bool IsErrored(void) const { return HasFlags(kFlagErrored); }
239 
240  void RingBufferChanged(MythMediaBuffer *Buffer, RecordingInfo *pginfo, RecordingQuality *recq);
241  void RecorderPaused(void);
242 
243  void SetNextLiveTVDir(QString dir);
244 
245  uint GetFlags(void) const { return m_stateFlags; }
246 
247  static TVRec *GetTVRec(uint inputid);
248 
249  void AllGood(void) override { WakeEventLoop(); } // SignalMonitorListener
250  void StatusChannelTuned(const SignalMonitorValue &/*val*/) override { } // SignalMonitorListener
251  void StatusSignalLock(const SignalMonitorValue &/*val*/) override { } // SignalMonitorListener
252  void StatusSignalStrength(const SignalMonitorValue &/*val*/) override { } // SignalMonitorListener
253 
254  protected:
255  void run(void) override; // QRunnable
256  bool WaitForEventThreadSleep(bool wake = true,
257  std::chrono::milliseconds time = std::chrono::milliseconds::max());
258 
259  private:
260  void SetRingBuffer(MythMediaBuffer* Buffer);
261  void SetPseudoLiveTVRecording(RecordingInfo *pi);
262  void TeardownAll(void);
263  void WakeEventLoop(void);
264 
265  static bool GetDevices(uint inputid,
266  uint &parentid,
267  GeneralDBOptions &gen_opts,
268  DVBDBOptions &dvb_opts,
269  FireWireDBOptions &firewire_opts);
270 
271  static QString GetStartChannel(uint inputid);
272 
273  void TeardownRecorder(uint request_flags);
274  DTVRecorder *GetDTVRecorder(void);
275 
276  bool CreateChannel(const QString &startchannel,
277  bool enter_power_save_mode);
278  void CloseChannel(void);
279  DTVChannel *GetDTVChannel(void);
280  V4LChannel *GetV4LChannel(void);
281 
282  bool SetupSignalMonitor(
283  bool tablemon, bool EITscan, bool notify);
284  bool SetupDTVSignalMonitor(bool EITscan);
285  void TeardownSignalMonitor(void);
286  DTVSignalMonitor *GetDTVSignalMonitor(void);
287 
288  bool HasFlags(uint f) const { return (m_stateFlags & f) == f; }
289  void SetFlags(uint f, const QString & file, int line);
290  void ClearFlags(uint f, const QString & file, int line);
291  static QString FlagToString(uint f);
292 
293  void HandleTuning(void);
294  void TuningShutdowns(const TuningRequest &request);
295  void TuningFrequency(const TuningRequest &request);
296  MPEGStreamData *TuningSignalCheck(void);
297 
298  void TuningNewRecorder(MPEGStreamData *streamData);
299  void TuningRestartRecorder(void);
300  QString TuningGetChanNum(const TuningRequest &request, QString &input) const;
301  bool TuningOnSameMultiplex(TuningRequest &request);
302 
303  void HandleStateChange(void);
304  void ChangeState(TVState nextState);
305  static bool StateIsRecording(TVState state);
306  static bool StateIsPlaying(TVState state);
307  TVState RemovePlaying(TVState state) const;
308  TVState RemoveRecording(TVState state) const;
309 
310  void HandlePendingRecordings(void);
311 
312  bool WaitForNextLiveTVDir(void);
313  bool GetProgramRingBufferForLiveTV(RecordingInfo **pginfo, MythMediaBuffer **Buffer,
314  const QString &channum);
315  bool CreateLiveTVRingBuffer(const QString & channum);
316  bool SwitchLiveTVRingBuffer(const QString & channum,
317  bool discont, bool set_rec);
318 
319  RecordingInfo *SwitchRecordingRingBuffer(const RecordingInfo &rcinfo);
320 
321  void StartedRecording(RecordingInfo *curRec);
322  void FinishedRecording(RecordingInfo *curRec, RecordingQuality *recq);
323  QDateTime GetRecordEndTime(const ProgramInfo *pi) const;
324  void CheckForRecGroupChange(void);
325  void NotifySchedulerOfRecording(RecordingInfo *rec);
326  enum AutoRunInitType { kAutoRunProfile, kAutoRunNone, };
327  void InitAutoRunJobs(RecordingInfo *rec, AutoRunInitType t,
328  RecordingProfile *recpro, int line);
329 
330  void SetRecordingStatus(
331  RecStatus::Type new_status, int line, bool have_lock = false);
332 
333  QString LoadProfile(void *tvchain, RecordingInfo *rec,
334  RecordingProfile &profile) const;
335 
336  // Various components TVRec coordinates
337  RecorderBase *m_recorder {nullptr};
338  ChannelBase *m_channel {nullptr};
339  SignalMonitor *m_signalMonitor {nullptr};
340  EITScanner *m_scanner {nullptr};
341 
343  bool m_signalEventCmdSent {false};
344 
347  uint m_signalMonitorCheckCnt {0};
348  bool m_reachedRecordingDeadline {false};
349  QDateTime m_preFailDeadline;
350  bool m_reachedPreFail {false};
351 
352  // Various threads
354  MThread *m_eventThread {nullptr};
356  MThread *m_recorderThread {nullptr};
357 
358  // Configuration variables from database
359  bool m_transcodeFirst {false};
360  bool m_earlyCommFlag {false};
361  bool m_runJobOnHostOnly {false};
362  std::chrono::seconds m_eitCrawlIdleStart {1min};
363  std::chrono::seconds m_eitTransportTimeout {5min};
364  int m_audioSampleRateDB {0};
365  std::chrono::seconds m_overRecordSecNrml {0s};
366  std::chrono::seconds m_overRecordSecCat {0s};
368 
369  // Configuration variables from setup routines
371  uint m_parentId {0};
372  bool m_isPip {false};
373 
374  // Configuration variables from database, based on inputid
378 
380 
381  // State variables
382  mutable QMutex m_setChannelLock;
383  mutable QMutex m_stateChangeLock {QMutex::Recursive};
384  mutable QMutex m_pendingRecLock {QMutex::Recursive};
385  TVState m_internalState {kState_None};
386  TVState m_desiredNextState {kState_None};
387  bool m_changeState {false};
388  bool m_pauseNotify {true};
389  uint m_stateFlags {0};
391  TuningRequest m_lastTuningRequest {0};
393  mutable QMutex m_triggerEventLoopLock {QMutex::NonRecursive};
394  QWaitCondition m_triggerEventLoopWait;
395  bool m_triggerEventLoopSignal {false};
396  mutable QMutex m_triggerEventSleepLock {QMutex::NonRecursive};
397  QWaitCondition m_triggerEventSleepWait;
398  bool m_triggerEventSleepSignal {false};
399  volatile bool m_switchingBuffer {false};
401 
402  // Current recording info
403  RecordingInfo *m_curRecording {nullptr};
404  QDateTime m_recordEndTime;
405  // RecordingInfo::MakeUniqueKey()->autoRun
406  QHash<QString,int> m_autoRunJobs;
407  int m_overrecordseconds {0};
408 
409  // Pending recording info
411 
412  // Pseudo LiveTV recording
413  RecordingInfo *m_pseudoLiveTVRecording {nullptr};
416  QWaitCondition m_triggerLiveTVDir;
418 
419  // LiveTV file chain
420  LiveTVChain *m_tvChain {nullptr};
421 
422  // RingBuffer info
423  MythMediaBuffer *m_buffer {nullptr};
424  QString m_rbFileExt {"ts"};
425 
426  public:
427  static QReadWriteLock s_inputsLock;
428  static QMap<uint,TVRec*> s_inputs;
429 
430  public:
432  static constexpr std::chrono::milliseconds kSignalMonitoringRate { 50ms };
433 
434  // General State flags
435  static const uint kFlagFrontendReady = 0x00000001;
436  static const uint kFlagRunMainLoop = 0x00000002;
437  static const uint kFlagExitPlayer = 0x00000004;
438  static const uint kFlagFinishRecording = 0x00000008;
439  static const uint kFlagErrored = 0x00000010;
440  static const uint kFlagCancelNextRecording = 0x00000020;
441 
442  // Tuning flags
444  static const uint kFlagLiveTV = 0x00000100;
446  static const uint kFlagRecording = 0x00000200;
448  static const uint kFlagAntennaAdjust = 0x00000400;
449  static const uint kFlagRec = 0x00000F00;
450 
451  // Non-recording Commands
453  static const uint kFlagEITScan = 0x00001000;
455  static const uint kFlagCloseRec = 0x00002000;
457  static const uint kFlagKillRec = 0x00004000;
458 
459  static const uint kFlagNoRec = 0x0000F000;
460  static const uint kFlagKillRingBuffer = 0x00010000;
461 
462  // Waiting stuff
463  static const uint kFlagWaitingForRecPause = 0x00100000;
464  static const uint kFlagWaitingForSignal = 0x00200000;
465  static const uint kFlagNeedToStartRecorder = 0x00800000;
466  static const uint kFlagPendingActions = 0x00F00000;
467 
468  // Running stuff
469  static const uint kFlagSignalMonitorRunning = 0x01000000;
470  static const uint kFlagEITScannerRunning = 0x04000000;
471 
472  static const uint kFlagDummyRecorderRunning = 0x10000000;
473  static const uint kFlagRecorderRunning = 0x20000000;
474  static const uint kFlagAnyRecRunning = 0x30000000;
475  static const uint kFlagAnyRunning = 0x3F000000;
476 
477  // Tuning state
478  static const uint kFlagRingBufferReady = 0x40000000;
479  static const uint kFlagDetect = 0x80000000;
480 };
481 
482 #endif
GeneralDBOptions
Definition: tv_rec.h:65
RecStatus::Type
Type
Definition: recStatus.h:16
PendingInfo::m_possibleConflicts
std::vector< uint > m_possibleConflicts
Definition: tv_rec.h:138
tv.h
TVRec::m_startRecordingDeadline
QDateTime m_startRecordingDeadline
Definition: tv_rec.h:345
TuningRequest
Definition: tv_rec.h:101
PendingInfo::PendingInfo
PendingInfo()=default
TVRec::GetMajorId
uint GetMajorId(void)
Definition: tv_rec.h:236
TVRec::m_recProfileName
QString m_recProfileName
Definition: tv_rec.h:379
ChannelChangeDirection
ChannelChangeDirection
ChannelChangeDirection is an enumeration of possible channel changing directions.
Definition: tv.h:28
false
VERBOSE_PREAMBLE false
Definition: verbosedefs.h:85
TVRec::m_tuningRequests
TuningQueue m_tuningRequests
Definition: tv_rec.h:390
PictureAdjustType
PictureAdjustType
Definition: tv.h:120
title
QString title
Definition: mythplugins/mytharchive/mytharchivehelper/main.cpp:636
PendingMap
QMap< uint, PendingInfo > PendingMap
Definition: tv_rec.h:140
RecordingInfo
Holds information on a TV Program one might wish to record.
Definition: recordinginfo.h:34
GeneralDBOptions::m_signalTimeout
uint m_signalTimeout
Definition: tv_rec.h:76
mythtvexp.h
TVRec::m_triggerLiveTVDir
QWaitCondition m_triggerLiveTVDir
Definition: tv_rec.h:416
ProgramMapTable
A PMT table maps a program described in the ProgramAssociationTable to various PID's which describe t...
Definition: mpegtables.h:692
GeneralDBOptions::m_inputType
QString m_inputType
Definition: tv_rec.h:73
arg
arg(title).arg(filename).arg(doDelete))
TVRec::m_overRecordCategory
QString m_overRecordCategory
Definition: tv_rec.h:367
PendingInfo::m_hasLaterShowing
bool m_hasLaterShowing
Definition: tv_rec.h:134
TVRec::ChangeChannel
void ChangeChannel(ChannelChangeDirection dir)
Changes to a channel in the 'dir' channel change direction.
Definition: tv_rec.h:206
PendingInfo::m_info
ProgramInfo * m_info
Definition: tv_rec.h:132
RecStatus::Unknown
@ Unknown
Definition: recStatus.h:32
TuningRequest::toString
QString toString(void) const
Definition: tv_rec.cpp:4836
TVRec::FrontendReady
void FrontendReady(void)
Tells TVRec that the frontend's TV class is ready for messages.
Definition: tv_rec.h:164
category
QString category
Definition: mythplugins/mytharchive/mytharchivehelper/main.cpp:1422
MythMediaBuffer
Definition: mythmediabuffer.h:50
FireWireDBOptions::m_speed
int m_speed
Definition: tv_rec.h:96
CetonChannel
Definition: cetonchannel.h:22
TVRec::m_setChannelLock
QMutex m_setChannelLock
Definition: tv_rec.h:382
build_compdb.file
file
Definition: build_compdb.py:55
TVRec::GetParentId
uint GetParentId(void) const
Definition: tv_rec.h:235
mythdeque.h
hardwareprofile.distros.mythtv_data.data_mythtv.prefix
string prefix
Definition: data_mythtv.py:40
SignalMonitorListener
Definition: signalmonitorlistener.h:21
myth_deque_init
TuningRequest myth_deque_init(const TuningRequest *)
Definition: tv_rec.h:125
TVRec::StatusChannelTuned
void StatusChannelTuned(const SignalMonitorValue &) override
Signal to be sent with change change status.
Definition: tv_rec.h:250
TVRec::AllGood
void AllGood(void) override
Signal to be sent when you have a lock on all values.
Definition: tv_rec.h:249
HDHRChannel
Definition: hdhrchannel.h:20
programtypes.h
TVRec::m_recordEndTime
QDateTime m_recordEndTime
Definition: tv_rec.h:404
ASIRecorder
This is a specialization of DTVRecorder used to handle streams from ASI drivers.
Definition: asirecorder.h:55
TVRec::Stop
void Stop(void)
Tells TVRec to stop event loop.
Definition: tv_rec.h:172
kState_None
@ kState_None
None State, this is the initial state in both TV and TVRec, it indicates that we are ready to change ...
Definition: tv.h:58
GeneralDBOptions::m_channelTimeout
uint m_channelTimeout
Definition: tv_rec.h:77
TVRec::m_inputId
uint m_inputId
Definition: tv_rec.h:370
GeneralDBOptions::m_vbiDev
QString m_vbiDev
Definition: tv_rec.h:71
TVRec::m_pendingRecordings
PendingMap m_pendingRecordings
Definition: tv_rec.h:410
TVRec::GetInputId
uint GetInputId(void) const
Returns the inputid.
Definition: tv_rec.h:234
CetonRecorder
Definition: cetonrecorder.h:20
TVRec::m_autoRunJobs
QHash< QString, int > m_autoRunJobs
Definition: tv_rec.h:406
signalmonitorlistener.h
ChannelBase
Abstract class providing a generic interface to tuning hardware.
Definition: channelbase.h:31
hardwareprofile.scan.profile
profile
Definition: scan.py:99
videoouttypes.h
TuningRequest::m_progNum
int m_progNum
Definition: tv_rec.h:122
hardwareprofile.config.p
p
Definition: config.py:33
hardwareprofile.i18n.t
t
Definition: i18n.py:36
FirewireChannel
FirewireChannel Copyright (c) 2005 by Jim Westfall and Dave Abrahams Distributed as part of MythTV un...
Definition: firewirechannel.h:14
DVBDBOptions::m_dvbOnDemand
bool m_dvbOnDemand
Definition: tv_rec.h:86
MPEGStreamData
Encapsulates data about MPEG stream and emits events for each table.
Definition: mpegstreamdata.h:84
TVRec::m_nextLiveTVDir
QString m_nextLiveTVDir
Definition: tv_rec.h:414
TVRec::m_triggerEventSleepWait
QWaitCondition m_triggerEventSleepWait
Definition: tv_rec.h:397
TVRec::StatusSignalLock
void StatusSignalLock(const SignalMonitorValue &) override
Signal to be sent as true when it is safe to begin or continue recording, and false if it may not be ...
Definition: tv_rec.h:251
GeneralDBOptions::GeneralDBOptions
GeneralDBOptions()=default
SignalMonitorValue
Definition: signalmonitorvalue.h:13
TVRec::m_liveTVStartChannel
QString m_liveTVStartChannel
Definition: tv_rec.h:417
GetState
#define GetState(a, b)
Definition: audiooutputopensles.cpp:48
f
QTextStream t & f
Definition: mythplugins/mytharchive/mytharchivehelper/main.cpp:603
TVRec::m_eitScanStartTime
QDateTime m_eitScanStartTime
Definition: tv_rec.h:392
TVRec::s_inputsLock
static QReadWriteLock s_inputsLock
Definition: tv_rec.h:427
RecordingQuality
Definition: recordingquality.h:34
DTVRecorder
This is a specialization of RecorderBase used to handle MPEG-2, MPEG-4, MPEG-4 AVC,...
Definition: dtvrecorder.h:25
uint
unsigned int uint
Definition: compat.h:140
FireWireDBOptions::FireWireDBOptions
FireWireDBOptions()=default
TuningRequest::m_minorChan
uint m_minorChan
Definition: tv_rec.h:121
TVRec::m_triggerEventLoopWait
QWaitCondition m_triggerEventLoopWait
Definition: tv_rec.h:394
TVRec::IsErrored
bool IsErrored(void) const
Returns true is "errored" is true, false otherwise.
Definition: tv_rec.h:238
SignalMonitor
Signal monitoring base class.
Definition: signalmonitor.h:31
DVBRecorder
This is a specialization of DTVRecorder used to handle streams from DVB drivers.
Definition: dvbrecorder.h:21
TVRec::IsRunning
bool IsRunning(void) const
Returns true if event loop has not been told to shut down.
Definition: tv_rec.h:170
GeneralDBOptions::m_skipBtAudio
bool m_skipBtAudio
Definition: tv_rec.h:75
frm_pos_map_t
QMap< long long, long long > frm_pos_map_t
Frame # -> File offset map.
Definition: programtypes.h:46
TuningRequest::TuningRequest
TuningRequest(uint f, QString ch, QString in=QString())
Definition: tv_rec.h:108
PictureAttribute
PictureAttribute
Definition: videoouttypes.h:103
MTV_PUBLIC
#define MTV_PUBLIC
Definition: mythtvexp.h:15
TuningRequest::m_majorChan
uint m_majorChan
Definition: tv_rec.h:120
GeneralDBOptions::m_audioSampleRate
int m_audioSampleRate
Definition: tv_rec.h:74
recordinginfo.h
DVBChannel
Provides interface to the tuning hardware when using DVB drivers.
Definition: dvbchannel.h:30
TuningRequest::m_flags
uint m_flags
Definition: tv_rec.h:116
TVRec::m_nextLiveTVDirLock
QMutex m_nextLiveTVDirLock
Definition: tv_rec.h:415
TVRec::m_signalEventCmdTimeout
QDateTime m_signalEventCmdTimeout
Definition: tv_rec.h:342
Buffer
Definition: MythExternControl.h:36
ProgramInfo
Holds information on recordings and videos.
Definition: programinfo.h:67
DVBDBOptions::m_dvbEitScan
bool m_dvbEitScan
Definition: tv_rec.h:88
TVState
TVState
TVState is an enumeration of the states used by TV and TVRec.
Definition: tv.h:50
TVRec::m_genOpt
GeneralDBOptions m_genOpt
Definition: tv_rec.h:375
dir
QDir dir
Definition: mythplugins/mytharchive/mytharchivehelper/main.cpp:1174
MythDeque< TuningRequest >
TVRec::m_dvbOpt
DVBDBOptions m_dvbOpt
Definition: tv_rec.h:376
std
Definition: mythchrono.h:23
RecorderBase
This is the abstract base class for supporting recorder hardware.
Definition: recorderbase.h:73
DVBDBOptions
Definition: tv_rec.h:81
GeneralDBOptions::m_videoDev
QString m_videoDev
Definition: tv_rec.h:70
FireWireDBOptions::m_connection
int m_connection
Definition: tv_rec.h:97
TVRec::StatusSignalStrength
void StatusSignalStrength(const SignalMonitorValue &) override
Signal to be sent with an actual signal value.
Definition: tv_rec.h:252
TVRec
This is the coordinating class of the Recorder Subsystem.
Definition: tv_rec.h:142
FireWireDBOptions
Definition: tv_rec.h:91
TVRec::kAutoRunProfile
@ kAutoRunProfile
Definition: tv_rec.h:326
TuningRequest::IsOnSameMultiplex
bool IsOnSameMultiplex(void) const
Definition: tv_rec.h:113
GeneralDBOptions::m_audioDev
QString m_audioDev
Definition: tv_rec.h:72
MThread
This is a wrapper around QThread that does several additional things.
Definition: mthread.h:49
TVRec::m_signalMonitorDeadline
QDateTime m_signalMonitorDeadline
Definition: tv_rec.h:346
DVBDBOptions::m_dvbTuningDelay
std::chrono::milliseconds m_dvbTuningDelay
Definition: tv_rec.h:87
mthread.h
PendingInfo::m_doNotAsk
bool m_doNotAsk
Definition: tv_rec.h:137
DTVSignalMonitor
This class is intended to detect the presence of needed tables.
Definition: dtvsignalmonitor.h:14
inputinfo.h
RecStatus
Definition: recStatus.h:11
DVBDBOptions::DVBDBOptions
DVBDBOptions()=default
InputInfo
Definition: inputinfo.h:14
TuningRequest::TuningRequest
TuningRequest(uint f, RecordingInfo *p)
Definition: tv_rec.h:106
HDHRRecorder
Definition: hdhrrecorder.h:19
mythtimer.h
BrowseDirection
BrowseDirection
Used to request ProgramInfo for channel browsing.
Definition: tv.h:37
PendingInfo::m_ask
bool m_ask
Definition: tv_rec.h:136
TVRec::GetFlags
uint GetFlags(void) const
Definition: tv_rec.h:245
PendingInfo::m_canceled
bool m_canceled
Definition: tv_rec.h:135
DTVChannel
Class providing a generic interface to digital tuning hardware.
Definition: dtvchannel.h:33
TVRec::IsPlaying
bool IsPlaying(void)
Returns "state == kState_RecordingPreRecorded".
Definition: tv_rec.h:176
TuningRequest::TuningRequest
TuningRequest(uint f)
Definition: tv_rec.h:104
RecordingProfile
Definition: recordingprofile.h:39
PendingInfo::m_recordingStart
QDateTime m_recordingStart
Definition: tv_rec.h:133
TuningRequest::m_channel
QString m_channel
Definition: tv_rec.h:118
TVRec::m_fwOpt
FireWireDBOptions m_fwOpt
Definition: tv_rec.h:377
TVRec::HasFlags
bool HasFlags(uint f) const
Definition: tv_rec.h:288
V4LChannel
Implements tuning for TV cards using the V4L driver API, both versions 1 and 2.
Definition: v4lchannel.h:30
TuningRequest::m_input
QString m_input
Definition: tv_rec.h:119
GeneralDBOptions::m_waitForSeqstart
bool m_waitForSeqstart
Definition: tv_rec.h:78
TuningRequest::m_program
RecordingInfo * m_program
Definition: tv_rec.h:117
TVRec::AutoRunInitType
AutoRunInitType
Definition: tv_rec.h:326
EITScanner
Acts as glue between ChannelBase, EITSource and EITHelper.
Definition: eitscanner.h:33
PendingInfo
Definition: tv_rec.h:127
TVRec::s_inputs
static QMap< uint, TVRec * > s_inputs
Definition: tv_rec.h:428
FireWireDBOptions::m_model
QString m_model
Definition: tv_rec.h:98
LiveTVChain
Keeps track of recordings in a current LiveTV instance.
Definition: livetvchain.h:31
TVRec::IsRecording
bool IsRecording(void)
Returns "state == kState_RecordingRecordedOnly".
Definition: tv_rec.h:179
TVRec::m_preFailDeadline
QDateTime m_preFailDeadline
Definition: tv_rec.h:349