Divide Framework 0.1
A free and open-source 3D Framework under heavy development
Loading...
Searching...
No Matches
DirectionalLightSystem.cpp
Go to the documentation of this file.
1
2
4
10
11namespace Divide {
13 : PlatformContextComponent(context),
14 ECSSystem(parentEngine)
15 {
16 }
17
20
23 if (comp->drawImpostor() || comp->showDirectionCone()) {
24 IM::ConeDescriptor descriptor;
25 descriptor.root = -comp->directionCache() * comp->range();
26 descriptor.direction = comp->directionCache();
27 descriptor.length = comp->range();
28 descriptor.radius = 2.f;
29 descriptor.noCull = true;
30 descriptor.colour = Util::ToByteColour(comp->getDiffuseColour());
31 context().gfx().debugDrawCone(comp->getGUID() + 0, descriptor);
32 }
33 }
34 }
35
36} //namespace Divide
#define PROFILE_SCOPE_AUTO(CATEGORY)
Definition: Profiler.h:87
DirectionalLightSystem(ECS::ECSEngine &parentEngine, PlatformContext &context)
void debugDrawCone(const I64 ID, IM::ConeDescriptor descriptor) noexcept
Definition: GFXDevice.cpp:2966
PlatformContext & context() noexcept
GFXDevice & gfx() noexcept
constexpr Optick::Category::Type Scene
Definition: Profiler.h:66
UColour4 ToByteColour(const FColour4 &floatColour) noexcept
Definition: MathHelper.cpp:256
Handle console commands that start with a forward slash.
Definition: AIProcessor.cpp:7
DirectionalLightComponent(SceneGraphNode *sgn, PlatformContext &context)