diff options
author | vimene <vincent.menegaux@gmail.com> | 2023-11-26 17:58:30 +0100 |
---|---|---|
committer | vimene <vincent.menegaux@gmail.com> | 2023-11-26 17:58:30 +0100 |
commit | e730e8bdc69ef89dfa28d2606d260cb8b72f4740 (patch) | |
tree | c219050793df6d1d777e94ea3c887027cde7451e /src/o3d/scene.cpp | |
parent | 5a1d67d1797a3db874e44500e13237d676843185 (diff) | |
download | engine-e730e8bdc69ef89dfa28d2606d260cb8b72f4740.tar.gz |
added scenes, camera and meshes
Diffstat (limited to 'src/o3d/scene.cpp')
-rw-r--r-- | src/o3d/scene.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/o3d/scene.cpp b/src/o3d/scene.cpp new file mode 100644 index 0000000..aba25dc --- /dev/null +++ b/src/o3d/scene.cpp @@ -0,0 +1,12 @@ +#include "o3d/scene.h" +#include <vector> +#include "o3d/camera.h" +#include "o3d/obj3d.h" + +using namespace engine::o3d; + +Scene::Scene(Camera camera, std::vector<Object3D> objs) : camera{camera}, objs{objs} { + this.camera.scene = this; + for (auto& obj : this.objs) + obj.scene = this; +} |