aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/libraries/irrlicht-1.8/source/Irrlicht/CMeshSceneNode.h
diff options
context:
space:
mode:
authorDavid Walter Seikel2013-01-13 18:54:10 +1000
committerDavid Walter Seikel2013-01-13 18:54:10 +1000
commit959831f4ef5a3e797f576c3de08cd65032c997ad (patch)
treee7351908be5995f0b325b2ebeaa02d5a34b82583 /libraries/irrlicht-1.8/source/Irrlicht/CMeshSceneNode.h
parentAdd info about changes to Irrlicht. (diff)
downloadSledjHamr-959831f4ef5a3e797f576c3de08cd65032c997ad.zip
SledjHamr-959831f4ef5a3e797f576c3de08cd65032c997ad.tar.gz
SledjHamr-959831f4ef5a3e797f576c3de08cd65032c997ad.tar.bz2
SledjHamr-959831f4ef5a3e797f576c3de08cd65032c997ad.tar.xz
Remove damned ancient DOS line endings from Irrlicht. Hopefully I did not go overboard.
Diffstat (limited to 'libraries/irrlicht-1.8/source/Irrlicht/CMeshSceneNode.h')
-rw-r--r--libraries/irrlicht-1.8/source/Irrlicht/CMeshSceneNode.h206
1 files changed, 103 insertions, 103 deletions
diff --git a/libraries/irrlicht-1.8/source/Irrlicht/CMeshSceneNode.h b/libraries/irrlicht-1.8/source/Irrlicht/CMeshSceneNode.h
index 513664f..6705330 100644
--- a/libraries/irrlicht-1.8/source/Irrlicht/CMeshSceneNode.h
+++ b/libraries/irrlicht-1.8/source/Irrlicht/CMeshSceneNode.h
@@ -1,103 +1,103 @@
1// Copyright (C) 2002-2012 Nikolaus Gebhardt 1// Copyright (C) 2002-2012 Nikolaus Gebhardt
2// This file is part of the "Irrlicht Engine". 2// This file is part of the "Irrlicht Engine".
3// For conditions of distribution and use, see copyright notice in irrlicht.h 3// For conditions of distribution and use, see copyright notice in irrlicht.h
4 4
5#ifndef __C_MESH_SCENE_NODE_H_INCLUDED__ 5#ifndef __C_MESH_SCENE_NODE_H_INCLUDED__
6#define __C_MESH_SCENE_NODE_H_INCLUDED__ 6#define __C_MESH_SCENE_NODE_H_INCLUDED__
7 7
8#include "IMeshSceneNode.h" 8#include "IMeshSceneNode.h"
9#include "IMesh.h" 9#include "IMesh.h"
10 10
11namespace irr 11namespace irr
12{ 12{
13namespace scene 13namespace scene
14{ 14{
15 15
16 class CMeshSceneNode : public IMeshSceneNode 16 class CMeshSceneNode : public IMeshSceneNode
17 { 17 {
18 public: 18 public:
19 19
20 //! constructor 20 //! constructor
21 CMeshSceneNode(IMesh* mesh, ISceneNode* parent, ISceneManager* mgr, s32 id, 21 CMeshSceneNode(IMesh* mesh, ISceneNode* parent, ISceneManager* mgr, s32 id,
22 const core::vector3df& position = core::vector3df(0,0,0), 22 const core::vector3df& position = core::vector3df(0,0,0),
23 const core::vector3df& rotation = core::vector3df(0,0,0), 23 const core::vector3df& rotation = core::vector3df(0,0,0),
24 const core::vector3df& scale = core::vector3df(1.0f, 1.0f, 1.0f)); 24 const core::vector3df& scale = core::vector3df(1.0f, 1.0f, 1.0f));
25 25
26 //! destructor 26 //! destructor
27 virtual ~CMeshSceneNode(); 27 virtual ~CMeshSceneNode();
28 28
29 //! frame 29 //! frame
30 virtual void OnRegisterSceneNode(); 30 virtual void OnRegisterSceneNode();
31 31
32 //! renders the node. 32 //! renders the node.
33 virtual void render(); 33 virtual void render();
34 34
35 //! returns the axis aligned bounding box of this node 35 //! returns the axis aligned bounding box of this node
36 virtual const core::aabbox3d<f32>& getBoundingBox() const; 36 virtual const core::aabbox3d<f32>& getBoundingBox() const;
37 37
38 //! returns the material based on the zero based index i. To get the amount 38 //! returns the material based on the zero based index i. To get the amount
39 //! of materials used by this scene node, use getMaterialCount(). 39 //! of materials used by this scene node, use getMaterialCount().
40 //! This function is needed for inserting the node into the scene hirachy on a 40 //! This function is needed for inserting the node into the scene hirachy on a
41 //! optimal position for minimizing renderstate changes, but can also be used 41 //! optimal position for minimizing renderstate changes, but can also be used
42 //! to directly modify the material of a scene node. 42 //! to directly modify the material of a scene node.
43 virtual video::SMaterial& getMaterial(u32 i); 43 virtual video::SMaterial& getMaterial(u32 i);
44 44
45 //! returns amount of materials used by this scene node. 45 //! returns amount of materials used by this scene node.
46 virtual u32 getMaterialCount() const; 46 virtual u32 getMaterialCount() const;
47 47
48 //! Writes attributes of the scene node. 48 //! Writes attributes of the scene node.
49 virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const; 49 virtual void serializeAttributes(io::IAttributes* out, io::SAttributeReadWriteOptions* options=0) const;
50 50
51 //! Reads attributes of the scene node. 51 //! Reads attributes of the scene node.
52 virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0); 52 virtual void deserializeAttributes(io::IAttributes* in, io::SAttributeReadWriteOptions* options=0);
53 53
54 //! Returns type of the scene node 54 //! Returns type of the scene node
55 virtual ESCENE_NODE_TYPE getType() const { return ESNT_MESH; } 55 virtual ESCENE_NODE_TYPE getType() const { return ESNT_MESH; }
56 56
57 //! Sets a new mesh 57 //! Sets a new mesh
58 virtual void setMesh(IMesh* mesh); 58 virtual void setMesh(IMesh* mesh);
59 59
60 //! Returns the current mesh 60 //! Returns the current mesh
61 virtual IMesh* getMesh(void) { return Mesh; } 61 virtual IMesh* getMesh(void) { return Mesh; }
62 62
63 //! Creates shadow volume scene node as child of this node 63 //! Creates shadow volume scene node as child of this node
64 //! and returns a pointer to it. 64 //! and returns a pointer to it.
65 virtual IShadowVolumeSceneNode* addShadowVolumeSceneNode(const IMesh* shadowMesh, 65 virtual IShadowVolumeSceneNode* addShadowVolumeSceneNode(const IMesh* shadowMesh,
66 s32 id, bool zfailmethod=true, f32 infinity=10000.0f); 66 s32 id, bool zfailmethod=true, f32 infinity=10000.0f);
67 67
68 //! Sets if the scene node should not copy the materials of the mesh but use them in a read only style. 68 //! Sets if the scene node should not copy the materials of the mesh but use them in a read only style.
69 /* In this way it is possible to change the materials a mesh causing all mesh scene nodes 69 /* In this way it is possible to change the materials a mesh causing all mesh scene nodes
70 referencing this mesh to change too. */ 70 referencing this mesh to change too. */
71 virtual void setReadOnlyMaterials(bool readonly); 71 virtual void setReadOnlyMaterials(bool readonly);
72 72
73 //! Returns if the scene node should not copy the materials of the mesh but use them in a read only style 73 //! Returns if the scene node should not copy the materials of the mesh but use them in a read only style
74 virtual bool isReadOnlyMaterials() const; 74 virtual bool isReadOnlyMaterials() const;
75 75
76 //! Creates a clone of this scene node and its children. 76 //! Creates a clone of this scene node and its children.
77 virtual ISceneNode* clone(ISceneNode* newParent=0, ISceneManager* newManager=0); 77 virtual ISceneNode* clone(ISceneNode* newParent=0, ISceneManager* newManager=0);
78 78
79 //! Removes a child from this scene node. 79 //! Removes a child from this scene node.
80 //! Implemented here, to be able to remove the shadow properly, if there is one, 80 //! Implemented here, to be able to remove the shadow properly, if there is one,
81 //! or to remove attached childs. 81 //! or to remove attached childs.
82 virtual bool removeChild(ISceneNode* child); 82 virtual bool removeChild(ISceneNode* child);
83 83
84 protected: 84 protected:
85 85
86 void copyMaterials(); 86 void copyMaterials();
87 87
88 core::array<video::SMaterial> Materials; 88 core::array<video::SMaterial> Materials;
89 core::aabbox3d<f32> Box; 89 core::aabbox3d<f32> Box;
90 video::SMaterial ReadOnlyMaterial; 90 video::SMaterial ReadOnlyMaterial;
91 91
92 IMesh* Mesh; 92 IMesh* Mesh;
93 IShadowVolumeSceneNode* Shadow; 93 IShadowVolumeSceneNode* Shadow;
94 94
95 s32 PassCount; 95 s32 PassCount;
96 bool ReadOnlyMaterials; 96 bool ReadOnlyMaterials;
97 }; 97 };
98 98
99} // end namespace scene 99} // end namespace scene
100} // end namespace irr 100} // end namespace irr
101 101
102#endif 102#endif
103 103