Changeset 4836 in orxonox.OLD for orxonox/trunk/src/lib/graphics
- Timestamp:
- Jul 12, 2005, 12:33:16 AM (20 years ago)
- Location:
- orxonox/trunk/src/lib/graphics
- Files:
-
- 25 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/lib/graphics/graphics_engine.cc
r4835 r4836 30 30 31 31 /** 32 \briefstandard constructor33 \todo this constructor is not jet implemented - do it32 * standard constructor 33 @todo this constructor is not jet implemented - do it 34 34 */ 35 35 GraphicsEngine::GraphicsEngine () … … 48 48 49 49 /** 50 \briefThe Pointer to this GraphicsEngine50 * The Pointer to this GraphicsEngine 51 51 */ 52 52 GraphicsEngine* GraphicsEngine::singletonRef = NULL; 53 53 54 54 /** 55 \briefdestructs the graphicsEngine.55 * destructs the graphicsEngine. 56 56 */ 57 57 GraphicsEngine::~GraphicsEngine () … … 103 103 104 104 /** 105 \briefinitializes the Video for openGL.105 * initializes the Video for openGL. 106 106 107 107 This has to be done only once when starting orxonox. … … 170 170 171 171 /** 172 \briefSets the GL-attributes172 * Sets the GL-attributes 173 173 */ 174 174 int GraphicsEngine::setGLattribs() … … 192 192 193 193 /** 194 \briefsets the Resolution of the Screen to display the Graphics to.195 \param width The width of the window196 \param height The height of the window197 \param bpp bits per pixel194 * sets the Resolution of the Screen to display the Graphics to. 195 * @param width The width of the window 196 * @param height The height of the window 197 * @param bpp bits per pixel 198 198 */ 199 199 int GraphicsEngine::setResolution(int width, int height, int bpp) … … 212 212 213 213 /** 214 \briefsets Fullscreen mode215 \param fullscreen true if fullscreen, false if windowed214 * sets Fullscreen mode 215 * @param fullscreen true if fullscreen, false if windowed 216 216 */ 217 217 void GraphicsEngine::setFullscreen(bool fullscreen) … … 225 225 226 226 /** 227 \briefsets the background color228 \param red the red part of the background229 \param blue the blue part of the background230 \param green the green part of the background231 \param alpha the alpha part of the background227 * sets the background color 228 * @param red the red part of the background 229 * @param blue the blue part of the background 230 * @param green the green part of the background 231 * @param alpha the alpha part of the background 232 232 */ 233 233 void GraphicsEngine::setBackgroundColor(GLclampf red, GLclampf green, GLclampf blue, GLclampf alpha) … … 238 238 239 239 /** 240 \briefSignalhandler, for when the resolution has changed241 \param resizeInfo SDL information about the size of the new screen size240 * Signalhandler, for when the resolution has changed 241 * @param resizeInfo SDL information about the size of the new screen size 242 242 */ 243 243 int GraphicsEngine::resolutionChanged(const SDL_ResizeEvent& resizeInfo) … … 308 308 309 309 /** 310 \briefentering 2D Mode310 * entering 2D Mode 311 311 312 312 this is a GL-Projection-mode, that is orthogonal, for placing the font in fron of everything else … … 341 341 342 342 /** 343 \briefleaves the 2DMode again also \see Font::enter2DMode()343 * leaves the 2DMode again also \see Font::enter2DMode() 344 344 */ 345 345 void GraphicsEngine::leave2DMode() … … 355 355 356 356 /** 357 \briefstores the GL_matrices357 * stores the GL_matrices 358 358 */ 359 359 void GraphicsEngine::storeMatrices() … … 374 374 375 375 /** 376 \briefoutputs all the Fullscreen modes.376 * outputs all the Fullscreen modes. 377 377 */ 378 378 void GraphicsEngine::listModes() … … 400 400 401 401 /** 402 \briefticks the Text403 \param dt the time passed402 * ticks the Text 403 * @param dt the time passed 404 404 */ 405 405 void GraphicsEngine::tick(float dt) … … 426 426 427 427 /** 428 \briefdisplays the Frames per second429 \param display if the text should be displayed430 431 \todo this is dangerous428 * displays the Frames per second 429 * @param display if the text should be displayed 430 431 @todo this is dangerous 432 432 */ 433 433 void GraphicsEngine::displayFPS(bool display) … … 453 453 /** 454 454 \brief processes the events for orxonox main class 455 \param the event to handle455 * @param the event to handle 456 456 */ 457 457 void GraphicsEngine::process(const Event &event) -
orxonox/trunk/src/lib/graphics/graphics_engine.h
r4834 r4836 2 2 \file graphics_engine.h 3 3 4 \briefdefines a Interface between orxonox and graphical input4 * defines a Interface between orxonox and graphical input 5 5 6 6 handles graphical SDL-initialisation, textures, resolutions, and so on … … 27 27 public: 28 28 virtual ~GraphicsEngine(); 29 /** \returns a Pointer to the only object of this Class */29 /** @returns a Pointer to the only object of this Class */ 30 30 inline static GraphicsEngine* getInstance() { if (!singletonRef) singletonRef = new GraphicsEngine(); return singletonRef; }; 31 31 … … 40 40 41 41 42 /** \returns the x resolution */42 /** @returns the x resolution */ 43 43 inline int getResolutionX() const { return this->resolutionX; }; 44 /** \returns the y resolution */44 /** @returns the y resolution */ 45 45 inline int getResolutionY() const { return this->resolutionY; }; 46 /** \returns the Bits Per Pixel */46 /** @returns the Bits Per Pixel */ 47 47 inline int getbbp() const { return this->bitsPerPixel; }; 48 48 -
orxonox/trunk/src/lib/graphics/importer/abstract_model.h
r4809 r4836 16 16 /*! 17 17 \file abstract_model.h 18 \briefDefinition of an abstract model. containing all needed for other model18 * Definition of an abstract model. containing all needed for other model 19 19 */ 20 20 -
orxonox/trunk/src/lib/graphics/importer/array.h
r4799 r4836 36 36 void addEntry(T entry0, T entry1, T entry2); 37 37 38 /** \returns The array */38 /** @returns The array */ 39 39 inline const T* getArray () const { return this->array; }; 40 /** \returns The Count of entries in the Array*/40 /** * @returns The Count of entries in the Array*/ 41 41 inline unsigned int getCount()const { return this->entryCount; }; 42 42 inline int getIndex(T* entry) const; … … 61 61 62 62 /** 63 \briefcreates a new Array63 * creates a new Array 64 64 */ 65 65 template<class T> … … 75 75 76 76 /** 77 \briefdeletes an Array.77 * deletes an Array. 78 78 It does this by first deleting all the array-entries, and then delete the array[] itself 79 79 */ … … 95 95 96 96 /** 97 \brieffinalizes an array.97 * finalizes an array. 98 98 This Function creates the array, and makes it ready to be sent to the application. 99 99 */ … … 124 124 125 125 /** 126 \briefadds a new Entry to the Array127 \param entry Entry to add.126 * adds a new Entry to the Array 127 * @param entry Entry to add. 128 128 */ 129 129 template<class T> … … 145 145 146 146 /** 147 \briefAdds 3 entries at once (convenience)147 * Adds 3 entries at once (convenience) 148 148 */ 149 149 template<class T> … … 157 157 158 158 /** 159 \briefgets back the index of the entry in the array. value check160 \param entry: the entry to look up161 \returns the index in the array, -1 if not found159 * gets back the index of the entry in the array. value check 160 * @param entry: the entry to look up 161 * @returns the index in the array, -1 if not found 162 162 */ 163 163 template<class T> … … 176 176 177 177 /** 178 \briefSimple debug info about the Array178 * Simple debug info about the Array 179 179 */ 180 180 template<class T> -
orxonox/trunk/src/lib/graphics/importer/material.cc
r4834 r4836 25 25 #include <string.h> 26 26 27 //! \todo check if we are in RESOURCE MANAGER-mode27 //! @todo check if we are in RESOURCE MANAGER-mode 28 28 #include "resource_manager.h" 29 29 … … 31 31 32 32 /** 33 \briefcreates a Material.34 \param mtlName Name of the Material to be added to the Material List33 * creates a Material. 34 * @param mtlName Name of the Material to be added to the Material List 35 35 */ 36 36 Material::Material (const char* mtlName) … … 52 52 53 53 /** 54 \briefdeletes a Material54 * deletes a Material 55 55 */ 56 56 Material::~Material() … … 67 67 68 68 /** 69 \briefsets the material with which the following Faces will be painted69 * sets the material with which the following Faces will be painted 70 70 */ 71 71 bool Material::select () … … 99 99 100 100 // setting illumination Model 101 if (this->illumModel == 1) //! \todo make this work, if no vertex-normals are read.101 if (this->illumModel == 1) //! @todo make this work, if no vertex-normals are read. 102 102 glShadeModel(GL_FLAT); 103 103 else if (this->illumModel >= 2) … … 124 124 125 125 /** 126 \briefSets the Material Illumination Model.127 \briefillu illumination Model in int form126 * Sets the Material Illumination Model. 127 * illu illumination Model in int form 128 128 */ 129 129 void Material::setIllum (int illum) … … 133 133 } 134 134 /** 135 \briefSets the Material Illumination Model.136 \briefillu illumination Model in char* form135 * Sets the Material Illumination Model. 136 * illu illumination Model in char* form 137 137 */void Material::setIllum (char* illum) 138 138 { … … 141 141 142 142 /** 143 \briefSets the Material Diffuse Color.144 \param r Red Color Channel.145 \param g Green Color Channel.146 \param b Blue Color Channel.143 * Sets the Material Diffuse Color. 144 * @param r Red Color Channel. 145 * @param g Green Color Channel. 146 * @param b Blue Color Channel. 147 147 */ 148 148 void Material::setDiffuse (float r, float g, float b) … … 156 156 } 157 157 /** 158 \briefSets the Material Diffuse Color.159 \param rgb The red, green, blue channel in char format (with spaces between them)158 * Sets the Material Diffuse Color. 159 * @param rgb The red, green, blue channel in char format (with spaces between them) 160 160 */ 161 161 void Material::setDiffuse (char* rgb) … … 167 167 168 168 /** 169 \briefSets the Material Ambient Color.170 \param r Red Color Channel.171 \param g Green Color Channel.172 \param b Blue Color Channel.169 * Sets the Material Ambient Color. 170 * @param r Red Color Channel. 171 * @param g Green Color Channel. 172 * @param b Blue Color Channel. 173 173 */ 174 174 void Material::setAmbient (float r, float g, float b) … … 181 181 } 182 182 /** 183 \briefSets the Material Ambient Color.184 \param rgb The red, green, blue channel in char format (with spaces between them)183 * Sets the Material Ambient Color. 184 * @param rgb The red, green, blue channel in char format (with spaces between them) 185 185 */ 186 186 void Material::setAmbient (char* rgb) … … 192 192 193 193 /** 194 \briefSets the Material Specular Color.195 \param r Red Color Channel.196 \param g Green Color Channel.197 \param b Blue Color Channel.194 * Sets the Material Specular Color. 195 * @param r Red Color Channel. 196 * @param g Green Color Channel. 197 * @param b Blue Color Channel. 198 198 */ 199 199 void Material::setSpecular (float r, float g, float b) … … 206 206 } 207 207 /** 208 \briefSets the Material Specular Color.209 \param rgb The red, green, blue channel in char format (with spaces between them)208 * Sets the Material Specular Color. 209 * @param rgb The red, green, blue channel in char format (with spaces between them) 210 210 */ 211 211 void Material::setSpecular (char* rgb) … … 217 217 218 218 /** 219 \briefSets the Material Shininess.220 \param shini stes the Shininess from float.219 * Sets the Material Shininess. 220 * @param shini stes the Shininess from float. 221 221 */ 222 222 void Material::setShininess (float shini) … … 225 225 } 226 226 /** 227 \briefSets the Material Shininess.228 \param shini stes the Shininess from char*.227 * Sets the Material Shininess. 228 * @param shini stes the Shininess from char*. 229 229 */ 230 230 void Material::setShininess (char* shini) … … 234 234 235 235 /** 236 \briefSets the Material Transparency.237 \param trans stes the Transparency from int.236 * Sets the Material Transparency. 237 * @param trans stes the Transparency from int. 238 238 */ 239 239 void Material::setTransparency (float trans) … … 243 243 } 244 244 /** 245 \briefSets the Material Transparency.246 \param trans stes the Transparency from char*.245 * Sets the Material Transparency. 246 * @param trans stes the Transparency from char*. 247 247 */ 248 248 void Material::setTransparency (char* trans) … … 252 252 253 253 /** 254 \briefAdds a Texture Path to the List of already existing Paths255 \param pathName The Path to add.254 * Adds a Texture Path to the List of already existing Paths 255 * @param pathName The Path to add. 256 256 */ 257 257 void Material::addTexturePath(const char* pathName) … … 263 263 264 264 /** 265 \briefSets the Materials Diffuse Map266 \param dMap the Name of the Image to Use265 * Sets the Materials Diffuse Map 266 * @param dMap the Name of the Image to Use 267 267 */ 268 268 void Material::setDiffuseMap(const char* dMap) … … 281 281 282 282 /** 283 \briefSets the Materials Ambient Map284 \param aMap the Name of the Image to Use285 \todo implement this283 * Sets the Materials Ambient Map 284 * @param aMap the Name of the Image to Use 285 @todo implement this 286 286 */ 287 287 void Material::setAmbientMap(const char* aMap) … … 292 292 293 293 /** 294 \briefSets the Materials Specular Map295 \param sMap the Name of the Image to Use296 \todo implement this294 * Sets the Materials Specular Map 295 * @param sMap the Name of the Image to Use 296 @todo implement this 297 297 */ 298 298 void Material::setSpecularMap(const char* sMap) … … 303 303 304 304 /** 305 \briefSets the Materials Bumpiness306 \param bump the Name of the Image to Use307 \todo implemet this305 * Sets the Materials Bumpiness 306 * @param bump the Name of the Image to Use 307 @todo implemet this 308 308 */ 309 309 void Material::setBump(const char* bump) -
orxonox/trunk/src/lib/graphics/importer/material.h
r4746 r4836 2 2 \file material.h 3 3 \brief Contains the Material Class that handles Material for 3D-Objects. 4 \todo free SDL-surface when deleting Material.5 \todo delete imgNameWithPath after use creation.4 @todo free SDL-surface when deleting Material. 5 @todo delete imgNameWithPath after use creation. 6 6 */ 7 7 -
orxonox/trunk/src/lib/graphics/importer/md2Model.cc
r4787 r4836 101 101 102 102 /** 103 \briefinitializes an array of vert with the current frame scaled vertices104 \param verticesList: the list of vertices to interpolate between103 * initializes an array of vert with the current frame scaled vertices 104 * @param verticesList: the list of vertices to interpolate between 105 105 106 106 we won't use the pVertices array directly, since its much easier and we need … … 126 126 /** 127 127 \brief sets the animation type 128 \param type: animation type128 * @param type: animation type 129 129 130 130 the animation types can be looked up in the animationType table … … 150 150 /** 151 151 \brief sets the time in seconds passed since the last tick 152 \param time: in sec152 * @param time: in sec 153 153 */ 154 154 void MD2Model::tick(float time) … … 320 320 /** 321 321 \brief this will load the whole model data (vertices, opengl command list, ...) 322 \param fileName: the name of the model file322 * @param fileName: the name of the model file 323 323 \return true if success 324 324 */ … … 418 418 /** 419 419 \brief loads the skin/material stuff 420 \param fileName: name of the skin file420 * @param fileName: name of the skin file 421 421 \return true if success 422 422 */ -
orxonox/trunk/src/lib/graphics/importer/md2Model.h
r4787 r4836 1 1 /*! 2 2 \file md2Model.h 3 \briefDefinition of an MD2 Model, a model format invented by ID Software.3 * Definition of an MD2 Model, a model format invented by ID Software. 4 4 5 5 We are deeply thankfull for all the wunderfull things id software made for us gamers! … … 142 142 void setAnim(int type); 143 143 /** 144 \briefscales the current model145 \param scaleFactor: the factor [0..1] to use for scaling144 * scales the current model 145 * @param scaleFactor: the factor [0..1] to use for scaling 146 146 */ 147 147 void scaleModel(float scaleFactor) { this->scaleFactor = scaleFactor;} -
orxonox/trunk/src/lib/graphics/importer/model.cc
r4834 r4836 33 33 //////////////////// 34 34 /** 35 \briefcreates a new ModelFaceElement35 * creates a new ModelFaceElement 36 36 */ 37 37 ModelFaceElement::ModelFaceElement() … … 45 45 46 46 /** 47 \briefdestroys a ModelFaceElement47 * destroys a ModelFaceElement 48 48 */ 49 49 ModelFaceElement::~ModelFaceElement() … … 54 54 55 55 /** 56 \briefcreates a new ModelFace56 * creates a new ModelFace 57 57 */ 58 58 ModelFace::ModelFace() … … 69 69 70 70 /** 71 \briefdeletes a ModelFace71 * deletes a ModelFace 72 72 */ 73 73 ModelFace::~ModelFace() … … 83 83 84 84 /** 85 \briefCreates a new ModelGroup85 * Creates a new ModelGroup 86 86 */ 87 87 ModelGroup::ModelGroup() … … 98 98 99 99 /** 100 \briefdeletes a ModelGroup100 * deletes a ModelGroup 101 101 */ 102 102 ModelGroup::~ModelGroup() … … 111 111 112 112 /** 113 \briefcleans up a ModelGroup113 * cleans up a ModelGroup 114 114 115 115 actually does the same as the delete Operator, but does not delete the predecessing group … … 130 130 ///////////// 131 131 /** 132 \briefCreates a 3D-Model.132 * Creates a 3D-Model. 133 133 134 134 assigns it a Name and a Type … … 166 166 167 167 /** 168 \briefdeletes an Model.168 * deletes an Model. 169 169 170 170 Looks if any from model allocated space is still in use, and if so deleted it. … … 206 206 207 207 /** 208 \briefFinalizes an Object. This can be done outside of the Class.208 * Finalizes an Object. This can be done outside of the Class. 209 209 */ 210 210 void Model::finalize() … … 237 237 ////////// 238 238 /** 239 \briefDraws the Models of all Groups.239 * Draws the Models of all Groups. 240 240 It does this by just calling the Lists that must have been created earlier. 241 241 */ … … 280 280 281 281 /** 282 \briefDraws the Model number groupNumber283 \param groupNumber The number of the group that will be displayed.282 * Draws the Model number groupNumber 283 * @param groupNumber The number of the group that will be displayed. 284 284 285 285 It does this by just calling the List that must have been created earlier. … … 312 312 313 313 /** 314 \briefDraws the Model with a specific groupName315 \param groupName The name of the group that will be displayed.314 * Draws the Model with a specific groupName 315 * @param groupName The name of the group that will be displayed. 316 316 317 317 It does this by just calling the List that must have been created earlier. … … 339 339 ////////// 340 340 /** 341 \briefdeletes all the arrays341 * deletes all the arrays 342 342 */ 343 343 bool Model::deleteArrays() … … 359 359 360 360 /** 361 \brieffinalizes an Model.361 * finalizes an Model. 362 362 * This funcion is needed, to delete all the Lists, and arrays that are no more 363 363 * needed because they are already imported into openGL. … … 375 375 ////////// 376 376 /** 377 \briefadds a new Material to the Material List378 \param material the Material to add379 \returns the added material377 * adds a new Material to the Material List 378 * @param material the Material to add 379 * @returns the added material 380 380 * 381 381 * this also tells this Model, that all the Materials are handled externally … … 391 391 392 392 /** 393 \briefadds a new Material to the Material List394 \param materialName the name of the Material to add395 \returns the added material393 * adds a new Material to the Material List 394 * @param materialName the name of the Material to add 395 * @returns the added material 396 396 */ 397 397 Material* Model::addMaterial(const char* materialName) … … 406 406 407 407 /** 408 \brieffinds a Material by its name and returns it409 \param materialName the Name of the material to search for.410 \returns the Material if found, NULL otherwise408 * finds a Material by its name and returns it 409 * @param materialName the Name of the material to search for. 410 * @returns the Material if found, NULL otherwise 411 411 */ 412 412 Material* Model::findMaterialByName(const char* materialName) … … 428 428 429 429 /** 430 \briefparses a group String431 \param groupString the new Group to create430 * parses a group String 431 * @param groupString the new Group to create 432 432 433 433 This function initializes a new Group. … … 452 452 453 453 /** 454 \briefparses a vertex-String455 \param vertexString The String that will be parsed.454 * parses a vertex-String 455 * @param vertexString The String that will be parsed. 456 456 457 457 If a vertex line is found this function will inject it into the vertex-Array … … 470 470 471 471 /** 472 \briefparses a vertex-String473 \param x the X-coordinate of the Vertex to add.474 \param y the Y-coordinate of the Vertex to add.475 \param z the Z-coordinate of the Vertex to add.472 * parses a vertex-String 473 * @param x the X-coordinate of the Vertex to add. 474 * @param y the Y-coordinate of the Vertex to add. 475 * @param z the Z-coordinate of the Vertex to add. 476 476 477 477 */ … … 485 485 486 486 /** 487 \briefparses a vertexNormal-String488 \param normalString The String that will be parsed.487 * parses a vertexNormal-String 488 * @param normalString The String that will be parsed. 489 489 490 490 If a vertexNormal line is found this function will inject it into the vertexNormal-Array … … 503 503 504 504 /** 505 \briefadds a VertexNormal.506 \param x The x coordinate of the Normal.507 \param y The y coordinate of the Normal.508 \param z The z coordinate of the Normal.505 * adds a VertexNormal. 506 * @param x The x coordinate of the Normal. 507 * @param y The y coordinate of the Normal. 508 * @param z The z coordinate of the Normal. 509 509 510 510 If a vertexNormal line is found this function will inject it into the vertexNormal-Array … … 519 519 520 520 /** 521 \briefparses a vertexTextureCoordinate-String522 \param vTextureString The String that will be parsed.521 * parses a vertexTextureCoordinate-String 522 * @param vTextureString The String that will be parsed. 523 523 524 524 If a vertexTextureCoordinate line is found, … … 540 540 541 541 /** 542 \briefadds a Texture Coordinate543 \param u The u coordinate of the TextureCoordinate.544 \param v The y coordinate of the TextureCoordinate.542 * adds a Texture Coordinate 543 * @param u The u coordinate of the TextureCoordinate. 544 * @param v The y coordinate of the TextureCoordinate. 545 545 546 546 If a TextureCoordinate line is found this function will inject it into the TextureCoordinate-Array … … 556 556 557 557 /** 558 \briefparses a face-string559 \param faceString The String that will be parsed.558 * parses a face-string 559 * @param faceString The String that will be parsed. 560 560 561 561 If a face line is found this function will add it to the glList. … … 615 615 616 616 /** 617 \briefadds a new Face618 \param faceElemCount the number of Vertices to add to the Face.619 \param type The information Passed with each Vertex617 * adds a new Face 618 * @param faceElemCount the number of Vertices to add to the Face. 619 * @param type The information Passed with each Vertex 620 620 */ 621 621 bool Model::addFace(int faceElemCount, VERTEX_FORMAT type, ...) … … 648 648 649 649 /** 650 \briefFunction that selects a material, if changed in the obj file.651 \param matString the Material that will be set.650 * Function that selects a material, if changed in the obj file. 651 * @param matString the Material that will be set. 652 652 */ 653 653 bool Model::setMaterial(const char* matString) … … 663 663 664 664 /** 665 \briefFunction that selects a material, if changed in the obj file.666 \param mtl the Material that will be set.665 * Function that selects a material, if changed in the obj file. 666 * @param mtl the Material that will be set. 667 667 */ 668 668 bool Model::setMaterial(Material* mtl) … … 678 678 679 679 /** 680 \briefA routine that is able to create normals.680 * A routine that is able to create normals. 681 681 682 682 The algorithm does the following: … … 757 757 //////////// 758 758 /** 759 \briefreads and includes the Faces/Materials into the openGL state Machine759 * reads and includes the Faces/Materials into the openGL state Machine 760 760 */ 761 761 bool Model::importToDisplayList() … … 849 849 850 850 /** 851 \briefreads and includes the Faces/Materials into the openGL state Machine851 * reads and includes the Faces/Materials into the openGL state Machine 852 852 */ 853 853 bool Model::importToVertexArray() … … 869 869 870 870 /** 871 \briefbuilds an array of triangles, that can later on be used for obb separation and octree separation871 * builds an array of triangles, that can later on be used for obb separation and octree separation 872 872 */ 873 873 bool Model::buildTriangleList() … … 993 993 994 994 /** 995 \briefAdds a Face-element (one vertex of a face) with all its information.996 \param elem The FaceElement to add to the OpenGL-environment.995 * Adds a Face-element (one vertex of a face) with all its information. 996 * @param elem The FaceElement to add to the OpenGL-environment. 997 997 998 998 It does this by searching: … … 1034 1034 1035 1035 /** 1036 \briefIncludes a default model1036 * Includes a default model 1037 1037 1038 1038 This will inject a Cube, because this is the most basic model. -
orxonox/trunk/src/lib/graphics/importer/model.h
r4834 r4836 24 24 MODEL_DISPLAY_LIST means, that a DisplayList will be built out of the model. This model will be STATIC, meaning it cannot be changed after initialisation. 25 25 MODEL_VERTEX_ARRAY means, that a VertexArray will be built out of the model. This moel will be DYNAMIX, meaning that one can change the properties from outside of the model. 26 * \todo implement this stuff26 * @todo implement this stuff 27 27 */ 28 28 typedef enum MODEL_TYPE { … … 90 90 ModelFace* firstFace; //!< The first Face in this group. 91 91 ModelFace* currentFace; //!< The current Face in this Group (the one we are currently working with.) 92 int faceMode; //!< The Mode the Face is in: initially -1, 0 for FaceList opened, 1 for Material, 3 for triangle, 4 for Quad, 5+ for Poly \todo ENUM...92 int faceMode; //!< The Mode the Face is in: initially -1, 0 for FaceList opened, 1 for Material, 3 for triangle, 4 for Quad, 5+ for Poly @todo ENUM... 93 93 int faceCount; //!< The Number of Faces this Group holds. 94 94 … … 111 111 void draw(char* groupName) const; 112 112 113 /** \returns Count of the Models (Groups) in this File */113 /** @returns Count of the Models (Groups) in this File */ 114 114 inline int getGroupCount() const { return this->groupCount; }; 115 115 116 /** \returns a Pointer to the Vertex-Array, if it was deleted it returns NULL */116 /** @returns a Pointer to the Vertex-Array, if it was deleted it returns NULL */ 117 117 inline const GLfloat* getVertexArray() const { return this->vertices->getArray(); }; 118 /** \returns the VertexCount of this Model */118 /** @returns the VertexCount of this Model */ 119 119 inline unsigned int getVertexCount() const { return this->vertexCount; }; 120 120 121 /** \returns a Pointer to the Normals-Array, if it was deleted it returns NULL */121 /** @returns a Pointer to the Normals-Array, if it was deleted it returns NULL */ 122 122 inline const GLfloat* getNormalsArray() const { return this->normals->getArray(); }; 123 /** \returns the NormalsCount of this Model */123 /** @returns the NormalsCount of this Model */ 124 124 inline unsigned int getNormalsCount() const { return this->normalCount; }; 125 125 126 /** \returns a Pointer to the TexCoord-Array, if it was deleted it returns NULL */126 /** @returns a Pointer to the TexCoord-Array, if it was deleted it returns NULL */ 127 127 inline const GLfloat* getTexCoordArray() const { return this->vTexture->getArray(); }; 128 /** \returns the TexCoord-Count of this Model */128 /** @returns the TexCoord-Count of this Model */ 129 129 inline unsigned int getTexCoordCount() const { return this->texCoordCount; }; 130 130 131 /** \returns the Count of Faces of this Model */131 /** @returns the Count of Faces of this Model */ 132 132 inline unsigned int getFaceCount() const { return this->faceCount; }; 133 133 … … 157 157 158 158 protected: 159 float scaleFactor; //!< The Factor with which the Model should be scaled. \todo maybe one wants to scale the Model after Initialisation159 float scaleFactor; //!< The Factor with which the Model should be scaled. @todo maybe one wants to scale the Model after Initialisation 160 160 161 161 private: -
orxonox/trunk/src/lib/graphics/importer/objModel.cc
r4371 r4836 28 28 29 29 /** 30 \briefCrates a 3D-Model, loads in a File and scales it.31 \param fileName file to parse and load (must be a .obj file)32 \param scaling The factor that the model will be scaled with.30 * Crates a 3D-Model, loads in a File and scales it. 31 * @param fileName file to parse and load (must be a .obj file) 32 * @param scaling The factor that the model will be scaled with. 33 33 */ 34 34 OBJModel::OBJModel(const char* fileName, float scaling) : Model(fileName) … … 44 44 45 45 /** 46 \briefdeletes an OBJModel.46 * deletes an OBJModel. 47 47 48 48 Looks if any from model allocated space is still in use, and if so deleted it. … … 56 56 57 57 /** 58 \briefImports a obj file and handles the the relative location59 \param fileName The file to import58 * Imports a obj file and handles the the relative location 59 * @param fileName The file to import 60 60 61 61 Splits the FileName from the DirectoryName … … 86 86 87 87 /** 88 \briefReads in the .obj File and sets all the Values.88 * Reads in the .obj File and sets all the Values. 89 89 This function does read the file, parses it for the occurence of things like vertices, faces and so on, and executes the specific tasks 90 90 */ … … 143 143 this->addGroup (buffer+2); 144 144 } 145 else if (!strncmp(buffer, "s ", 2)) //! \todo smoothing groups have to be implemented145 else if (!strncmp(buffer, "s ", 2)) //! @todo smoothing groups have to be implemented 146 146 { 147 147 PRINTF(2)("smoothing groups not supportet yet. line: %s\n", buffer); … … 153 153 154 154 /** 155 \briefFunction to read in a mtl File.156 \param mtlFile The .mtl file to read155 * Function to read in a mtl File. 156 * @param mtlFile The .mtl file to read 157 157 158 158 This Function parses all Lines of an mtl File. -
orxonox/trunk/src/lib/graphics/importer/primitive_model.cc
r4678 r4836 25 25 26 26 /** 27 \briefCreates a 3D-Model of Primitive-Type type27 * Creates a 3D-Model of Primitive-Type type 28 28 29 29 if you want to just display a Cube/Sphere/Cylinder/... without any material. 30 30 31 \todo implement Cube/Sphere/Cylinder/...31 @todo implement Cube/Sphere/Cylinder/... 32 32 */ 33 33 PrimitiveModel::PrimitiveModel(PRIMITIVE type, float size, unsigned int detail) … … 56 56 57 57 /** 58 \briefstandard deconstructor58 * standard deconstructor 59 59 60 60 */ … … 65 65 66 66 /** 67 \briefBuilds a Sphere into the Model.68 \param size The diameter of the Sphere.69 \param detail The detail of the Sphere.67 * Builds a Sphere into the Model. 68 * @param size The diameter of the Sphere. 69 * @param detail The detail of the Sphere. 70 70 */ 71 71 void PrimitiveModel::sphereModel(float size, unsigned int detail) … … 132 132 } 133 133 /** 134 \briefCreates a Cylinder.134 * Creates a Cylinder. 135 135 */ 136 136 void PrimitiveModel::cylinderModel(float size, unsigned int detail) … … 173 173 174 174 /** 175 \briefcreates a cone inside of this Model176 \param size The size of the cone177 \param detail the Detail-level of this cone175 * creates a cone inside of this Model 176 * @param size The size of the cone 177 * @param detail the Detail-level of this cone 178 178 */ 179 179 void PrimitiveModel::coneModel(float size, unsigned int detail) … … 209 209 210 210 /** 211 \briefcreates a Plane inside of this Model212 \param size The size of this plane213 \param detail the Detail-level of this plane.211 * creates a Plane inside of this Model 212 * @param size The size of this plane 213 * @param detail the Detail-level of this plane. 214 214 */ 215 215 void PrimitiveModel::planeModel(float size, unsigned int detail) -
orxonox/trunk/src/lib/graphics/importer/primitive_model.h
r4468 r4836 1 1 /*! 2 2 \file primitive_model.h 3 \briefa Class to handle different simple models like planes cubes spheres and so on.3 * a Class to handle different simple models like planes cubes spheres and so on. 4 4 (cube is also an option of Model, but is extended here. 5 5 */ -
orxonox/trunk/src/lib/graphics/importer/texture.cc
r4746 r4836 28 28 29 29 /** 30 \briefConstructor for a Texture30 * Constructor for a Texture 31 31 */ 32 32 Texture::Texture(const char* imageName) … … 39 39 40 40 /** 41 \briefDestructor of a Texture41 * Destructor of a Texture 42 42 43 43 Frees Data, and deletes the textures from GL … … 50 50 51 51 /** 52 \briefLoads a Texture to the openGL-environment.53 \param surface the Image to load to openGL54 \returns The ID of the texture.52 * Loads a Texture to the openGL-environment. 53 * @param surface the Image to load to openGL 54 * @returns The ID of the texture. 55 55 */ 56 56 GLuint Texture::loadTexToGL (SDL_Surface* surface) … … 139 139 140 140 /** 141 \briefloads an Image from a file to a Texture142 \param imageName The image to load141 * loads an Image from a file to a Texture 142 * @param imageName The image to load 143 143 */ 144 144 bool Texture::loadImage(const char* imageName) -
orxonox/trunk/src/lib/graphics/importer/texture.h
r4746 r4836 3 3 \brief Contains the texture class, that handles the reading of Images into Texutre-files. 4 4 5 \todo procedural textures5 @todo procedural textures 6 6 */ 7 7 … … 27 27 ~Texture(); 28 28 29 /** \returns The textureID of this texture. */29 /** @returns The textureID of this texture. */ 30 30 inline GLuint getTexture() {return this->texture;} 31 31 GLuint loadTexToGL (SDL_Surface* surface); 32 /** \returns true if texture has alpha, false otherwise */32 /** @returns true if texture has alpha, false otherwise */ 33 33 inline bool hasAlpha() const {return bAlpha;} 34 34 -
orxonox/trunk/src/lib/graphics/light.cc
r4746 r4836 45 45 46 46 /** 47 * \param root The XML-element to load the Light from48 49 \todo what to do, if no Light-Slots are open anymore ???47 * @param root The XML-element to load the Light from 48 49 @todo what to do, if no Light-Slots are open anymore ??? 50 50 */ 51 51 Light::Light(const TiXmlElement* root) … … 71 71 72 72 /** 73 \briefdestroys a Light73 * destroys a Light 74 74 */ 75 75 Light::~Light() … … 81 81 82 82 /** 83 * \param root The XML-element to load the Light from83 * @param root The XML-element to load the Light from 84 84 */ 85 85 void Light::loadParams(const TiXmlElement* root) … … 104 104 105 105 /** 106 \briefsets an emitting Diffuse color of this Light107 \param r red108 \param g green109 \param b blue106 * sets an emitting Diffuse color of this Light 107 * @param r red 108 * @param g green 109 * @param b blue 110 110 */ 111 111 void Light::setDiffuseColor(GLfloat r, GLfloat g, GLfloat b) … … 120 120 121 121 /** 122 \briefsets an emitting Specular color of this Light123 \param r red124 \param g green125 \param b blue122 * sets an emitting Specular color of this Light 123 * @param r red 124 * @param g green 125 * @param b blue 126 126 */ 127 127 void Light::setSpecularColor(GLfloat r, GLfloat g, GLfloat b) … … 137 137 138 138 /** 139 \briefSets the AttenuationType of this Light Source140 \param constantAttenuation The Constant Attenuation of the Light141 \param linearAttenuation The Linear Attenuation of the Light142 \param quadraticAttenuation The Quadratic Attenuation of the Light139 * Sets the AttenuationType of this Light Source 140 * @param constantAttenuation The Constant Attenuation of the Light 141 * @param linearAttenuation The Linear Attenuation of the Light 142 * @param quadraticAttenuation The Quadratic Attenuation of the Light 143 143 */ 144 144 void Light::setAttenuation(float constantAttenuation, float linearAttenuation, float quadraticAttenuation) … … 155 155 156 156 /** 157 \briefstets the direction of the Spot Light.158 \param direction The direction of the Spot Light.157 * stets the direction of the Spot Light. 158 * @param direction The direction of the Spot Light. 159 159 */ 160 160 void Light::setSpotDirection(const Vector& direction) … … 169 169 170 170 /** 171 \briefsets the cutoff angle of the Light.172 \param cutoff The cutoff angle.171 * sets the cutoff angle of the Light. 172 * @param cutoff The cutoff angle. 173 173 */ 174 174 void Light::setSpotCutoff(GLfloat cutoff) … … 179 179 180 180 /** 181 \briefdraws this Light. Being a World-entity the possibility to do this lies at hand.181 * draws this Light. Being a World-entity the possibility to do this lies at hand. 182 182 */ 183 183 void Light::draw() const … … 190 190 191 191 /** 192 \briefPrints out some nice formated debug information about the Light192 * Prints out some nice formated debug information about the Light 193 193 */ 194 194 void Light::debug() const … … 213 213 ******************/ 214 214 /** 215 \briefstandard constructor for a Light215 * standard constructor for a Light 216 216 */ 217 217 LightManager::LightManager () … … 228 228 229 229 /** 230 \briefstandard deconstructor230 * standard deconstructor 231 231 232 232 first disables Lighting … … 248 248 249 249 /** 250 \briefsingleton-Reference to the Light-class250 * singleton-Reference to the Light-class 251 251 */ 252 252 LightManager* LightManager::singletonRef = NULL; 253 253 254 254 /** 255 \param root the XML-element to load the LightManager's settings from255 * @param root the XML-element to load the LightManager's settings from 256 256 */ 257 257 void LightManager::loadParams(const TiXmlElement* root) … … 265 265 266 266 /** 267 \param root The XML-element to load Lights from267 * @param root The XML-element to load Lights from 268 268 */ 269 269 void LightManager::loadLights(const TiXmlElement* root) … … 281 281 // set Attributes 282 282 /** 283 \briefsets the ambient Color of the Scene284 \param r red285 \param g green286 \param b blue283 * sets the ambient Color of the Scene 284 * @param r red 285 * @param g green 286 * @param b blue 287 287 */ 288 288 void LightManager::setAmbientColor(GLfloat r, GLfloat g, GLfloat b) … … 297 297 298 298 /** 299 \param light the Light to register to the LightManager299 * @param light the Light to register to the LightManager 300 300 301 301 This is done explicitely by the constructor of a Light … … 314 314 315 315 /** 316 \param light The light to unregister from the LightManager316 * @param light The light to unregister from the LightManager 317 317 318 318 This is done every time a Light is destroyed explicitely by the Light-destructor … … 333 333 334 334 /** 335 \briefdraws all the Lights in their appropriate position335 * draws all the Lights in their appropriate position 336 336 */ 337 337 void LightManager::draw() const … … 346 346 347 347 /** 348 \briefoutputs debug information about the Class and its lights348 * outputs debug information about the Class and its lights 349 349 */ 350 350 void LightManager::debug() const -
orxonox/trunk/src/lib/graphics/light.h
r4746 r4836 1 1 /*! 2 2 \file light.h 3 \briefHandles Lights.3 * Handles Lights. 4 4 5 5 A Light is one of the more important things in a 3D-environment, … … 38 38 void setSpotCutoff(GLfloat cutoff); 39 39 40 /** \returns the lightNumber*/40 /** @returns the lightNumber*/ 41 41 int getLightNumber() const {return this->lightNumber;} 42 42 … … 92 92 public: 93 93 virtual ~LightManager(); 94 /** \returns a Pointer to the only object of this Class */94 /** @returns a Pointer to the only object of this Class */ 95 95 inline static LightManager* getInstance() { if (!singletonRef) singletonRef = new LightManager(); return singletonRef; }; 96 96 -
orxonox/trunk/src/lib/graphics/spatial_separation/quadtree.cc
r4819 r4836 22 22 23 23 /** 24 \briefstandard constructor25 \todo this constructor is not jet implemented - do it24 * standard constructor 25 @todo this constructor is not jet implemented - do it 26 26 */ 27 27 Quadtree::Quadtree (modelInfo* pModelInfo) … … 33 33 34 34 /** 35 \briefstandard deconstructor35 * standard deconstructor 36 36 37 37 */ … … 43 43 44 44 /** 45 \briefgives the signal to separate the model into a quadtree45 * gives the signal to separate the model into a quadtree 46 46 */ 47 47 void Quadtree::separate() … … 50 50 51 51 /** 52 \briefdraws the debug quadtree boxes around the model52 * draws the debug quadtree boxes around the model 53 53 */ 54 54 void Quadtree::drawTree(int depth, int drawMode) const -
orxonox/trunk/src/lib/graphics/spatial_separation/quadtree.h
r4819 r4836 1 1 /*! 2 2 \file quadtree.h 3 \briefDefinition of a spatial data separation using quadtree3 * Definition of a spatial data separation using quadtree 4 4 5 5 */ -
orxonox/trunk/src/lib/graphics/spatial_separation/quadtree_node.cc
r4819 r4836 22 22 23 23 /** 24 \briefstandard constructor24 * standard constructor 25 25 */ 26 26 QuadtreeNode::QuadtreeNode (sTriangleExt* triangles, int numTriangles, Quadtree* quadtree) … … 31 31 32 32 /** 33 \briefstandard deconstructor33 * standard deconstructor 34 34 35 35 */ … … 41 41 42 42 /** 43 \briefgives the signal to separate the model into a quadtree44 \param treeDepth the max depth, the steps to go if treeDept == 0 leaf reached43 * gives the signal to separate the model into a quadtree 44 * @param treeDepth the max depth, the steps to go if treeDept == 0 leaf reached 45 45 */ 46 46 void QuadtreeNode::separateNode(int treeDepth) … … 49 49 50 50 /** 51 \briefgives the signal to separate the model into a quadtree52 \param treeDepth the max depth, the steps to go if treeDept == 0 leaf reached51 * gives the signal to separate the model into a quadtree 52 * @param treeDepth the max depth, the steps to go if treeDept == 0 leaf reached 53 53 */ 54 54 void QuadtreeNode::separateNode(float minLength) … … 57 57 58 58 /** 59 \briefdraws the debug quadtree boxes around the model59 * draws the debug quadtree boxes around the model 60 60 */ 61 61 void QuadtreeNode::drawTree(int depth, int drawMode) const -
orxonox/trunk/src/lib/graphics/spatial_separation/quadtree_node.h
r4819 r4836 1 1 /*! 2 2 \file proto_class.h 3 \briefDefinition of ...3 * Definition of ... 4 4 5 5 */ -
orxonox/trunk/src/lib/graphics/spatial_separation/spatial_separation.cc
r4819 r4836 24 24 25 25 /** 26 \briefstandard constructor27 \param model the model that is to be separated28 \param overlapSize each box will overlap for a given size26 * standard constructor 27 * @param model the model that is to be separated 28 * @param overlapSize each box will overlap for a given size 29 29 30 30 The boxes are overlaping because this makes collision detection a lot simpler … … 38 38 39 39 /** 40 \briefstandard constructor41 \param model the model that is to be separated42 \param overlapSize each box will overlap for a given size40 * standard constructor 41 * @param model the model that is to be separated 42 * @param overlapSize each box will overlap for a given size 43 43 44 44 The boxes are overlaping because this makes collision detection a lot simpler … … 53 53 54 54 /** 55 \briefstandard deconstructor55 * standard deconstructor 56 56 57 57 */ … … 63 63 /** 64 64 \brief creates a quadtree 65 \param model the model to do a quadtree on66 \param minLength the minimal length of a quadtree node65 * @param model the model to do a quadtree on 66 * @param minLength the minimal length of a quadtree node 67 67 \return the new quadtree 68 68 */ … … 76 76 /** 77 77 \brief creates a quadtree 78 \param model the model to do a quadtree on79 \param minLength the minimal length of a quadtree node78 * @param model the model to do a quadtree on 79 * @param minLength the minimal length of a quadtree node 80 80 \return the new quadtree 81 81 */ … … 88 88 /** 89 89 \brief creates a quadtree 90 \param model the model to do a quadtree on91 \param minLength the minimal length of a quadtree node90 * @param model the model to do a quadtree on 91 * @param minLength the minimal length of a quadtree node 92 92 \return the new quadtree 93 93 */ … … 103 103 /** 104 104 \brief gets the maximal dimension of a model 105 \param playerModel the model that this measurement is based on105 * @param playerModel the model that this measurement is based on 106 106 \return the maximal dimension of the model 107 107 */ -
orxonox/trunk/src/lib/graphics/spatial_separation/spatial_separation.h
r4819 r4836 1 1 /*! 2 2 \file spatial_separation.h 3 \briefDefinition of the generic spatial separation process of model data3 * Definition of the generic spatial separation process of model data 4 4 5 5 */ -
orxonox/trunk/src/lib/graphics/text_engine.cc
r4834 r4836 42 42 //////////// 43 43 /** 44 \briefcreates a new Text Element45 \param font the Font to render this text in46 \param type The renderType to display this font in44 * creates a new Text Element 45 * @param font the Font to render this text in 46 * @param type The renderType to display this font in 47 47 48 48 this constructor is private, because the user should initialize … … 67 67 68 68 /** 69 \briefdeletes a Text out of memory69 * deletes a Text out of memory 70 70 71 71 This also ereases the text from the textList of the TextEngine … … 77 77 78 78 /** 79 \brieftells the Text, that it should folow a PNode80 \param bindNode: the node to bind this text to79 * tells the Text, that it should folow a PNode 80 * @param bindNode: the node to bind this text to 81 81 */ 82 82 void Text::setBindNode(PNode* bindNode) … … 86 86 87 87 /** 88 \briefsets the Type of this Text89 \param type the type to set.88 * sets the Type of this Text 89 * @param type the type to set. 90 90 */ 91 91 void Text::setType(int type) … … 98 98 99 99 /** 100 \briefSets a new Text to the font101 \param text the new text to set100 * Sets a new Text to the font 101 * @param text the new text to set 102 102 */ 103 103 void Text::setText(const char* text) … … 129 129 130 130 /** 131 \briefsets a Position.132 \param x the x-position in pixels from the left border133 \param y the y-position in pixels from the top border131 * sets a Position. 132 * @param x the x-position in pixels from the left border 133 * @param y the y-position in pixels from the top border 134 134 */ 135 135 void Text::setPosition(int x, int y) … … 140 140 141 141 /** 142 \briefsets the text-alignment143 \param alignment the alignment to set142 * sets the text-alignment 143 * @param alignment the alignment to set 144 144 */ 145 145 void Text::setAlignment(TEXT_ALIGNMENT alignment) … … 149 149 150 150 /** 151 \briefsets a new color to the font152 \param r Red153 \param g Green154 \param b Blue151 * sets a new color to the font 152 * @param r Red 153 * @param g Green 154 * @param b Blue 155 155 */ 156 156 void Text::setColor(Uint8 r, Uint8 g, Uint8 b) … … 162 162 163 163 /** 164 \briefcreates a texture out of the given parameters164 * creates a texture out of the given parameters 165 165 166 166 this has to be called every time by the user, to if changes were made. … … 185 185 186 186 /** 187 \briefdraws the Font187 * draws the Font 188 188 */ 189 189 void Text::draw() const … … 269 269 270 270 /** 271 \briefprints out some nice debug information about this text271 * prints out some nice debug information about this text 272 272 */ 273 273 void Text::debug() const … … 285 285 //////////// 286 286 /** 287 \briefLoads a Font from an SDL_surface into a texture.288 \param surface The surface to make the texture of289 \param texCoord The texture coordinates of the 4 corners of the texture290 \returns the ID of the texture287 * Loads a Font from an SDL_surface into a texture. 288 * @param surface The surface to make the texture of 289 * @param texCoord The texture coordinates of the 4 corners of the texture 290 * @returns the ID of the texture 291 291 */ 292 292 GLuint Text::loadTexture(SDL_Surface *surface, TexCoord* texCoord) … … 366 366 367 367 /** 368 \briefQuick utility function for texture creation369 \param input an integer370 \returns the next bigger 2^n-integer than input368 * Quick utility function for texture creation 369 * @param input an integer 370 * @returns the next bigger 2^n-integer than input 371 371 */ 372 372 int Text::powerOfTwo(int input) … … 385 385 //////////// 386 386 /** 387 \briefconstructs a Font388 \param fontFile the File to load the font from389 \param fontSize the Size of the Font in Pixels390 \param r Red value of the Font.391 \param g Green value of the Font.392 \param b Blue value of the Font.387 * constructs a Font 388 * @param fontFile the File to load the font from 389 * @param fontSize the Size of the Font in Pixels 390 * @param r Red value of the Font. 391 * @param g Green value of the Font. 392 * @param b Blue value of the Font. 393 393 */ 394 394 Font::Font(const char* fontFile, unsigned int fontSize, Uint8 r, Uint8 g, Uint8 b) … … 413 413 414 414 /** 415 \briefdestructs a font415 * destructs a font 416 416 */ 417 417 Font::~Font() … … 433 433 434 434 /** 435 \briefsets The Font.436 \param fontFile The file containing the font.437 \returns true if loaded, false if something went wrong, or if a font was loaded before.435 * sets The Font. 436 * @param fontFile The file containing the font. 437 * @returns true if loaded, false if something went wrong, or if a font was loaded before. 438 438 */ 439 439 bool Font::setFont(const char* fontFile) … … 462 462 463 463 /** 464 \briefsets a specific renderStyle465 \param renderStyle the Style to render: a char-array containing:464 * sets a specific renderStyle 465 * @param renderStyle the Style to render: a char-array containing: 466 466 i: italic, b: bold, u, underline 467 467 */ … … 485 485 486 486 /** 487 \briefSets a new Size to the font488 \param fontSize The new Size in pixels.487 * Sets a new Size to the font 488 * @param fontSize The new Size in pixels. 489 489 */ 490 490 void Font::setSize(unsigned int fontSize) … … 494 494 495 495 /** 496 \briefsets a new color to the font497 \param r Red498 \param g Green499 \param b Blue496 * sets a new color to the font 497 * @param r Red 498 * @param g Green 499 * @param b Blue 500 500 */ 501 501 void Font::setFastColor(Uint8 r, Uint8 g, Uint8 b) … … 507 507 508 508 /** 509 \returns the maximum height of the Font, if the font was initialized, 0 otherwise509 * @returns the maximum height of the Font, if the font was initialized, 0 otherwise 510 510 */ 511 511 int Font::getMaxHeight() … … 518 518 519 519 /** 520 \returns the maximum ascent of the Font, if the font was initialized, 0 otherwise520 * @returns the maximum ascent of the Font, if the font was initialized, 0 otherwise 521 521 522 522 the ascent is the pixels of the font above the baseline … … 531 531 532 532 /** 533 \returns the maximum descent of the Font, if the font was initialized, 0 otherwise533 * @returns the maximum descent of the Font, if the font was initialized, 0 otherwise 534 534 535 535 the descent is the pixels of the font below the baseline … … 544 544 545 545 /** 546 \param character The character to get info about.547 \returns a Glyph struct of a character. This Glyph is a pointer,546 * @param character The character to get info about. 547 * @returns a Glyph struct of a character. This Glyph is a pointer, 548 548 and MUST be deleted by the user.. 549 549 … … 581 581 582 582 this->initGlyphs(32, numberOfGlyphs); 583 this->glyphArray[32]->width = fontSize/3; //!< \todo find out the real size of a Space583 this->glyphArray[32]->width = fontSize/3; //!< @todo find out the real size of a Space 584 584 585 585 int rectSize = this->findOptimalFastTextureSize(); … … 695 695 696 696 /** 697 \briefstores Glyph Metrics in an Array.698 \param from The Glyph to start from.699 \param count The number of Glyphs to start From.697 * stores Glyph Metrics in an Array. 698 * @param from The Glyph to start from. 699 * @param count The number of Glyphs to start From. 700 700 */ 701 701 void Font::initGlyphs(Uint16 from, Uint16 count) … … 722 722 723 723 /** 724 \returns the optimal size to use as the texture size725 726 \todo: this algorithm can be a lot more faster, althought it does724 * @returns the optimal size to use as the texture size 725 726 @todo: this algorithm can be a lot more faster, althought it does 727 727 not really matter within the init-context, and 128 glyphs. 728 728 … … 773 773 774 774 /** 775 \briefa simple function to get some interesting information about this class775 * a simple function to get some interesting information about this class 776 776 */ 777 777 void Font::debug() … … 800 800 /////////////////// 801 801 /** 802 \briefstandard constructor802 * standard constructor 803 803 */ 804 804 TextEngine::TextEngine () … … 812 812 813 813 /** 814 \briefthe singleton reference to this class814 * the singleton reference to this class 815 815 */ 816 816 TextEngine* TextEngine::singletonRef = NULL; 817 817 818 818 /** 819 \briefstandard deconstructor819 * standard deconstructor 820 820 821 821 */ … … 830 830 831 831 /** 832 \brieffunction to enable TTF_Fonts832 * function to enable TTF_Fonts 833 833 */ 834 834 void TextEngine::enableFonts() … … 846 846 847 847 /** 848 \brieffunction to disable TTF_fonts848 * function to disable TTF_fonts 849 849 */ 850 850 void TextEngine::disableFonts() … … 859 859 860 860 /** 861 \briefcreates a new Text with a certain font.861 * creates a new Text with a certain font. 862 862 \see Font::Font 863 863 \see Text::Text … … 884 884 885 885 /** 886 \briefremoves a Text from the List887 \param text: the text to delete886 * removes a Text from the List 887 * @param text: the text to delete 888 888 889 889 this only ereases allocated memory, and removes the text … … 898 898 899 899 /** 900 \briefdeletes all the Text, and tries to delete all allocated fonts900 * deletes all the Text, and tries to delete all allocated fonts 901 901 */ 902 902 void TextEngine::flush() … … 913 913 914 914 /** 915 \briefdraws all the Texts that have been initialized915 * draws all the Texts that have been initialized 916 916 */ 917 917 void TextEngine::draw() const … … 937 937 938 938 /** 939 \briefoutputs some nice Debug information940 941 \todo there should also be something outputted about Font939 * outputs some nice Debug information 940 941 @todo there should also be something outputted about Font 942 942 */ 943 943 void TextEngine::debug() const … … 961 961 962 962 /** 963 \briefchecks if the compiled version and the local version of SDL_ttf match.964 \returns true if match, false otherwise963 * checks if the compiled version and the local version of SDL_ttf match. 964 * @returns true if match, false otherwise 965 965 */ 966 966 bool TextEngine::checkVersion() -
orxonox/trunk/src/lib/graphics/text_engine.h
r4746 r4836 1 1 /*! 2 2 \file text_engine.h 3 \briefDefinition of textEngine, the Font and the Text3 * Definition of textEngine, the Font and the Text 4 4 5 5 Text is the text outputed. … … 116 116 void setPosition(int x, int y); 117 117 void setAlignment(TEXT_ALIGNMENT alignment); 118 /** \param blending the blending intensity to set (between 0.0 and 1.0) */118 /** @param blending the blending intensity to set (between 0.0 and 1.0) */ 119 119 inline void setBlending(float blending) {this->blending = blending;} 120 120 … … 145 145 // placement in openGL 146 146 GLuint texture; //!< A GL-texture to hold the text 147 TexCoord texCoord; //!< Texture-coordinates \todo fix this to have a struct147 TexCoord texCoord; //!< Texture-coordinates @todo fix this to have a struct 148 148 SDL_Rect posSize; //!< An SDL-Rectangle representing the position and size of the Text on the screen. 149 149 … … 174 174 void setStyle(const char* renderStyle); 175 175 176 /** \returns a Pointer to the Array of Glyphs */176 /** @returns a Pointer to the Array of Glyphs */ 177 177 inline Glyph** getGlyphArray() const {return glyphArray;} 178 /** \returns the texture to the fast-texture */178 /** @returns the texture to the fast-texture */ 179 179 inline GLuint getFastTextureID() const {return fastTextureID;} 180 180 … … 217 217 public: 218 218 virtual ~TextEngine(); 219 /** \returns a Pointer to the only object of this Class */219 /** @returns a Pointer to the only object of this Class */ 220 220 inline static TextEngine* getInstance() { if (!singletonRef) singletonRef = new TextEngine(); return singletonRef; }; 221 221
Note: See TracChangeset
for help on using the changeset viewer.