Changeset 5078 in orxonox.OLD for trunk/src/lib
- Timestamp:
- Aug 19, 2005, 5:02:38 AM (19 years ago)
- Location:
- trunk/src/lib/graphics
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/graphics/graphics_engine.cc
r5024 r5078 451 451 this->geTextMaxFPS->setAlignment(TEXT_ALIGN_LEFT); 452 452 this->geTextMaxFPS->setPosition2D(5, 35); 453 this->geTextMinFPS = TextEngine::getInstance()->createText("fonts/arial_black.ttf", 35, TEXT_DYNAMIC, 0, 255, 0);453 this->geTextMinFPS = TextEngine::getInstance()->createText("fonts/arial_black.ttf", 15, TEXT_DYNAMIC, 0, 255, 0); 454 454 this->geTextMinFPS->setAlignment(TEXT_ALIGN_LEFT); 455 455 this->geTextMinFPS->setPosition2D(5, 65); -
trunk/src/lib/graphics/render2D/render_2d.cc
r5068 r5078 88 88 void Render2D::moveToLayer(Element2D* element2D, E2D_LAYER to) 89 89 { 90 this->element2DList[(int)log2(element2D->getLayer())]->remove(element2D); 91 this->element2DList[(int)log2(to)]->add(element2D); 90 if (element2D->getLayer() != to) 91 { 92 this->element2DList[(int)log2(element2D->getLayer())]->remove(element2D); 93 this->element2DList[(int)log2(to)]->add(element2D); 94 } 92 95 } 93 96 -
trunk/src/lib/graphics/text_engine.cc
r5077 r5078 813 813 /** 814 814 * creates a new Text with a certain font. 815 \see Font::Font816 \see Text::Text815 @see Font::Font 816 @see Text::Text 817 817 */ 818 818 Text* TextEngine::createText(const char* fontFile, unsigned int fontSize, int textType, Uint8 r, Uint8 g, Uint8 b) … … 831 831 832 832 return new Text(tmpFont, TEXT_DYNAMIC); 833 }834 835 /**836 * deletes all the Text, and tries to delete all allocated fonts837 */838 void TextEngine::flush()839 {840 tIterator<BaseObject>* textIterator = ClassList::getList(CL_TEXT)->getIterator();841 Text* text = dynamic_cast<Text*>(textIterator->nextElement());842 while( text != NULL)843 {844 delete text;845 text = dynamic_cast<Text*>(textIterator->nextElement());846 }847 delete textIterator;848 833 } 849 834 -
trunk/src/lib/graphics/text_engine.h
r5077 r5078 218 218 Uint8 b = FONT_DEFAULT_COLOR_B); 219 219 220 void flush();221 222 220 void debug() const; 223 221
Note: See TracChangeset
for help on using the changeset viewer.