Cumulia Illustrator Rendering Engine v1.0.0
A Rendering engine for industrial CAD/CAE model and optimized for greatest performance
 
Loading...
Searching...
No Matches
renderer.h
1//##################################################################################################
2//
3// Copyright (c) 2024 Beijing Qiongqi Tech Co.,Ltd. All rights reserved.
4
5// This source code is confidential and proprietary to Beijing Qiongqi Tech Co.,Ltd(The Holder).
6// Any unauthorized use, copying, modification, or distribution of the code is strictly prohibited.
7// Any user shall obtain authorizaition from the Holder before modifying the source code. And the user shall not
8// sublicense, sell, distribute, or transfer the source code, whether in original or modified form, to any third party
9// without the prior written consent of the Holder.
10
11// This copyright notice and permission grant shall be included in all copies or substantial portions of the source code.
12
13// Author Cumulia Illustrator
14// Date 2024-05-01
15// Version V1.0.0
16//##################################################################################################
17
18#pragma once
19
20#include <memory>
21
22#include "assetmanager.h"
23#include "scenemanager.h"
24#include "rendercontext.h"
25#include "../scene/scene.h"
26
27namespace cil
28{
31 {
32 private:
33 std::shared_ptr<AssetManager> assetManager;
34 std::shared_ptr<SceneManager> sceneManager;
35 std::shared_ptr<RenderContext> renderContext;
36
37 public:
38
40
43 void render(const std::shared_ptr<Scene>& scene);
44
48 std::shared_ptr<Image2D> read(const std::shared_ptr<ImageBuffer>& buffer);
49
51 void add(const std::shared_ptr<Scene>& scene);
52
54 void remove(const std::shared_ptr<Scene>& scene);
55
57 void update(const std::shared_ptr<Scene>& scene);
58
60 void add(const std::shared_ptr<Pass>& pass);
61 void add(const std::shared_ptr<Node>& node);
62 void add(const std::shared_ptr<Mesh>& mesh);
63 void add(const std::shared_ptr<Target>& target);
64 void add(const std::shared_ptr<Primitive>& primitive);
65 void add(const std::shared_ptr<Material>& material);
66 void add(const std::shared_ptr<Geometry>& geometry);
67 void add(const std::shared_ptr<Program>& program);
68 void add(const std::shared_ptr<Texture>& texture);
69 void add(const std::shared_ptr<Vertices>& vertices);
70 void add(const std::shared_ptr<ElementIndices>& indices);
71 void add(const std::shared_ptr<Source>& source);
72 void add(const std::shared_ptr<Image>& image);
73 void add(const std::shared_ptr<Sampler>& sampler);
74 void add(const std::shared_ptr<ArrayBuffer>& buffer);
75
77 void remove(const std::shared_ptr<Pass>& pass);
78 void remove(const std::shared_ptr<Node>& node);
79 void remove(const std::shared_ptr<Mesh>& mesh);
80 void remove(const std::shared_ptr<Target>& target);
81 void remove(const std::shared_ptr<Primitive>& primitive);
82 void remove(const std::shared_ptr<Material>& material);
83 void remove(const std::shared_ptr<Geometry>& geometry);
84 void remove(const std::shared_ptr<Program>& program);
85 void remove(const std::shared_ptr<Texture>& texture);
86 void remove(const std::shared_ptr<Vertices>& vertices);
87 void remove(const std::shared_ptr<ElementIndices>& indices);
88 void remove(const std::shared_ptr<Source>& source);
89 void remove(const std::shared_ptr<Image>& image);
90 void remove(const std::shared_ptr<Sampler>& sampler);
91 void remove(const std::shared_ptr<ArrayBuffer>& buffer);
92
94 void update(const std::shared_ptr<Pass>& pass);
95 void update(const std::shared_ptr<Node>& node);
96 void update(const std::shared_ptr<Mesh>& mesh);
97 void update(const std::shared_ptr<Target>& target);
98 void update(const std::shared_ptr<Primitive>& primitive);
99 void update(const std::shared_ptr<Material>& material);
100 void update(const std::shared_ptr<Geometry>& geometry);
101 void update(const std::shared_ptr<Program>& program);
102 void update(const std::shared_ptr<Texture>& texture);
103 void update(const std::shared_ptr<Vertices>& vertices);
104 void update(const std::shared_ptr<ElementIndices>& indices);
105 void update(const std::shared_ptr<Source>& source);
106 void update(const std::shared_ptr<Image>& image);
107 void update(const std::shared_ptr<Sampler>& sampler);
108 void update(const std::shared_ptr<ArrayBuffer>& buffer);
109
111 void free();
112 };
113}
The Renderer class provides a comprehensive set of interfaces for managing and rendering scene.
Definition renderer.h:31
void remove(const std::shared_ptr< Program > &program)
void remove(const std::shared_ptr< Scene > &scene)
Removes the given scene from the renderer.
void add(const std::shared_ptr< Geometry > &geometry)
void remove(const std::shared_ptr< Node > &node)
void add(const std::shared_ptr< ElementIndices > &indices)
void add(const std::shared_ptr< Node > &node)
void remove(const std::shared_ptr< Primitive > &primitive)
void remove(const std::shared_ptr< Image > &image)
std::shared_ptr< Image2D > read(const std::shared_ptr< ImageBuffer > &buffer)
Reads data from the given image buffer.
void update(const std::shared_ptr< Sampler > &sampler)
void update(const std::shared_ptr< Geometry > &geometry)
void remove(const std::shared_ptr< Pass > &pass)
Removes the given object.
void update(const std::shared_ptr< Node > &node)
void add(const std::shared_ptr< Scene > &scene)
Adds the given scene to the renderer.
void add(const std::shared_ptr< Mesh > &mesh)
void add(const std::shared_ptr< Image > &image)
void remove(const std::shared_ptr< Mesh > &mesh)
void update(const std::shared_ptr< ArrayBuffer > &buffer)
void update(const std::shared_ptr< Material > &material)
void remove(const std::shared_ptr< Source > &source)
void add(const std::shared_ptr< Texture > &texture)
void remove(const std::shared_ptr< Geometry > &geometry)
void remove(const std::shared_ptr< Sampler > &sampler)
void add(const std::shared_ptr< Program > &program)
void update(const std::shared_ptr< ElementIndices > &indices)
void update(const std::shared_ptr< Target > &target)
void remove(const std::shared_ptr< Target > &target)
void add(const std::shared_ptr< Primitive > &primitive)
void update(const std::shared_ptr< Source > &source)
void update(const std::shared_ptr< Mesh > &mesh)
void free()
Frees resources used by the renderer, ensuring that the renderer is properly terminated.
void add(const std::shared_ptr< Target > &target)
void update(const std::shared_ptr< Texture > &texture)
void remove(const std::shared_ptr< ArrayBuffer > &buffer)
void remove(const std::shared_ptr< ElementIndices > &indices)
void update(const std::shared_ptr< Primitive > &primitive)
void remove(const std::shared_ptr< Texture > &texture)
void add(const std::shared_ptr< Pass > &pass)
Adds the given object.
void update(const std::shared_ptr< Pass > &pass)
Updates the given object.
void add(const std::shared_ptr< Source > &source)
void update(const std::shared_ptr< Vertices > &vertices)
void add(const std::shared_ptr< ArrayBuffer > &buffer)
void update(const std::shared_ptr< Scene > &scene)
Removes the given scene from the renderer.
void add(const std::shared_ptr< Sampler > &sampler)
void add(const std::shared_ptr< Vertices > &vertices)
void update(const std::shared_ptr< Image > &image)
void remove(const std::shared_ptr< Material > &material)
void add(const std::shared_ptr< Material > &material)
void remove(const std::shared_ptr< Vertices > &vertices)
void update(const std::shared_ptr< Program > &program)
void render(const std::shared_ptr< Scene > &scene)
Renders the given scene.
Definition decal.h:23