26 #include "sharedframe.h" 40 class TransportControllable;
42 class QPropertyAnimation;
45 class Player :
public QWidget
54 explicit Player(QWidget *parent = 0);
55 void connectTransport(
const TransportControllable*);
58 void setMarkers(
const QList<int>&);
59 QSize videoSize()
const;
60 int position()
const {
63 void moveVideoToScreen(
int screen = -1);
64 void setPauseAfterOpen(
bool pause);
65 TabIndex tabIndex()
const;
69 void showStatusMessage(QString);
72 void played(
double speed);
75 void seeked(
int position);
78 void previousSought(
int currentPosition);
79 void previousSought();
80 void nextSought(
int currentPosition);
82 void zoomChanged(
float zoom);
83 void scrolledHorizontally(
int x);
84 void scrolledVertically(
int y);
85 void tabIndexChanged(
int index);
88 void play(
double speed = 1.0);
91 void togglePlayPaused();
92 void seek(
int position);
94 void onProducerOpened(
bool play =
true);
95 void postProducerOpened();
96 void onMeltedUnitOpened();
97 void onDurationChanged();
98 void onShowFrame(
int position,
double fps,
int in,
int out,
int length,
bool isPlaying);
100 void onVolumeChanged(
int);
101 void onCaptureStateChanged(
bool);
106 void switchToTab(TabIndex index);
107 void enableTab(TabIndex index,
bool enabled =
true);
108 void onTabBarClicked(
int index);
109 void setStatusLabel(
const QString& text,
int timeoutSeconds, QAction* action);
112 void resizeEvent(QResizeEvent* event);
115 void setupActions(QWidget* widget);
116 void retranslateUi(QWidget* widget);
117 void adjustScrollBars(
float horizontal,
float vertical);
118 double setVolume(
int volume);
121 QAction *actionPause;
122 QAction *actionSkipNext;
123 QAction *actionSkipPrevious;
124 QAction *actionRewind;
125 QAction *actionFastForward;
126 QAction *actionVolume;
128 ScrubBar* m_scrubber;
129 TimeSpinBox* m_positionSpinner;
130 QLabel* m_durationLabel;
131 QLabel* m_inPointLabel;
132 QLabel* m_selectedLabel;
137 QFrame* m_volumePopup;
138 QSlider* m_volumeSlider;
139 QWidget* m_volumeWidget;
140 QPushButton* m_muteButton;
143 double m_savedVolume;
146 int m_isMeltedPlaying;
147 QScrollBar* m_horizontalScroll;
148 QScrollBar* m_verticalScroll;
149 QToolButton* m_zoomButton;
150 QAction* m_zoomFitAction;
151 QAction* m_zoomOriginalAction;
152 QAction* m_zoomOutAction50;
153 QAction* m_zoomOutAction25;
154 QAction* m_zoomInAction;
155 float m_zoomToggleFactor;
157 bool m_pauseAfterOpen;
159 QWidget* m_videoWidget;
160 QHBoxLayout* m_videoLayout;
161 QWidget* m_videoScrollWidget;
162 const TransportControllable* m_currentTransport;
163 QPushButton * m_statusLabel;
164 QPropertyAnimation* m_statusFadeIn;
165 QPropertyAnimation* m_statusFadeOut;
166 QTimer m_statusTimer;
169 void updateSelection();
170 void onInChanged(
int in);
171 void onOutChanged(
int out);
172 void on_actionSkipNext_triggered();
173 void on_actionSkipPrevious_triggered();
174 void on_actionVolume_triggered();
175 void onMuteButtonToggled(
bool checked);
176 void setZoom(
float factor,
const QIcon &icon);
182 void toggleZoom(
bool checked);
183 void onFadeOutFinished();
The SharedFrame provides thread safe access to Mlt::Frame data.
Definition: sharedframe.h:48