From 0ea5fc66924303d1bf73ba283a383e2aadee02f2 Mon Sep 17 00:00:00 2001 From: neodarz Date: Sat, 11 Aug 2018 20:21:34 +0200 Subject: Initial commit --- docs/doxygen/nel/classNL3D_1_1CPointLightUser.html | 895 +++++++++++++++++++++ 1 file changed, 895 insertions(+) create mode 100644 docs/doxygen/nel/classNL3D_1_1CPointLightUser.html (limited to 'docs/doxygen/nel/classNL3D_1_1CPointLightUser.html') diff --git a/docs/doxygen/nel/classNL3D_1_1CPointLightUser.html b/docs/doxygen/nel/classNL3D_1_1CPointLightUser.html new file mode 100644 index 00000000..bec22dfc --- /dev/null +++ b/docs/doxygen/nel/classNL3D_1_1CPointLightUser.html @@ -0,0 +1,895 @@ + + + + nevrax.org : docs + + + + + + + + + + + + + + +
# Home   # nevrax.com   
+ + + + +
Nevrax
+ + + + + + + + + + +
+ + +
+ Nevrax.org
+ + + + + + + +
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
+
+ + +
+ + +
+Docs + +
+  + + + + + +
Documentation 
+ +
+Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  
+

NL3D::CPointLightUser Class Reference

UPointLight implementation. +More... +

+#include <point_light_user.h> +

+

Inheritance diagram for NL3D::CPointLightUser: +

+ +NL3D::UPointLight +NL3D::CTransformUser +NL3D::UTransform +NL3D::UTransform +NL3D::CTransformableUser +NL3D::UTransformable +NL3D::UTransformable +NL3D::UTransformable + +List of all members. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Public Methods

virtual void setAmbient (NLMISC::CRGBA ambient)
 Set the ambient color of the light. Default to Black. More...

virtual void setDiffuse (NLMISC::CRGBA diffuse)
 Set the diffuse color of the light. Default to White. More...

virtual void setSpecular (NLMISC::CRGBA specular)
 Set the specular color of the light. Default to White. More...

virtual void setColor (NLMISC::CRGBA color)
 Set the diffuse and specular color of the light to the same value. don't modify _Ambient. More...

virtual NLMISC::CRGBA getAmbient () const
 Get the ambient color of the light. More...

virtual NLMISC::CRGBA getDiffuse () const
 Get the diffuse color of the light. More...

virtual NLMISC::CRGBA getSpecular () const
 Get the specular color of the light. More...

virtual void setupAttenuation (float attenuationBegin, float attenuationEnd)
 setup the attenuation of the light. More...

virtual float getAttenuationBegin () const
 get the begin radius of the attenuation. More...

virtual float getAttenuationEnd () const
 get the end radius of the attenuation. More...

virtual void enableSpotlight (bool enable)
 Setup SpotLight. More...

virtual bool isSpotlight () const
 Is Spotlight enabled? More...

virtual void setupSpotAngle (float spotAngleBegin, float spotAngleEnd)
 setup the spot AngleBegin and AngleEnd that define spot attenuation of the light. More...

virtual float getSpotAngleBegin () const
 get the begin radius of the SpotAngles. More...

virtual float getSpotAngleEnd () const
 get the end radius of the SpotAngles. More...

virtual void setDeltaPosToSkeletonWhenOutOfFrustum (const CVector &deltaPos)
 setup the deltaPosToSkeletonWhenOutOfFrustum When a light is sticked to a skeleton, and if this skeleton is clipped, then the position of the light can't be computed correctly without animating the skeleton. More...

virtual const CVector & getDeltaPosToSkeletonWhenOutOfFrustum () const
 see setDeltaPosToSkeletonWhenOutOfFrustum(). More...

Object
 CPointLightUser (CScene *scene, IModel *trans)
 This model should have been created with Scene::createInstance(). More...

virtual ~CPointLightUser ()

Public Attributes

CPointLightModel_PointLightModel
 This is the SAME pointer than _Transform, but correctly casted. More...

+

Detailed Description

+UPointLight implementation. +

+

+Author:
+Lionel Berenguier , Nevrax France
+Date:
+2001
+

+ +

+Definition at line 49 of file point_light_user.h.


Constructor & Destructor Documentation

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
NL3D::CPointLightUser::CPointLightUser CScene  scene,
IModel  trans
+
+ + + + + +
+   + + +

+This model should have been created with Scene::createInstance(). +

+ +

+Definition at line 41 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
virtual NL3D::CPointLightUser::~CPointLightUser   [inline, virtual]
+
+ + + + + +
+   + + +

+ +

+Definition at line 61 of file point_light_user.h. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+


Member Function Documentation

+

+ + + + +
+ + + + + + + + + + +
void NL3D::CPointLightUser::enableSpotlight bool   enable [virtual]
+
+ + + + + +
+   + + +

+Setup SpotLight. +

+SpotLight is disabled by default. The direction of the spot is lead by the J vector of the UPointLight WorldMatrix +

+Implements NL3D::UPointLight. +

+Definition at line 107 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
NLMISC::CRGBA NL3D::CPointLightUser::getAmbient   const [virtual]
+
+ + + + + +
+   + + +

+Get the ambient color of the light. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 72 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
float NL3D::CPointLightUser::getAttenuationBegin   const [virtual]
+
+ + + + + +
+   + + +

+get the begin radius of the attenuation. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 94 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
float NL3D::CPointLightUser::getAttenuationEnd   const [virtual]
+
+ + + + + +
+   + + +

+get the end radius of the attenuation. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 99 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
const CVector & NL3D::CPointLightUser::getDeltaPosToSkeletonWhenOutOfFrustum   const [virtual]
+
+ + + + + +
+   + + +

+see setDeltaPosToSkeletonWhenOutOfFrustum(). +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 142 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
NLMISC::CRGBA NL3D::CPointLightUser::getDiffuse   const [virtual]
+
+ + + + + +
+   + + +

+Get the diffuse color of the light. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 77 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
NLMISC::CRGBA NL3D::CPointLightUser::getSpecular   const [virtual]
+
+ + + + + +
+   + + +

+Get the specular color of the light. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 82 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
float NL3D::CPointLightUser::getSpotAngleBegin   const [virtual]
+
+ + + + + +
+   + + +

+get the begin radius of the SpotAngles. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 125 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
float NL3D::CPointLightUser::getSpotAngleEnd   const [virtual]
+
+ + + + + +
+   + + +

+get the end radius of the SpotAngles. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 130 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + +
bool NL3D::CPointLightUser::isSpotlight   const [virtual]
+
+ + + + + +
+   + + +

+Is Spotlight enabled? +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 115 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + + +
void NL3D::CPointLightUser::setAmbient NLMISC::CRGBA   ambient [virtual]
+
+ + + + + +
+   + + +

+Set the ambient color of the light. Default to Black. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 50 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + + +
void NL3D::CPointLightUser::setColor NLMISC::CRGBA   color [virtual]
+
+ + + + + +
+   + + +

+Set the diffuse and specular color of the light to the same value. don't modify _Ambient. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 65 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + + +
void NL3D::CPointLightUser::setDeltaPosToSkeletonWhenOutOfFrustum const CVector &   deltaPos [virtual]
+
+ + + + + +
+   + + +

+setup the deltaPosToSkeletonWhenOutOfFrustum When a light is sticked to a skeleton, and if this skeleton is clipped, then the position of the light can't be computed correctly without animating the skeleton. +

+To allow good position of the light, and to avoid recomputing the skeleton even if it is clipped, the light position is set to skeletonMatrix * this "deltaPosToSkeletonWhenOutOfFrustum". +

+Default is (0, 0, 1.5). You may change this according to the approximate size of the skeleton (dwarf or giant), and you must take into account any mount (horse etc...). eg for a man on a elephant, a good value would be (0,0,5) :) +

+Implements NL3D::UPointLight. +

+Definition at line 137 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + + +
void NL3D::CPointLightUser::setDiffuse NLMISC::CRGBA   diffuse [virtual]
+
+ + + + + +
+   + + +

+Set the diffuse color of the light. Default to White. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 55 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + + +
void NL3D::CPointLightUser::setSpecular NLMISC::CRGBA   specular [virtual]
+
+ + + + + +
+   + + +

+Set the specular color of the light. Default to White. +

+ +

+Implements NL3D::UPointLight. +

+Definition at line 60 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
void NL3D::CPointLightUser::setupAttenuation float   attenuationBegin,
float   attenuationEnd
[virtual]
+
+ + + + + +
+   + + +

+setup the attenuation of the light. +

+if (0,0) attenuation is disabled. clamp(attenuationBegin,0 , +oo) and clamp(attenuationEnd, attenuationBegin, +oo) By default, attenuation is 10-30. PERFORMANCE WARNING: big lights (disabled attenuation and big attenuationEnd) slow down performances. (by experience, with a factor of 2). +

+Implements NL3D::UPointLight. +

+Definition at line 89 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
void NL3D::CPointLightUser::setupSpotAngle float   spotAngleBegin,
float   spotAngleEnd
[virtual]
+
+ + + + + +
+   + + +

+setup the spot AngleBegin and AngleEnd that define spot attenuation of the light. +

+Usefull only if SpotLight NB: clamp(angleBegin, 0, PI); clamp(angleEnd, angleBegin, PI); Default is PI/4, PI/2 +

+Implements NL3D::UPointLight. +

+Definition at line 120 of file point_light_user.cpp. +

+References _PointLightModel, and NL3D_MEM_POINTLIGHT.

+


Member Data Documentation

+

+ + + + +
+ + +
CPointLightModel* NL3D::CPointLightUser::_PointLightModel +
+
+ + + + + +
+   + + +

+This is the SAME pointer than _Transform, but correctly casted. +

+ +

+Definition at line 53 of file point_light_user.h. +

+Referenced by CPointLightUser, enableSpotlight, getAmbient, getAttenuationBegin, getAttenuationEnd, getDeltaPosToSkeletonWhenOutOfFrustum, getDiffuse, getSpecular, getSpotAngleBegin, getSpotAngleEnd, isSpotlight, setAmbient, setColor, setDeltaPosToSkeletonWhenOutOfFrustum, setDiffuse, setSpecular, setupAttenuation, setupSpotAngle, and ~CPointLightUser.

+


The documentation for this class was generated from the following files: + + + +
                                                                                                                                                                    +
+ + -- cgit v1.2.1