6 #ifndef HIRO_DRAW_RENDERER_H 7 #define HIRO_DRAW_RENDERER_H 11 #include <glm/glm.hpp> 13 #include <GLW/ShaderProgramList.h> 14 #include <COGS/Color.h> 15 #include <COGS/MaterialModel.h> 16 #include <COGS/Transform.h> 17 #include <HIRO_DRAW/PrimitiveDatabase.h> 34 virtual ~
Style() =
default;
36 virtual bool ReadFromStream(std::istream &str);
38 virtual void WriteToStream(std::ostream &str);
41 bool ReadVersion(std::istream &str,
const uint32_t expected_version);
57 virtual void LoadRequiredShaderPrograms(glw::ProgramList *programs);
59 virtual void Render(
const std::string &program);
72 virtual void OnRenderSimple();
75 virtual void Render2D(
const std::string &program);
87 virtual void OnRenderSimple2D();
93 template <
typename StyleType>
94 const StyleType *GetStyle()
const;
96 const Scene *GetScene()
const;
103 template <
typename StyleType>
106 return static_cast<const StyleType *
>(style_);
111 using PStyle = std::shared_ptr<hiro::draw::Style>;
112 using PRenderer = std::shared_ptr<hiro::draw::Renderer>;
Responsible for rendering texts.
Definition: TextRenderer.h:47
Extensions for object visualization. Implements a higher level of OpenGL rendering.
Definition: API.h:20
const StyleType * GetStyle() const
Obtain currently set object style of specific type. Can be used only in Update-Render stage! ...
Definition: Renderer.h:104
Base class for setting rendering style of an arbitrary render object.
Definition: Renderer.h:27
cogs::Transform transform
Model transformation applied to the renderer. In shader will appear as MODEL_MATRIX.
Definition: Renderer.h:32
Class responsible for rendering loop implementation and its optimization.
Definition: RenderSystem.h:42
Defines rendering viewport, contains multiple object instances and a camera.
Definition: Scene.h:92
Abstract base class for an arbitrary renderer object.
Definition: Renderer.h:47