Blender  V2.93
COM_ExecutionSystem.h
Go to the documentation of this file.
1 /*
2  * This program is free software; you can redistribute it and/or
3  * modify it under the terms of the GNU General Public License
4  * as published by the Free Software Foundation; either version 2
5  * of the License, or (at your option) any later version.
6  *
7  * This program is distributed in the hope that it will be useful,
8  * but WITHOUT ANY WARRANTY; without even the implied warranty of
9  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10  * GNU General Public License for more details.
11  *
12  * You should have received a copy of the GNU General Public License
13  * along with this program; if not, write to the Free Software Foundation,
14  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
15  *
16  * Copyright 2011, Blender Foundation.
17  */
18 
19 class ExecutionGroup;
20 
21 #pragma once
22 
23 #include "BKE_text.h"
24 
25 #include "COM_ExecutionGroup.h"
26 #include "COM_Node.h"
27 #include "COM_NodeOperation.h"
28 
29 #include "DNA_color_types.h"
30 #include "DNA_node_types.h"
31 
32 #include "BLI_vector.hh"
33 
34 namespace blender::compositor {
35 
122 
123  private:
127  CompositorContext m_context;
128 
132  Vector<NodeOperation *> m_operations;
133 
137  Vector<ExecutionGroup *> m_groups;
138 
139  private: // methods
140  public:
149  Scene *scene,
150  bNodeTree *editingtree,
151  bool rendering,
152  bool fastcalculation,
153  const ColorManagedViewSettings *viewSettings,
154  const ColorManagedDisplaySettings *displaySettings,
155  const char *viewName);
156 
161 
162  void set_operations(const Vector<NodeOperation *> &operations,
163  const Vector<ExecutionGroup *> &groups);
164 
171  void execute();
172 
177  {
178  return this->m_context;
179  }
180 
181  private:
182  void execute_groups(eCompositorPriority priority);
183 
184  /* allow the DebugInfo class to look at internals */
185  friend class DebugInfo;
186 
187 #ifdef WITH_CXX_GUARDEDALLOC
188  MEM_CXX_CLASS_ALLOC_FUNCS("COM:ExecutionSystem")
189 #endif
190 };
191 
192 } // namespace blender::compositor
Overall context of the compositor.
the ExecutionSystem contains the whole compositor tree.
const CompositorContext & getContext() const
get the reference to the compositor context
void set_operations(const Vector< NodeOperation * > &operations, const Vector< ExecutionGroup * > &groups)
ExecutionSystem(RenderData *rd, Scene *scene, bNodeTree *editingtree, bool rendering, bool fastcalculation, const ColorManagedViewSettings *viewSettings, const ColorManagedDisplaySettings *displaySettings, const char *viewName)
Create a new ExecutionSystem and initialize it with the editingtree.
Scene scene
eCompositorPriority
Possible priority settings.
Definition: COM_Enums.h:45