Olive
renderfunctions.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 RENDERFUNCTIONS_H
22 #define RENDERFUNCTIONS_H
23 
24 #include <QOpenGLContext>
25 #include <QVector>
26 
27 class Effect;
28 class Viewer;
29 class QOpenGLShaderProgram;
30 struct Sequence;
31 class Clip;
32 
39 
46 
54  QOpenGLContext* ctx;
55 
63 
70  QVector<Clip*> nests;
71 
77  bool video;
78 
86 
108 
124 
133 
145  QOpenGLShaderProgram* blend_mode_program;
146 
157  QOpenGLShaderProgram* premultiply_program;
158 
166  GLuint main_buffer;
167 
176 
184 
192 
200 
208 };
209 
232 GLuint compose_sequence(ComposeSequenceParams &params);
233 
253 void compose_audio(Viewer* viewer, Sequence* seq, int playback_speed);
254 
255 #endif // RENDERFUNCTIONS_H
QVector< Clip * > nests
Array to store the nested sequence hierarchy.
Definition: renderfunctions.h:70
Definition: sequence.h:33
QOpenGLShaderProgram * premultiply_program
Premultiply alpha shader.
Definition: renderfunctions.h:157
The ComposeSequenceParams struct.
Definition: renderfunctions.h:38
GLuint backend_buffer2
Backend OpenGL framebuffer 2 used for further processing before rendering to main_buffer.
Definition: renderfunctions.h:199
GLuint backend_buffer1
Backend OpenGL framebuffer 1 used for further processing before rendering to main_buffer.
Definition: renderfunctions.h:183
bool texture_failed
A variable that compose_sequence() will set to TRUE if any of the clips couldn't be shown.
Definition: renderfunctions.h:107
Definition: effect.h:166
bool video
Set compose mode to video or audio.
Definition: renderfunctions.h:77
GLuint main_attachment
The attachment to the framebuffer in main_buffer.
Definition: renderfunctions.h:175
Effect ** gizmos
Set to the Effect whose gizmos were chosen to be drawn on screen.
Definition: renderfunctions.h:85
Viewer * viewer
Reference to the Viewer class that's calling compose_sequence()
Definition: renderfunctions.h:45
GLuint main_buffer
The OpenGL framebuffer object that the final texture to be shown is rendered to.
Definition: renderfunctions.h:166
QOpenGLShaderProgram * blend_mode_program
Blending mode shader.
Definition: renderfunctions.h:145
int playback_speed
Set the current playback speed (adjusted with Shuttle Left/Right)
Definition: renderfunctions.h:132
GLuint backend_attachment2
Backend OpenGL framebuffer 2's texture attachment.
Definition: renderfunctions.h:207
Sequence * seq
The sequence to compose.
Definition: renderfunctions.h:62
Definition: clip.h:53
Definition: viewer.h:45
QOpenGLContext * ctx
The OpenGL context to use while rendering.
Definition: renderfunctions.h:54
GLuint backend_attachment1
Backend OpenGL framebuffer 1's texture attachment.
Definition: renderfunctions.h:191
bool single_threaded
Run all cachers in the same thread that compose_sequence() is in.
Definition: renderfunctions.h:123