Photon Editor Library 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
RenderAgent.h
Go to the documentation of this file.
1#pragma once
2
5
6#include <SDL/sdl_interface.h>
7
8namespace ph::editor::render { class OfflineRenderer; }
9
10namespace ph::editor
11{
12
13class RenderConfig;
14
16{
17public:
18 virtual RenderConfig getRenderConfig() const = 0;
19
25 virtual void render(RenderConfig config) = 0;
26
28
29 math::TDecomposedTransform<real> getLocalToParent() const override;
30 void setLocalToParent(const math::TDecomposedTransform<real>& transform) override;
31
32private:
33 // SDL-binded fields
34 ObjectTransform m_agentTransform;
35
36public:
37 PH_DEFINE_SDL_CLASS(TSdlOwnerClass<RenderAgent>)
38 {
39 ClassType clazz("render-agent");
40 clazz.docName("Render Agent");
41 clazz.description("Controls rendering.");
42 clazz.baseOn<FlatDesignerObject>();
43
44 clazz.addStruct(&OwnerType::m_agentTransform);
45
46 return clazz;
47 }
48};
49
50}// end namespace ph::editor
Definition FlatDesignerObject.h:12
Definition ObjectTransform.h:16
Definition RenderAgent.h:16
math::TDecomposedTransform< real > getLocalToParent() const override
Definition RenderAgent.cpp:7
void setLocalToParent(const math::TDecomposedTransform< real > &transform) override
Definition RenderAgent.cpp:12
virtual void render(RenderConfig config)=0
Start producing a rendered scene. This method kicks off the rendering process and returns immediately...
PH_DEFINE_SDL_CLASS(TSdlOwnerClass< RenderAgent >)
Definition RenderAgent.h:37
virtual RenderConfig getRenderConfig() const =0
void renderWithDefaultConfig()
Definition RenderAgent.cpp:17
Definition RenderConfig.h:13
Definition DesignerObject.h:19
Definition ph_editor.h:10