source: flair-dev/trunk/include/FlairSimulator/MeshSceneNode.h@ 12

Last change on this file since 12 was 9, checked in by Sanahuja Guillaume, 9 years ago

lic

File size: 2.1 KB
Line 
1// %flair:license{
2// This file is part of the Flair framework distributed under the
3// CECILL-C License, Version 1.0.
4// %flair:license}
5// created: 2012/08/22
6// filename: MeshSceneNode.h
7//
8// author: Guillaume Sanahuja
9// Copyright Heudiasyc UMR UTC/CNRS 7253
10//
11// version: $Id: $
12//
13// purpose: classe definissant un IMeshSceneNode
14//
15/*********************************************************************/
16
17#ifndef MESHSCENENODE_H
18#define MESHSCENENODE_H
19
20#include <IMeshSceneNode.h>
21
22namespace flair
23{
24namespace simulator
25{
26 class Model;
27
28 class MeshSceneNode : public irr::scene::IMeshSceneNode
29 {
30 public:
31 MeshSceneNode(Model* parent,irr::scene::IMesh* mesh,
32 const irr::core::vector3df& position = irr::core::vector3df(0,0,0),
33 const irr::core::vector3df& rotation = irr::core::vector3df(0,0,0),
34 irr::video::ITexture* texture=NULL, irr::s32 id=-1);
35
36 virtual void OnRegisterSceneNode(void);
37 virtual void render(void);
38 virtual const irr::core::aabbox3d<irr::f32>& getBoundingBox() const
39 {
40 return Box;
41 }
42 virtual irr::u32 getMaterialCount(void) const
43 {
44 return 1;
45 }
46 virtual irr::video::SMaterial& getMaterial(irr::u32 i);
47 virtual void setMesh( irr::scene::IMesh* ptr);
48 virtual irr::scene::IMesh* getMesh(void);
49 virtual void setReadOnlyMaterials(bool readonly);
50 virtual bool isReadOnlyMaterials(void) const
51 {
52 return false;
53 }
54 virtual irr::scene::IShadowVolumeSceneNode* addShadowVolumeSceneNode(const irr::scene::IMesh* shadowMesh=0,
55 irr::s32 id=-1, bool zfailmethod=true, irr::f32 infinity=1000.0f)
56 {
57 return NULL;
58 }
59
60 private:
61 irr::scene::IMesh *mesh;
62 irr::core::aabbox3d<irr::f32> Box;
63 irr::video::SMaterial Material;
64 };
65} // end namespace simulator
66} // end namespace flair
67
68#endif // MESHSCENENODE_H
Note: See TracBrowser for help on using the repository browser.