Irrlicht 3D Engine
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
ITerrainSceneNode.h
Go to the documentation of this file.
1
// Copyright (C) 2002-2012 Nikolaus Gebhardt
2
// This file is part of the "Irrlicht Engine".
3
// For conditions of distribution and use, see copyright notice in irrlicht.h
4
5
// The code for the TerrainSceneNode is based on the terrain renderer by
6
// Soconne and the GeoMipMapSceneNode developed by Spintz. They made their
7
// code available for Irrlicht and allowed it to be distributed under this
8
// licence. I only modified some parts. A lot of thanks go to them.
9
10
#ifndef __I_TERRAIN_SCENE_NODE_H__
11
#define __I_TERRAIN_SCENE_NODE_H__
12
13
#include "
ETerrainElements.h
"
14
#include "
ISceneNode.h
"
15
#include "
IDynamicMeshBuffer.h
"
16
#include "
irrArray.h
"
17
18
namespace
irr
19
{
20
namespace
io
21
{
22
class
IReadFile;
23
}
// end namespace io
24
namespace
scene
25
{
26
class
IMesh;
27
29
49
class
ITerrainSceneNode
:
public
ISceneNode
50
{
51
public
:
53
ITerrainSceneNode
(
ISceneNode
* parent,
ISceneManager
* mgr,
s32
id
,
54
const
core::vector3df
& position =
core::vector3df
(0.0f, 0.0f, 0.0f),
55
const
core::vector3df
& rotation =
core::vector3df
(0.0f, 0.0f, 0.0f),
56
const
core::vector3df
& scale =
core::vector3df
(1.0f, 1.0f, 1.0f) )
57
:
ISceneNode
(parent, mgr, id, position, rotation, scale) {}
58
60
61
virtual
const
core::aabbox3d<f32>
&
getBoundingBox
()
const
=0;
62
64
65
virtual
const
core::aabbox3d<f32>
&
getBoundingBox
(
s32
patchX,
s32
patchZ)
const
=0;
66
68
69
virtual
u32
getIndexCount
()
const
=0;
70
72
73
virtual
IMesh
*
getMesh
() =0;
74
76
virtual
IMeshBuffer
*
getRenderBuffer
() =0;
77
78
80
82
virtual
void
getMeshBufferForLOD
(
IDynamicMeshBuffer
& mb,
s32
LOD=0)
const
=0;
83
85
93
virtual
s32
getIndicesForPatch
(
core::array<u32>
& indices,
94
s32
patchX,
s32
patchZ,
s32
LOD=0) =0;
95
97
100
virtual
s32
getCurrentLODOfPatches
(
core::array<s32>
& LODs)
const
=0;
101
103
106
virtual
void
setLODOfPatch
(
s32
patchX,
s32
patchZ,
s32
LOD=0) =0;
107
109
virtual
const
core::vector3df
&
getTerrainCenter
()
const
=0;
110
112
virtual
f32
getHeight
(
f32
x,
f32
y)
const
=0;
113
115
117
virtual
void
setCameraMovementDelta
(
f32
delta) =0;
118
120
122
virtual
void
setCameraRotationDelta
(
f32
delta) =0;
123
125
126
virtual
void
setDynamicSelectorUpdate
(
bool
bVal) =0;
127
129
135
virtual
bool
overrideLODDistance
(
s32
LOD,
f64
newDistance) =0;
136
138
147
virtual
void
scaleTexture
(
f32
scale = 1.0f,
f32
scale2=0.0f) =0;
148
150
155
virtual
bool
loadHeightMap
(
io::IReadFile
* file,
156
video::SColor
vertexColor=
video::SColor
(255,255,255,255),
157
s32
smoothFactor=0) =0;
158
160
170
virtual
bool
loadHeightMapRAW
(
io::IReadFile
* file,
s32
bitsPerPixel=16,
171
bool
signedData=
false
,
bool
floatVals=
false
,
s32
width=0,
172
video::SColor
vertexColor=
video::SColor
(255,255,255,255),
173
s32
smoothFactor=0) =0;
174
175
};
176
177
}
// end namespace scene
178
}
// end namespace irr
179
180
181
#endif // __I_TERRAIN_SCENE_NODE_H__
182
Irrlicht Engine
Documentation © 2003-2012 by Nikolaus Gebhardt. Generated on Tue Apr 7 2020 19:33:42 for Irrlicht 3D Engine by
Doxygen
1.8.1.2