MythTV  master
DetectLetterbox.h
Go to the documentation of this file.
1 // -*- Mode: c++ -*-
2 
3 #include "mythplayer.h"
4 
5 using namespace std;
6 
7 class MythPlayer;
8 
10 {
11 public:
12  explicit DetectLetterbox(MythPlayer* const player);
13  ~DetectLetterbox() = default;
14  void SetDetectLetterbox(bool detect);
15  bool GetDetectLetterbox() const;
16  void Detect(VideoFrame *frame);
17  void SwitchTo(VideoFrame *frame);
18 
19 private:
21  int m_firstFrameChecked {0};
22 
27  long long m_detectLetterboxSwitchFrame {-1};
28  long long m_detectLetterboxPossibleHalfFrame {-1};
29  long long m_detectLetterboxPossibleFullFrame {-1};
30  int m_detectLetterboxConsecutiveCounter {0};
31 
32  MythPlayer *m_player {nullptr};
33 
34  int m_detectLetterboxLimit {75};
36 };
37 
38 /* vim: set expandtab tabstop=4 shiftwidth=4: */
QMutex m_detectLetterboxLock
AdjustFillMode m_detectLetterboxDefaultMode
#define MTV_PUBLIC
Definition: mythtvexp.h:15
AdjustFillMode
Definition: videoouttypes.h:57
AdjustFillMode m_detectLetterboxDetectedMode
Which mode was last detected.