Map Class Reference

this is the class for map which sorts the obstacles in the environment and draws objects in that position More...

#include <Map.h>

Collaboration diagram for Map:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 Map (ngl::Camera *_cam, Models *_model, std::vector< ngl::Transformation > _trans, std::vector< ngl::Vec3 > _obstacles)
 ctor
 ~Map ()
 dtor
void draw (ngl::TransformStack *_tx, std::string _type, bool _box)
 draw the scene
void createMap ()
 method to create and load map
void drawMaze (ngl::TransformStack *_tStack, bool _box)
 draw the maze
void drawObstacles (ngl::TransformStack *_tStack, bool _box)
 draw the maze
void setObstacles (const std::vector< ngl::Vec3 > _obstacles)
 method to set the4 obstacle positions
void setNoObstacles (const std::vector< ngl::Vec3 > _NoObstacles)
 method to set the no obstacle position
ngl::Vec3 getInitialPosition ()
 method to generate a random initial index for a random node position

Private Attributes

GLuint m_texID1
 variable to hold the texture
ngl::Camera * m_camera
 pointer to hold the camera
Modelsm_model
 pointer to hold model
std::string m_type
 variable to hold the string type
std::vector< ngl::Transformation > m_trans
 variable to hold the transformation information
std::vector< ngl::Vec3 > m_obstacles
 variable to hold the positions of the obstacles
std::vector< ngl::Vec3 > m_NoObstacles
 pointer to hold the positions of the nodes without obstacles

Detailed Description

this is the class for map which sorts the obstacles in the environment and draws objects in that position

Definition at line 19 of file Map.h.


Constructor & Destructor Documentation

Map::Map ( ngl::Camera *  _cam,
Models _model,
std::vector< ngl::Transformation >  _trans,
std::vector< ngl::Vec3 >  _obstacles 
)

ctor

Parameters:
[in] the camera
[in] the model variable for meshes
[in] the transformation infromation for the obstacles
[in] the vector with positions of obstacles
Map::~Map (  ) 

dtor


Member Function Documentation

void Map::createMap (  ) 

method to create and load map

void Map::draw ( ngl::TransformStack *  _tx,
std::string  _type,
bool  _box 
)

draw the scene

Parameters:
[in] _tx the transform stack of the current scene
[in] _cam the current camera
[in] _box bool to draw the box
void Map::drawMaze ( ngl::TransformStack *  _tStack,
bool  _box 
)

draw the maze

Parameters:
[in] _tx the transform stack of the current scene
[in] _box bool to draw the box
void Map::drawObstacles ( ngl::TransformStack *  _tStack,
bool  _box 
)

draw the maze

Parameters:
[in] _tx the transform stack of the current scene
[in] _box bool to draw the box
ngl::Vec3 Map::getInitialPosition (  ) 

method to generate a random initial index for a random node position

void Map::setNoObstacles ( const std::vector< ngl::Vec3 >  _NoObstacles  )  [inline]

method to set the no obstacle position

Definition at line 64 of file Map.h.

References m_NoObstacles.

00064 {m_NoObstacles = _NoObstacles;std::cout<<"the No obstacles "<<m_NoObstacles.size()<<std::endl;}

void Map::setObstacles ( const std::vector< ngl::Vec3 >  _obstacles  )  [inline]

method to set the4 obstacle positions

Definition at line 60 of file Map.h.

References m_obstacles.

00060 {m_obstacles = _obstacles;std::cout<<"the obstacles "<<m_obstacles.size()<<std::endl;}


Member Data Documentation

ngl::Camera* Map::m_camera [private]

pointer to hold the camera

Definition at line 79 of file Map.h.

Models* Map::m_model [private]

pointer to hold model

Definition at line 83 of file Map.h.

std::vector<ngl::Vec3> Map::m_NoObstacles [private]

pointer to hold the positions of the nodes without obstacles

Definition at line 99 of file Map.h.

std::vector<ngl::Vec3> Map::m_obstacles [private]

variable to hold the positions of the obstacles

Definition at line 95 of file Map.h.

GLuint Map::m_texID1 [private]

variable to hold the texture

Definition at line 75 of file Map.h.

std::vector<ngl::Transformation> Map::m_trans [private]

variable to hold the transformation information

Definition at line 91 of file Map.h.

std::string Map::m_type [private]

variable to hold the string type

Definition at line 87 of file Map.h.


The documentation for this class was generated from the following file:

Generated on 16 Aug 2013 for Multi-AgentSystem by  doxygen 1.6.1