Unravel Engine C++ Reference
|
Class that contains core light data, used for rendering and other purposes. More...
#include <light_component.h>
Public Member Functions | |
auto | get_light () const -> const light & |
Gets the light object. | |
void | set_light (const light &l) |
Sets the light object. | |
auto | get_bounds () const -> math::bbox |
Gets the bounding box of the light object. | |
auto | get_bounds_sphere () const -> math::bsphere |
auto | get_bounds_precise (const math::vec3 &light_direction) const -> math::bbox |
Gets the bounding box of the light object. | |
auto | get_bounds_sphere_precise (const math::vec3 &light_direction) const -> math::bsphere |
auto | compute_projected_sphere_rect (irect32_t &rect, const math::vec3 &light_position, const math::vec3 &light_direction, const math::vec3 &view_origin, const math::transform &view, const math::transform &proj) -> int |
Computes the projected sphere rectangle. | |
auto | get_shadowmap_generator () -> shadow::shadowmap_generator & |
Gets the shadow map generator. | |
![]() | |
void | touch () |
Marks the component as 'touched'. | |
Additional Inherited Members | |
![]() | |
using | base |
![]() | |
bool | eto {} |
Disable empty type optimizations. | |
![]() | |
static constexpr bool | in_place_delete |
Indicates if the component can be deleted in place. | |
Class that contains core light data, used for rendering and other purposes.
Definition at line 14 of file light_component.h.
int unravel::light_component::compute_projected_sphere_rect | ( | irect32_t & | rect, |
const math::vec3 & | light_position, | ||
const math::vec3 & | light_direction, | ||
const math::vec3 & | view_origin, | ||
const math::transform & | view, | ||
const math::transform & | proj ) -> int |
Computes the projected sphere rectangle.
[out] | rect | Reference to the rectangle to be computed. |
[in] | light_position | The position of the light. |
[in] | light_direction | The direction of the light. |
[in] | view_origin | The origin of the view. |
[in] | view | The view transform. |
[in] | proj | The projection transform. |
Definition at line 81 of file light_component.cpp.
auto unravel::light_component::get_bounds | ( | ) | const -> math::bbox |
Gets the bounding box of the light object.
Definition at line 65 of file light_component.cpp.
auto unravel::light_component::get_bounds_precise | ( | const math::vec3 & | light_direction | ) | const -> math::bbox |
Gets the bounding box of the light object.
Definition at line 73 of file light_component.cpp.
auto unravel::light_component::get_bounds_sphere | ( | ) | const -> math::bsphere |
Definition at line 55 of file light_component.cpp.
auto unravel::light_component::get_bounds_sphere_precise | ( | const math::vec3 & | light_direction | ) | const -> math::bsphere |
Definition at line 60 of file light_component.cpp.
Gets the light object.
Definition at line 4 of file light_component.cpp.
auto unravel::light_component::get_shadowmap_generator | ( | ) | -> shadow::shadowmap_generator& |
Gets the shadow map generator.
Definition at line 130 of file light_component.cpp.
void unravel::light_component::set_light | ( | const light & | l | ) |
Sets the light object.
[in] | l | The light object to set. |
Definition at line 9 of file light_component.cpp.