From 8898ad9b25fca6afe2374d293a981db02a83d7e9 Mon Sep 17 00:00:00 2001 From: "FWoltermann@gmail.com" Date: Thu, 31 May 2012 14:46:27 +0000 Subject: Committing the documentation to svn to have it accessible online --- Doc/doxygen/html/_light_8cpp_source.html | 189 +++++++++++++++++++++++++++++++ 1 file changed, 189 insertions(+) create mode 100644 Doc/doxygen/html/_light_8cpp_source.html (limited to 'Doc/doxygen/html/_light_8cpp_source.html') diff --git a/Doc/doxygen/html/_light_8cpp_source.html b/Doc/doxygen/html/_light_8cpp_source.html new file mode 100644 index 0000000..a65beda --- /dev/null +++ b/Doc/doxygen/html/_light_8cpp_source.html @@ -0,0 +1,189 @@ + + + + + +Starshatter_Open: D:/SRC/StarshatterSVN/nGenEx/Light.cpp Source File + + + + + + + + + + + + + +
+
+ + + + + + +
+
Starshatter_Open +
+
Open source Starshatter engine
+
+
+ + + + + +
+
+ +
+
+
+ +
+ + + + +
+ +
+ +
+
+
Light.cpp
+
+
+Go to the documentation of this file.
1 /* Project nGenEx
+
2  Destroyer Studios LLC
+
3  Copyright © 1997-2004. All Rights Reserved.
+
4 
+
5  SUBSYSTEM: nGenEx.lib
+
6  FILE: Light.cpp
+
7  AUTHOR: John DiCamillo
+
8 
+
9 
+
10  OVERVIEW
+
11  ========
+
12  Dynamic Light Source
+
13 */
+
14 
+
15 #include "MemDebug.h"
+
16 #include "Light.h"
+
17 #include "Scene.h"
+
18 
+
19 // +--------------------------------------------------------------------+
+
20 
+
21 int Light::id_key = 1;
+
22 
+
23 // +--------------------------------------------------------------------+
+
24 
+
25 Light::Light(float l, float dl, int time)
+
26 : id(id_key++), type(LIGHT_POINT), life(time),
+
27 light(l), dldt(dl), color(255,255,255),
+
28 active(true), shadow(false), scene(0)
+
29 { }
+
30 
+
31 // +--------------------------------------------------------------------+
+
32 
+ +
34 { }
+
35 
+
36 // +--------------------------------------------------------------------+
+
37 
+
38 void
+ +
40 {
+
41  if (dldt < 1.0f)
+
42  light *= dldt;
+
43 
+
44  if (life > 0) life--;
+
45 }
+
46 
+
47 // +--------------------------------------------------------------------+
+
48 
+
49 void
+ +
51 {
+
52  if (scene)
+
53  scene->DelLight(this);
+
54 
+
55  delete this;
+
56 }
+
57 
+
58 // +--------------------------------------------------------------------+
+
59 
+
60 void
+
61 Light::MoveTo(const Point& dst)
+
62 {
+
63  //if (type != LIGHT_DIRECTIONAL)
+
64  loc = dst;
+
65 }
+
66 
+
67 void
+ +
69 {
+
70  if (type != LIGHT_DIRECTIONAL)
+
71  loc = loc - ref;
+
72 }
+
+
+ + + + -- cgit v1.1