Starshatter_Open
Open source Starshatter engine
Main Page
Classes
Files
File List
File Members
All
Classes
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Scene.h
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: Scene.h
7
AUTHOR: John DiCamillo
8
9
10
OVERVIEW
11
========
12
A 3D Scene, basically a collection of 3D graphic objects
13
*/
14
15
#ifndef Scene_h
16
#define Scene_h
17
18
#include "
Types.h
"
19
#include "
Color.h
"
20
#include "
Geometry.h
"
21
#include "
List.h
"
22
23
// +--------------------------------------------------------------------+
24
25
class
Graphic
;
26
class
Light
;
27
28
// +--------------------------------------------------------------------+
29
30
class
Scene
31
{
32
public
:
33
static
const
char
*
TYPENAME
() {
return
"Scene"
; }
34
35
Scene
();
36
virtual
~Scene
();
37
38
void
AddBackground
(
Graphic
* g);
39
void
DelBackground
(
Graphic
* g);
40
void
AddForeground
(
Graphic
* g);
41
void
DelForeground
(
Graphic
* g);
42
void
AddGraphic
(
Graphic
* g);
43
void
DelGraphic
(
Graphic
* g);
44
void
AddSprite
(
Graphic
* g);
45
void
DelSprite
(
Graphic
* g);
46
47
void
AddLight
(
Light
* l);
48
void
DelLight
(
Light
* l);
49
50
List<Graphic>
&
Background
() {
return
background
; }
51
List<Graphic>
&
Foreground
() {
return
foreground
; }
52
List<Graphic>
&
Graphics
() {
return
graphics
; }
53
List<Graphic>
&
Sprites
() {
return
sprites
; }
54
List<Light>
&
Lights
() {
return
lights
; }
55
Color
Ambient
() {
return
ambient
; }
56
void
SetAmbient
(
Color
a) {
ambient
= a; }
57
58
virtual
void
Collect
();
59
60
virtual
bool
IsLightObscured
(
const
Point
& obj_pos,
61
const
Point
& light_pos,
62
double
obj_radius,
63
Point
* imp_point=0)
const
;
64
65
protected
:
66
List<Graphic>
background
;
67
List<Graphic>
foreground
;
68
List<Graphic>
graphics
;
69
List<Graphic>
sprites
;
70
List<Light>
lights
;
71
Color
ambient
;
72
};
73
74
// +--------------------------------------------------------------------+
75
76
#endif Scene_h
nGenEx
Scene.h
Generated on Tue Jun 5 2012 20:46:26 for Starshatter_Open by
1.8.1