KiCad PCB EDA Suite
Loading...
Searching...
No Matches
LIGHT Class Referenceabstract

A base light class to derive to implement other light classes. More...

#include <light.h>

Inheritance diagram for LIGHT:
DIRECTIONAL_LIGHT POINT_LIGHT

Public Member Functions

 LIGHT ()
 
virtual ~LIGHT ()
 
virtual void GetLightParameters (const SFVEC3F &aHitPoint, SFVEC3F &aOutVectorToLight, SFVEC3F &aOutLightColor, float &aOutDistance) const =0
 Get parameters from this light.
 
void SetCastShadows (bool aCastShadow)
 
bool GetCastShadows () const
 

Protected Attributes

bool m_castShadow
 

Detailed Description

A base light class to derive to implement other light classes.

Definition at line 40 of file light.h.

Constructor & Destructor Documentation

◆ LIGHT()

LIGHT::LIGHT ( )
inline

Definition at line 43 of file light.h.

References m_castShadow.

◆ ~LIGHT()

virtual LIGHT::~LIGHT ( )
inlinevirtual

Definition at line 45 of file light.h.

Member Function Documentation

◆ GetCastShadows()

bool LIGHT::GetCastShadows ( ) const
inline

Definition at line 60 of file light.h.

References m_castShadow.

◆ GetLightParameters()

virtual void LIGHT::GetLightParameters ( const SFVEC3F aHitPoint,
SFVEC3F aOutVectorToLight,
SFVEC3F aOutLightColor,
float &  aOutDistance 
) const
pure virtual

Get parameters from this light.

Parameters
aHitPointinput hit position
aOutVectorToLighta vector that points from the hit position in direction to the light
aOutLightColorthe color of this light
aOutDistancethe distance from the point to the light

Implemented in DIRECTIONAL_LIGHT, and POINT_LIGHT.

◆ SetCastShadows()

void LIGHT::SetCastShadows ( bool  aCastShadow)
inline

Definition at line 59 of file light.h.

References m_castShadow.

Referenced by RENDER_3D_RAYTRACE_BASE::Reload().

Member Data Documentation

◆ m_castShadow

bool LIGHT::m_castShadow
protected

The documentation for this class was generated from the following file: