]> git.sesse.net Git - kdenlive/blob - src/transitionsettings.h
efe0188e1e53031e1ce800158f5c6b6369042573
[kdenlive] / src / transitionsettings.h
1 /***************************************************************************
2                           transitionsettings.h  -  Transitions widget
3                              -------------------
4     begin                : Mar 15 2008
5     copyright            : (C) 2008 by Marco Gittler
6     email                : g.marco@freenet.de
7  ***************************************************************************/
8
9 /***************************************************************************
10  *                                                                         *
11  *   This program is free software; you can redistribute it and/or modify  *
12  *   it under the terms of the GNU General Public License as published by  *
13  *   the Free Software Foundation; either version 2 of the License, or     *
14  *   (at your option) any later version.                                   *
15  *                                                                         *
16  ***************************************************************************/
17 #ifndef TRANSITIONSETTINGS_H
18 #define TRANSITIONSETTINGS_H
19
20 #include <QDomElement>
21
22 #include "ui_transitionsettings_ui.h"
23 #include "definitions.h"
24
25 class Timecode;
26 class Transition;
27 class EffectsList;
28 class EffectStackEdit;
29 class Monitor;
30
31 class TransitionSettings : public QWidget, public Ui::TransitionSettings_UI
32 {
33     Q_OBJECT
34
35 public:
36     explicit TransitionSettings(Monitor *monitor, QWidget* parent = 0);
37     void raiseWindow(QWidget*);
38     void updateProjectFormat(MltVideoProfile profile, Timecode t, const QList <TrackInfo> info);
39     void updateTimecodeFormat();
40     void setKeyframes(const QString data, int maximum);
41
42 private:
43     EffectStackEdit *m_effectEdit;
44     Transition* m_usedTransition;
45     GenTime m_transitionDuration;
46     GenTime m_transitionStart;
47     int m_autoTrackTransition;
48     QList <TrackInfo> m_tracks;
49     void updateTrackList();
50
51 public slots:
52     void slotTransitionItemSelected(Transition* t, int nextTrack, QPoint p, bool update);
53     void slotTransitionChanged(bool reinit = true, bool updateCurrent = false);
54     void slotUpdateEffectParams(const QDomElement, const QDomElement);
55
56 private slots:
57     /** @brief Sets the new B track for the transition (automatic or forced). */
58     void slotTransitionTrackChanged();
59     /** @brief Pass position changes of the timeline cursor to the effects to keep their local timelines in sync. */
60     void slotRenderPos(int pos);
61     void slotSeekTimeline(int pos);
62     void slotCheckMonitorPosition(int renderPos);
63
64 signals:
65     void transitionUpdated(Transition *, QDomElement);
66     void seekTimeline(int);
67     void importClipKeyframes(GRAPHICSRECTITEM = TRANSITIONWIDGET);
68 };
69
70 #endif