Sophie

Sophie

distrib > Mandriva > 10.2 > i586 > media > contrib > by-pkgid > 04e5d8c10ae76748689b4e7f48e0fa33 > files > 582

libogre5-devel-1.0.0-1mdk.i586.rpm

<html>
<head>
<title>OgreLight.h Source File - OGRE Documentation</title> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> 
<link type="text/css" rel="stylesheet" href="style.css">
</head>

<body>
<!-- Generated by Doxygen 1.3.6 -->
<div class="qindex"><a class="qindex" href="index.html">Main&nbsp;Page</a> | <a class="qindex" href="namespaces.html">Namespace List</a> | <a class="qindex" href="hierarchy.html">Class&nbsp;Hierarchy</a> | <a class="qindex" href="classes.html">Alphabetical&nbsp;List</a> | <a class="qindex" href="annotated.html">Class&nbsp;List</a> | <a class="qindex" href="files.html">File&nbsp;List</a> | <a class="qindex" href="namespacemembers.html">Namespace&nbsp;Members</a> | <a class="qindex" href="functions.html">Class&nbsp;Members</a> | <a class="qindex" href="globals.html">File&nbsp;Members</a> | <a class="qindex" href="pages.html">Related&nbsp;Pages</a></div>
<h1>OgreLight.h</h1><a href="OgreLight_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre>00001 <span class="comment">/*</span>
00002 <span class="comment">-----------------------------------------------------------------------------</span>
00003 <span class="comment">This source file is part of OGRE</span>
00004 <span class="comment">    (Object-oriented Graphics Rendering Engine)</span>
00005 <span class="comment">For the latest info, see http://www.ogre3d.org/</span>
00006 <span class="comment"></span>
00007 <span class="comment">Copyright (c) 2000-2005 The OGRE Team</span>
00008 <span class="comment">Also see acknowledgements in Readme.html</span>
00009 <span class="comment"></span>
00010 <span class="comment">This program is free software; you can redistribute it and/or modify it under</span>
00011 <span class="comment">the terms of the GNU Lesser General Public License as published by the Free Software</span>
00012 <span class="comment">Foundation; either version 2 of the License, or (at your option) any later</span>
00013 <span class="comment">version.</span>
00014 <span class="comment"></span>
00015 <span class="comment">This program is distributed in the hope that it will be useful, but WITHOUT</span>
00016 <span class="comment">ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS</span>
00017 <span class="comment">FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.</span>
00018 <span class="comment"></span>
00019 <span class="comment">You should have received a copy of the GNU Lesser General Public License along with</span>
00020 <span class="comment">this program; if not, write to the Free Software Foundation, Inc., 59 Temple</span>
00021 <span class="comment">Place - Suite 330, Boston, MA 02111-1307, USA, or go to</span>
00022 <span class="comment">http://www.gnu.org/copyleft/lesser.txt.</span>
00023 <span class="comment">-----------------------------------------------------------------------------</span>
00024 <span class="comment">*/</span>
00025 <span class="preprocessor">#ifndef _LIGHT_H__</span>
00026 <span class="preprocessor"></span><span class="preprocessor">#define _LIGHT_H__</span>
00027 <span class="preprocessor"></span>
00028 <span class="preprocessor">#include "<a class="code" href="OgrePrerequisites_8h.html">OgrePrerequisites.h</a>"</span>
00029 
00030 <span class="preprocessor">#include "<a class="code" href="OgreColourValue_8h.html">OgreColourValue.h</a>"</span>
00031 <span class="preprocessor">#include "<a class="code" href="OgreVector3_8h.html">OgreVector3.h</a>"</span>
00032 <span class="preprocessor">#include "<a class="code" href="OgreVector4_8h.html">OgreVector4.h</a>"</span>
00033 <span class="preprocessor">#include "<a class="code" href="OgreString_8h.html">OgreString.h</a>"</span>
00034 <span class="preprocessor">#include "<a class="code" href="OgreMovableObject_8h.html">OgreMovableObject.h</a>"</span>
00035 <span class="preprocessor">#include "<a class="code" href="OgrePlaneBoundedVolume_8h.html">OgrePlaneBoundedVolume.h</a>"</span>
00036 
00037 <span class="keyword">namespace </span>Ogre {
00038 
00039 
<a name="l00062"></a><a class="code" href="classOgre_1_1Light.html">00062</a>     <span class="keyword">class </span><a class="code" href="OgrePlatform_8h.html#a13">_OgreExport</a> Light : <span class="keyword">public</span> <a class="code" href="classOgre_1_1MovableObject.html">MovableObject</a>
00063     {
00064     <span class="keyword">public</span>:
<a name="l00066"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lighto0">00066</a>         <a class="code" href="namespaceOgre.html#a420">Real</a> tempSquareDist;
00067 
<a name="l00069"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightw3">00069</a>         <span class="keyword">enum</span> LightTypes
00070         {
00072             LT_POINT,
00074             LT_DIRECTIONAL,
00076             LT_SPOTLIGHT
00077         };
00078 
00081         Light();
00082 
00085         Light(<span class="keyword">const</span> <a class="code" href="namespaceOgre.html#a426">String</a>&amp; name);
00086 
00089         ~Light();
00090 
00093         <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#a426">String</a>&amp; getName(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00094 
00097         <span class="keywordtype">void</span> setType(LightTypes type);
00098 
00101         LightTypes getType(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00102 
00112         <span class="keywordtype">void</span> setDiffuseColour(<a class="code" href="namespaceOgre.html#a420">Real</a> red, <a class="code" href="namespaceOgre.html#a420">Real</a> green, <a class="code" href="namespaceOgre.html#a420">Real</a> blue);
00113 
00123         <span class="keywordtype">void</span> setDiffuseColour(<span class="keyword">const</span> <a class="code" href="classOgre_1_1ColourValue.html">ColourValue</a>&amp; colour);
00124 
00127         <span class="keyword">const</span> <a class="code" href="classOgre_1_1ColourValue.html">ColourValue</a>&amp; getDiffuseColour(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00128 
00138         <span class="keywordtype">void</span> setSpecularColour(<a class="code" href="namespaceOgre.html#a420">Real</a> red, <a class="code" href="namespaceOgre.html#a420">Real</a> green, <a class="code" href="namespaceOgre.html#a420">Real</a> blue);
00139 
00149         <span class="keywordtype">void</span> setSpecularColour(<span class="keyword">const</span> <a class="code" href="classOgre_1_1ColourValue.html">ColourValue</a>&amp; colour);
00150 
00153         <span class="keyword">const</span> <a class="code" href="classOgre_1_1ColourValue.html">ColourValue</a>&amp; getSpecularColour(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00154 
00174         <span class="keywordtype">void</span> setAttenuation(<a class="code" href="namespaceOgre.html#a420">Real</a> range, <a class="code" href="namespaceOgre.html#a420">Real</a> constant, <a class="code" href="namespaceOgre.html#a420">Real</a> linear, <a class="code" href="namespaceOgre.html#a420">Real</a> quadratic);
00175 
00178         <a class="code" href="namespaceOgre.html#a420">Real</a> getAttenuationRange(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00179 
00182         <a class="code" href="namespaceOgre.html#a420">Real</a> getAttenuationConstant(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00183 
00186         <a class="code" href="namespaceOgre.html#a420">Real</a> getAttenuationLinear(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00187 
00190         <a class="code" href="namespaceOgre.html#a420">Real</a> getAttenuationQuadric(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00191 
00198         <span class="keywordtype">void</span> setPosition(<a class="code" href="namespaceOgre.html#a420">Real</a> x, <a class="code" href="namespaceOgre.html#a420">Real</a> y, <a class="code" href="namespaceOgre.html#a420">Real</a> z);
00199 
00206         <span class="keywordtype">void</span> setPosition(<span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a>&amp; vec);
00207 
00212         <span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a>&amp; getPosition(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00213 
00220         <span class="keywordtype">void</span> setDirection(<a class="code" href="namespaceOgre.html#a420">Real</a> x, <a class="code" href="namespaceOgre.html#a420">Real</a> y, <a class="code" href="namespaceOgre.html#a420">Real</a> z);
00221 
00228         <span class="keywordtype">void</span> setDirection(<span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a>&amp; vec);
00229 
00234         <span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a>&amp; getDirection(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00235 
00244         <span class="keywordtype">void</span> setSpotlightRange(<span class="keyword">const</span> <a class="code" href="classOgre_1_1Radian.html">Radian</a>&amp; innerAngle, <span class="keyword">const</span> <a class="code" href="classOgre_1_1Radian.html">Radian</a>&amp; outerAngle, <a class="code" href="namespaceOgre.html#a420">Real</a> falloff = 1.0);
00245 <span class="preprocessor">#ifndef OGRE_FORCE_ANGLE_TYPES</span>
00246 <span class="preprocessor"></span>        <span class="keyword">inline</span> <span class="keywordtype">void</span> setSpotlightRange(<a class="code" href="namespaceOgre.html#a420">Real</a> innerAngle, <a class="code" href="namespaceOgre.html#a420">Real</a> outerAngle, <a class="code" href="namespaceOgre.html#a420">Real</a> falloff = 1.0) {
00247             setSpotlightRange ( <a class="code" href="classOgre_1_1Angle.html">Angle</a>(innerAngle), <a class="code" href="classOgre_1_1Angle.html">Angle</a>(outerAngle), falloff );
00248         }
00249 <span class="preprocessor">#endif//OGRE_FORCE_ANGLE_TYPES</span>
00250 <span class="preprocessor"></span>
00253         <span class="keyword">const</span> Radian&amp; getSpotlightInnerAngle(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00254 
00257         <span class="keyword">const</span> Radian&amp; getSpotlightOuterAngle(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00258 
00261         <a class="code" href="namespaceOgre.html#a420">Real</a> getSpotlightFalloff(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00262 
00264         <span class="keywordtype">void</span> _notifyCurrentCamera(<a class="code" href="classOgre_1_1Camera.html">Camera</a>* cam);
00265 
00267         <span class="keyword">const</span> AxisAlignedBox&amp; getBoundingBox(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00268 
00270         <span class="keywordtype">void</span> _updateRenderQueue(RenderQueue* queue);
00271 
00273         <span class="keyword">const</span> String&amp; getMovableType(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00274 
00276         <span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a>&amp; getDerivedPosition(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00277 
00279         <span class="keyword">const</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a>&amp; getDerivedDirection(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00280 
00286         <span class="keywordtype">void</span> setVisible(<span class="keywordtype">bool</span> visible);
00287 
<a name="l00289"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lighta34">00289</a>         <a class="code" href="namespaceOgre.html#a420">Real</a> getBoundingRadius(<span class="keywordtype">void</span>)<span class="keyword"> const </span>{ <span class="keywordflow">return</span> 0; <span class="comment">/* not visible */</span> }
00290 
00299         <a class="code" href="classOgre_1_1Vector4.html">Vector4</a> getAs4DVector(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
00300 
00310         <span class="keyword">const</span> <a class="code" href="classOgre_1_1PlaneBoundedVolume.html">PlaneBoundedVolume</a>&amp; _getNearClipVolume(<span class="keyword">const</span> <a class="code" href="classOgre_1_1Camera.html">Camera</a>* <span class="keyword">const</span> cam) <span class="keyword">const</span>;
00311 
00318         <span class="keyword">const</span> <a class="code" href="namespaceOgre.html#a411">PlaneBoundedVolumeList</a>&amp; _getFrustumClipVolumes(<span class="keyword">const</span> <a class="code" href="classOgre_1_1Camera.html">Camera</a>* <span class="keyword">const</span> cam) <span class="keyword">const</span>;
00319 
00320 
00321 
00322     <span class="keyword">private</span>:
00324         <span class="keywordtype">void</span> update(<span class="keywordtype">void</span>) <span class="keyword">const</span>;
<a name="l00325"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr0">00325</a>         <a class="code" href="namespaceOgre.html#a426">String</a> mName;
00326 
<a name="l00327"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr1">00327</a>         LightTypes mLightType;
<a name="l00328"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr2">00328</a>         <a class="code" href="classOgre_1_1Vector3.html">Vector3</a> mPosition;
<a name="l00329"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr3">00329</a>         <a class="code" href="classOgre_1_1ColourValue.html">ColourValue</a> mDiffuse;
<a name="l00330"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr4">00330</a>         <a class="code" href="classOgre_1_1ColourValue.html">ColourValue</a> mSpecular;
00331 
<a name="l00332"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr5">00332</a>         <a class="code" href="classOgre_1_1Vector3.html">Vector3</a> mDirection;
00333 
<a name="l00334"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr6">00334</a>         <a class="code" href="classOgre_1_1Radian.html">Radian</a> mSpotOuter;
<a name="l00335"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr7">00335</a>         <a class="code" href="classOgre_1_1Radian.html">Radian</a> mSpotInner;
<a name="l00336"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr8">00336</a>         <a class="code" href="namespaceOgre.html#a420">Real</a> mSpotFalloff;
<a name="l00337"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr9">00337</a>         <a class="code" href="namespaceOgre.html#a420">Real</a> mRange;
<a name="l00338"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr10">00338</a>         <a class="code" href="namespaceOgre.html#a420">Real</a> mAttenuationConst;
<a name="l00339"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr11">00339</a>         <a class="code" href="namespaceOgre.html#a420">Real</a> mAttenuationLinear;
<a name="l00340"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr12">00340</a>         <a class="code" href="namespaceOgre.html#a420">Real</a> mAttenuationQuad;
00341 
<a name="l00342"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr13">00342</a>         <span class="keyword">mutable</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a> mDerivedPosition;
<a name="l00343"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr14">00343</a>         <span class="keyword">mutable</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a> mDerivedDirection;
<a name="l00345"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr15">00345</a>         <span class="keyword">mutable</span> <a class="code" href="classOgre_1_1Quaternion.html">Quaternion</a> mLastParentOrientation;
<a name="l00346"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr16">00346</a>         <span class="keyword">mutable</span> <a class="code" href="classOgre_1_1Vector3.html">Vector3</a> mLastParentPosition;
00347 
<a name="l00349"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightv0">00349</a>         <span class="keyword">static</span> <a class="code" href="namespaceOgre.html#a426">String</a> msMovableType;
00350 
<a name="l00351"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr17">00351</a>         <span class="keyword">mutable</span> <a class="code" href="classOgre_1_1PlaneBoundedVolume.html">PlaneBoundedVolume</a> mNearClipVolume;
<a name="l00352"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr18">00352</a>         <span class="keyword">mutable</span> <a class="code" href="namespaceOgre.html#a411">PlaneBoundedVolumeList</a> mFrustumClipVolumes;
<a name="l00354"></a><a class="code" href="classOgre_1_1Light.html#Ogre_1_1Lightr19">00354</a>         <span class="keyword">mutable</span> <span class="keywordtype">bool</span> mLocalTransformDirty;
00355 
00356 
00357 
00358     };
00359 } <span class="comment">// Namespace</span>
00360 <span class="preprocessor">#endif</span>
</pre></div><p>
Copyright &copy; 2000-2005 by The OGRE Team<br />
Last modified Wed Feb 23 00:19:08 2005
</p>
</body>
</html>