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/u__light_8h-source.html | 201 +++++++++++++++++++++++++++++++ 1 file changed, 201 insertions(+) create mode 100644 docs/doxygen/nel/u__light_8h-source.html (limited to 'docs/doxygen/nel/u__light_8h-source.html') diff --git a/docs/doxygen/nel/u__light_8h-source.html b/docs/doxygen/nel/u__light_8h-source.html new file mode 100644 index 00000000..65e72fc1 --- /dev/null +++ b/docs/doxygen/nel/u__light_8h-source.html @@ -0,0 +1,201 @@ + + + + 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  
+

u_light.h

Go to the documentation of this file.
00001 
+00007 /* Copyright, 2001 Nevrax Ltd.
+00008  *
+00009  * This file is part of NEVRAX NEL.
+00010  * NEVRAX NEL is free software; you can redistribute it and/or modify
+00011  * it under the terms of the GNU General Public License as published by
+00012  * the Free Software Foundation; either version 2, or (at your option)
+00013  * any later version.
+00014 
+00015  * NEVRAX NEL is distributed in the hope that it will be useful, but
+00016  * WITHOUT ANY WARRANTY; without even the implied warranty of
+00017  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+00018  * General Public License for more details.
+00019 
+00020  * You should have received a copy of the GNU General Public License
+00021  * along with NEVRAX NEL; see the file COPYING. If not, write to the
+00022  * Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
+00023  * MA 02111-1307, USA.
+00024  */
+00025 
+00026 #ifndef NL_U_LIGHT_H
+00027 #define NL_U_LIGHT_H
+00028 
+00029 #include "nel/misc/types_nl.h"
+00030 #include "nel/misc/rgba.h"
+00031 #include "nel/misc/vector.h"
+00032 
+00033 
+00034 namespace NL3D 
+00035 {
+00036 
+00037 // ***************************************************************************
+00044 class ULight
+00045 {
+00046 public:
+00047         // Three modes for the light
+00048         enum TLightMode 
+00049         { 
+00050                 // The light is directional.
+00051                 DirectionalLight, 
+00052                 
+00053                 // The light is a point.
+00054                 PointLight, 
+00055 
+00056                 // The light is a spotlight with a cone.
+00057                 SpotLight 
+00058         };
+00059 
+00063         static  ULight  *createLight ();
+00064 
+00066 
+00067 
+00069         virtual void setupDirectional (const NLMISC::CRGBA& ambiant, const NLMISC::CRGBA& diffuse, const NLMISC::CRGBA& specular, const NLMISC::CVector& direction,
+00070                                                         float constant=1, float linear=0, float quadratic=0) = 0;
+00071         
+00073         virtual void setupPointLight (const NLMISC::CRGBA& ambiant, const NLMISC::CRGBA& diffuse, const NLMISC::CRGBA& specular, const NLMISC::CVector& position, 
+00074                                                 const NLMISC::CVector& direction, float constant=1, float linear=0, float quadratic=0) = 0;
+00075 
+00077         virtual void setupSpotLight (const NLMISC::CRGBA& ambiant, const NLMISC::CRGBA& diffuse, const NLMISC::CRGBA& specular, const NLMISC::CVector& position, 
+00078                                                 const NLMISC::CVector& direction, float exponent, float cutoff, float constant=1, float linear=0, float quadratic=0) = 0;
+00079 
+00086         virtual void setupAttenuation (float farAttenuationBegin, float farAttenuationEnd) = 0;
+00087 
+00094         virtual void setNoAttenuation () = 0;
+00095 
+00102         virtual void setupSpotExponent (float hotSpotAngle) = 0;
+00103 
+00105 
+00106 
+00108 
+00109 
+00113         virtual void setMode (ULight::TLightMode mode) = 0;
+00114         
+00118         virtual void setAmbiant (const NLMISC::CRGBA& ambiant) = 0;
+00119 
+00123         virtual void setDiffuse (const NLMISC::CRGBA& diffuse) = 0;
+00124 
+00128         virtual void setSpecular (const NLMISC::CRGBA& specular) = 0;
+00129 
+00133         virtual void setPosition (const NLMISC::CVector& position) = 0;
+00134 
+00138         virtual void setDirection (const NLMISC::CVector& direction) = 0;
+00139 
+00143         virtual void setExponent (float exponent) = 0;
+00144 
+00148         virtual void setCutoff (float cutoff) = 0;
+00149 
+00157         virtual void setConstantAttenuation (float constant) = 0;
+00158 
+00166         virtual void setLinearAttenuation (float linear) = 0;
+00167 
+00175         virtual void setQuadraticAttenuation (float quadratic) = 0;
+00176 
+00178 
+00180 
+00181 
+00185         virtual ULight::TLightMode getMode () const = 0;
+00186 
+00190         virtual NLMISC::CRGBA getAmbiant () const = 0;
+00191 
+00195         virtual NLMISC::CRGBA getDiffuse () const = 0;
+00196 
+00200         virtual NLMISC::CRGBA getSpecular () const = 0;
+00201 
+00205         virtual NLMISC::CVector getPosition () const = 0;
+00206 
+00210         virtual NLMISC::CVector getDirection () const = 0;
+00211 
+00215         virtual float getExponent () const = 0;
+00216 
+00220         virtual float getCutoff () const = 0;
+00221 
+00229         virtual float getConstantAttenuation () const = 0;
+00230 
+00238         virtual float getLinearAttenuation () const = 0;
+00239 
+00247         virtual float getQuadraticAttenuation () const = 0;
+00248 
+00250 };
+00251 
+00252 
+00253 } // NL3D
+00254 
+00255 
+00256 #endif // NL_U_LIGHT_H
+00257 
+00258 /* End of u_light.h */
+
+ + +
                                                                                                                                                                    +
+ + -- cgit v1.2.1