Olive
transition.h
1 /***
2 
3  Olive - Non-Linear Video Editor
4  Copyright (C) 2019 Olive Team
5 
6  This program is free software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  This program is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with this program. If not, see <http://www.gnu.org/licenses/>.
18 
19 ***/
20 
21 #ifndef TRANSITION_H
22 #define TRANSITION_H
23 
24 #include "effect.h"
25 
26 #define TA_NO_TRANSITION 0
27 #define TA_OPENING_TRANSITION 1
28 #define TA_CLOSING_TRANSITION 2
29 
30 #define TRANSITION_INTERNAL_CROSSDISSOLVE 0
31 #define TRANSITION_INTERNAL_LINEARFADE 1
32 #define TRANSITION_INTERNAL_EXPONENTIALFADE 2
33 #define TRANSITION_INTERNAL_LOGARITHMICFADE 3
34 #define TRANSITION_INTERNAL_CUBE 4
35 #define TRANSITION_INTERNAL_COUNT 5
36 
37 int create_transition(Clip* c, Clip* s, const EffectMeta* em, long length = -1);
38 
39 class Transition : public Effect {
40  Q_OBJECT
41 public:
42  Transition(Clip* c, Clip* s, const EffectMeta* em);
43  int copy(Clip* c, Clip* s);
44  Clip* secondary_clip;
45  void set_length(long l);
46  long get_true_length();
47  long get_length();
48 private slots:
49  void set_length_from_slider();
50 private:
51  long length; // used only for transitions
52  EffectField* length_field;
53 };
54 
55 #endif // TRANSITION_H
Definition: effect.h:166
Definition: effect.h:47
Definition: clip.h:53
Definition: effectfield.h:43
Definition: transition.h:39