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>
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
|
Models * | m_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 |
Member Function Documentation
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.
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.
Member Data Documentation
pointer to hold the camera
Definition at line 79 of file Map.h.
pointer to hold model
Definition at line 83 of file Map.h.
pointer to hold the positions of the nodes without obstacles
Definition at line 99 of file Map.h.
variable to hold the positions of the obstacles
Definition at line 95 of file Map.h.
variable to hold the texture
Definition at line 75 of file Map.h.
variable to hold the transformation information
Definition at line 91 of file Map.h.
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: