Divide Framework 0.1
A free and open-source 3D Framework under heavy development
Loading...
Searching...
No Matches
EnvironmentProbeSystem.cpp
Go to the documentation of this file.
1
2
4
7
8namespace Divide {
10 : PlatformContextComponent(context),
11 ECSSystem(parentEngine)
12 {
13 }
14
17
19
21 if (comp->_drawImpostor || comp->showParallaxAABB()) {
22 const BoundingBox& aabb = comp->_aabb;
23 {
24 IM::SphereDescriptor descriptor;
25 descriptor.center = aabb.getCenter();
26 descriptor.radius = 0.5f;
28 context().gfx().debugDrawSphere(comp->getGUID() + 0, descriptor);
29 }
30 {
31 IM::BoxDescriptor descriptor;
32 descriptor.min = aabb.getMin();
33 descriptor.max = aabb.getMax();
35 context().gfx().debugDrawBox(comp->getGUID() + 1, descriptor);
36 }
37 }
38
39 switch (comp->_updateType) {
41 if (comp->_queueRefresh) {
42 comp->dirty(true);
43 }
44 break;
46 if (comp->_queueRefresh) {
47 comp->dirty(++comp->_currentUpdateCall % comp->_updateRate == 0);
48 }
49 break;
52 break;//Nothing needed
55 break;
56 }
57 }
58 }
59
60} //namespace Divide
#define DIVIDE_UNEXPECTED_CALL()
#define PROFILE_SCOPE_AUTO(CATEGORY)
Definition: Profiler.h:87
vec3< F32 > getCenter() const noexcept
const vec3< F32 > & getMax() const noexcept
const vec3< F32 > & getMin() const noexcept
EnvironmentProbeSystem(ECS::ECSEngine &parentEngine, PlatformContext &context)
void debugDrawSphere(const I64 ID, IM::SphereDescriptor descriptor) noexcept
Definition: GFXDevice.cpp:2936
void debugDrawBox(const I64 ID, IM::BoxDescriptor descriptor) noexcept
Definition: GFXDevice.cpp:2877
PlatformContext & context() noexcept
GFXDevice & gfx() noexcept
constexpr Optick::Category::Type Scene
Definition: Profiler.h:66
Handle console commands that start with a forward slash.
Definition: AIProcessor.cpp:7