Loading...
Searching...
No Matches
CameraFactory.h
Go to the documentation of this file.
1#pragma once
2#include <string>
3#include <glm/glm.hpp>
4
5namespace hellfire {
6 class Scene;
7 using EntityID = uint32_t;
8
10 public:
11 static EntityID create(
12 Scene* scene,
13 const std::string& name,
14 float fov = 70.0f,
15 float aspect = 16.0f/9.0f,
16 float near_plane = 0.1f,
17 float far_plane = 1000.0f,
18 const glm::vec3& position = glm::vec3(0.0f)
19 );
20
22 Scene* scene,
23 const std::string& name,
24 const glm::vec3& position,
25 const glm::vec3& target,
26 float fov = 70.0f,
27 float aspect = 16.0f/9.0f,
28 float near_plane = 0.1f,
29 float far_plane = 1000.0f
30 );
31 };
32
34 public:
35 static EntityID create(
36 Scene* scene,
37 const std::string& name,
38 float size,
39 float aspect,
40 float near_plane = -1.0f,
41 float far_plane = 1.0f,
42 const glm::vec3& position = glm::vec3(0.0f)
43 );
44
46 Scene* scene,
47 const std::string& name,
48 float left,
49 float right,
50 float bottom,
51 float top,
52 float near_plane = -1.0f,
53 float far_plane = 1.0f,
54 const glm::vec3& position = glm::vec3(0.0f)
55 );
56 };
57}
TransformComponent * transform()
Definition Entity.cpp:42
static EntityID create(Scene *scene, const std::string &name, float size, float aspect, float near_plane=-1.0f, float far_plane=1.0f, const glm::vec3 &position=glm::vec3(0.0f))
static EntityID create_with_bounds(Scene *scene, const std::string &name, float left, float right, float bottom, float top, float near_plane=-1.0f, float far_plane=1.0f, const glm::vec3 &position=glm::vec3(0.0f))
static EntityID create_looking_at(Scene *scene, const std::string &name, const glm::vec3 &position, const glm::vec3 &target, float fov=70.0f, float aspect=16.0f/9.0f, float near_plane=0.1f, float far_plane=1000.0f)
static EntityID create(Scene *scene, const std::string &name, float fov=70.0f, float aspect=16.0f/9.0f, float near_plane=0.1f, float far_plane=1000.0f, const glm::vec3 &position=glm::vec3(0.0f))
Manages a collection of entities and their hierarchical relationships.
Definition Scene.h:24
Entity * get_entity(EntityID id)
Retrieves an entity by its ID.
Definition Scene.cpp:81
EntityID create_entity(const std::string &name="GameObject")
Creates a new entity in the scene.
Definition Scene.cpp:29
void set_position(float x, float y, float z)