Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/FICN/src/orxonox/objects/Mesh.cc @ 638

Last change on this file since 638 was 633, checked in by landauf, 17 years ago

added blinkies :D

File size: 599 bytes
Line 
1#include <sstream>
2
3#include "Mesh.h"
4#include "../Orxonox.h"
5
6namespace orxonox
7{
8    unsigned int Mesh::meshCounter_s = 0;
9
10    Mesh::Mesh()
11    {
12        this->entity_ = 0;
13    }
14
15    void Mesh::setMesh(const std::string& file)
16    {
17        std::ostringstream name;
18        name << (Mesh::meshCounter_s++);
19        this->entity_ = Orxonox::getSingleton()->getSceneManager()->createEntity("Mesh" + name.str(), file);
20    }
21
22    Mesh::~Mesh()
23    {
24        if (this->entity_)
25            Orxonox::getSingleton()->getSceneManager()->destroyEntity(this->entity_);
26    }
27}
Note: See TracBrowser for help on using the repository browser.