65 std::shared_ptr<SceneObject>
FindObject(
const std::string &name)
const;
71 const std::vector<std::shared_ptr<SceneObject>> &
GetObjects()
const {
return m_Objects; }
82 void Update(
float deltaTime);
114 std::vector<std::shared_ptr<SceneObject>> m_Objects;
Abstract base class for all camera types.
Definition BaseCamera.h:34
Responsible for rendering mesh objects using specified shaders.
Definition Renderer.h:19
Base class for objects in the 3D scene.
Definition SceneObject.h:19
Manages a collection of scene objects and provides rendering functionality.
Definition Scene.h:19
void ClearSelection()
Clears all object selections.
Definition Scene.cpp:114
SceneObject & AddObject(std::shared_ptr< SceneObject > object)
Adds a scene object to the scene.
Definition Scene.cpp:13
std::shared_ptr< SceneObject > FindObject(const std::string &name) const
Finds a scene object by name.
Definition Scene.cpp:53
void Render(Renderer &renderer, const BaseCamera &camera, Shader &shader)
Renders all visible objects in the scene.
Definition Scene.cpp:80
~Scene()
Destructor.
Definition Scene.cpp:8
void Clear()
Clears all objects from the scene.
Definition Scene.cpp:64
void SelectObject(std::shared_ptr< SceneObject > object)
Selects an object by pointer and clears other selections.
Definition Scene.cpp:102
std::shared_ptr< SceneObject > GetSelectedObject() const
Gets the currently selected object.
Definition Scene.cpp:125
void Update(float deltaTime)
Updates all objects in the scene.
Definition Scene.cpp:69
const std::vector< std::shared_ptr< SceneObject > > & GetObjects() const
Gets all scene objects.
Definition Scene.h:71
Scene()
Constructor.
Definition Scene.cpp:4
size_t GetObjectCount() const
Gets the number of objects in the scene.
Definition Scene.h:94
bool RemoveObject(const std::string &name)
Removes a scene object by name.
Definition Scene.cpp:26
Encapsulates an OpenGL shader program, handling compilation, linking, and usage.
Definition Shader.h:14