Euphoria
world.h
Go to the documentation of this file.
1 #pragma once
2 
3 #include <memory>
4 
5 
6 #include "render/instance.h"
7 #include "render/light.h"
8 
9 namespace eu::core
10 {
11  struct Camera3;
12  struct CompiledCamera3;
13  struct Viewport;
14 }
15 
16 namespace eu::io
17 {
18  struct FileSystem;
19 }
20 
21 namespace eu::render
22 {
23  struct MaterialShader;
24  struct ShaderUniform;
25 }
26 
27 namespace eu::render
28 {
29  struct World
30  {
31  void
32  add_actor(const std::shared_ptr<Instance>& actor);
33 
34  // todo(Gustav): improve light support
36 
38  render(const core::Viewport& viewport, const core::Camera3& camera);
39 
40  void
41  update();
42 
43  void
44  render
45  (
46  const core::Camera3& camera,
47  const core::CompiledCamera3& compiled
48  );
49 
50  std::vector<std::shared_ptr<Instance>> actors;
51  };
52 }
Definition: enum.h:8
void update()
Definition: world.cc:29
std::vector< std::shared_ptr< Instance > > actors
Definition: world.h:50
core::CompiledCamera3 render(const core::Viewport &viewport, const core::Camera3 &camera)
Definition: world.cc:21
render::Light light
Definition: world.h:35
void add_actor(const std::shared_ptr< Instance > &actor)
Definition: world.cc:15