Antkeeper
0.0.1
|
Collection of scene objects. More...
#include <collection.hpp>
Public Member Functions | |
Objects | |
void | add_object (object_base &object) |
Adds an object to the collection. More... | |
void | remove_object (const object_base &object) |
Removes an object from the collection. More... | |
void | remove_objects () |
Removes all objects from the collection. More... | |
const std::vector< object_base * > & | get_objects () const noexcept |
Returns all objects in the collection. More... | |
const std::vector< object_base * > & | get_objects (std::size_t type_id) const |
Returns all objects in the collection with the given type ID. More... | |
Settings | |
void | set_scale (float scale) noexcept |
Sets the scale of the scene. More... | |
float | get_scale () const noexcept |
Returns the ratio of meters to scene units. More... | |
Collection of scene objects.
Definition at line 32 of file collection.hpp.
void scene::collection::add_object | ( | object_base & | object | ) |
Adds an object to the collection.
object | Object to add. |
Definition at line 24 of file collection.cpp.
|
inlinenoexcept |
Returns all objects in the collection.
Definition at line 56 of file collection.hpp.
|
inline |
Returns all objects in the collection with the given type ID.
type_id | Scene object type ID. |
Definition at line 68 of file collection.hpp.
|
inlinenoexcept |
Returns the ratio of meters to scene units.
Definition at line 88 of file collection.hpp.
void scene::collection::remove_object | ( | const object_base & | object | ) |
Removes an object from the collection.
object | Object to remove. |
Definition at line 30 of file collection.cpp.
void scene::collection::remove_objects | ( | ) |
Removes all objects from the collection.
Definition at line 36 of file collection.cpp.
|
inlinenoexcept |
Sets the scale of the scene.
scale | Ratio of meters to scene units. |
Definition at line 82 of file collection.hpp.