ScummVM API documentation
light.h
1
/* ScummVM - Graphic Adventure Engine
2
*
3
* ScummVM is the legal property of its developers, whose names
4
* are too numerous to list here. Please refer to the COPYRIGHT
5
* file distributed with this source distribution.
6
*
7
* This program is free software: you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation, either version 3 of the License, or
10
* (at your option) any later version.
11
*
12
* This program is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
*
17
* You should have received a copy of the GNU General Public License
18
* along with this program. If not, see <http://www.gnu.org/licenses/>.
19
*
20
*/
21
22
#ifndef STARK_RESOURCES_LIGHT_H
23
#define STARK_RESOURCES_LIGHT_H
24
25
#include "common/str.h"
26
27
#include "math/vector3d.h"
28
29
#include "engines/stark/resources/object.h"
30
31
namespace
Stark
{
32
33
namespace
Formats {
34
class
XRCReadStream;
35
}
36
37
namespace
Gfx {
38
struct
LightEntry;
39
}
40
41
namespace
Resources {
42
46
class
Light
:
public
Object
{
47
public
:
48
static
const
Type::ResourceType TYPE = Type::kLight;
49
50
Light
(
Object
*parent, byte subType, uint16 index,
const
Common::String
&name);
51
~
Light
()
override
;
52
53
// Resource API
54
void
readData(
Formats::XRCReadStream
*stream)
override
;
55
void
onPostRead()
override
;
56
void
saveLoad(
ResourceSerializer
*serializer)
override
;
57
59
Gfx::LightEntry
*getLightEntry();
60
62
void
setColor(int32 red, int32 green, int32 blue);
63
65
void
setPosition(
const
Math::Vector3d &position);
66
67
protected
:
68
void
printData()
override
;
69
70
Math::Vector3d _color;
71
Math::Vector3d _position;
72
Math::Vector3d _direction;
73
float
_innerConeAngle;
74
float
_outerConeAngle;
75
float
_falloffNear;
76
float
_falloffFar;
77
float
_multiplier;
78
79
Gfx::LightEntry
*_lightEntry;
80
};
81
82
}
// End of namespace Resources
83
}
// End of namespace Stark
84
85
#endif // STARK_RESOURCES_LIGHT_H
Common::String
Definition:
str.h:59
Stark::Gfx::LightEntry
Definition:
renderentry.h:44
Stark
Definition:
console.h:27
Stark::Resources::Object
Definition:
object.h:143
Stark::Resources::Light
Definition:
light.h:46
Stark::Formats::XRCReadStream
Definition:
xrc.h:45
Stark::ResourceSerializer
Definition:
stateprovider.h:51
engines
stark
resources
light.h
Generated on Sat Aug 31 2024 09:09:01 for ScummVM API documentation by
1.8.13