Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

light.h

Go to the documentation of this file.
00001 /* ***********************************************************************************
00002         Writer:         Sebastien Bloc
00003         Copyright:      2003-2004
00004         eMail:          sebastien.bloc@free.fr
00005         URL:            http://mignonsoft.free.fr
00006 
00007         This program is free software; you can redistribute it and/or
00008         modify it under the terms of the GNU General Public License
00009         as published by the Free Software Foundation; either version 2
00010         of the License, or (at your option) any later version.
00011 
00012         This program is distributed in the hope that it will be useful,
00013         but WITHOUT ANY WARRANTY; without even the implied warranty of
00014         MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015         GNU General Public License for more details.
00016 http://www.gnu.org/copyleft/gpl.html    
00017 *********************************************************************************** */
00018 
00023 #ifndef INCLUDE_3D_LIGHT_H
00024 #define INCLUDE_3D_LIGHT_H
00025 
00026 #include "3d.h"
00027 #include "variable.h"
00028 #include "material.h"
00029 #include "coordonate.h"
00030 
00041 class Light
00042 {
00043 public: 
00044         static BOOL useLighting;
00045         int id;
00046         BOOL isEnable;
00047         Enabling<GLfloat> cutoff;
00048         Enabling<GLfloat> exponent;
00049         Enabling<GLfloat> attenuationCst;
00050         Enabling<GLfloat> attenuationLin;
00051         Enabling<GLfloat> attenuationQuad;
00052 
00053 public:
00054         Material material;
00055         Coordonate<GLfloat> direction;
00056         Coordonate<GLfloat> position;
00057 
00058         static void SetLighting(BOOL set);
00059         static BOOL IsLighting();
00060         Light();
00061         Light(int _id);
00062         void Zero();
00063         void operator=(Light &source);
00064         void Enable(BOOL active=-1); 
00065         BOOL IsEnabled();
00066         void Toggle();
00067         void Use();
00068 };
00069 
00070 
00071 #endif

Generated on Fri Aug 20 19:19:46 2004 for 3d Controls by doxygen 1.3.6