Changeset 8990 in orxonox.OLD for trunk/src/lib/gui/gl
- Timestamp:
- Jul 1, 2006, 6:09:30 PM (18 years ago)
- Location:
- trunk/src/lib/gui/gl
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/gui/gl/glgui_widget.cc
r8989 r8990 651 651 else 652 652 this->setForegroundColor(Color(r,g,b,a)); 653 } 654 655 656 /** 657 * @brief sets the Foreground Texture for all States. 658 * @param texture the Texture. 659 */ 660 void GLGuiWidget::setForegroundTexture(const Texture& texture) 661 { 662 for (unsigned int i = 0; i < GLGUI_STATE_COUNT; ++i) 663 setForegroundTexture(texture, (OrxGui::State)i); 664 } 665 666 /** 667 * @brief sets the Foreground Texture to all States. 668 * @param textureName the Texture's fileName. 669 */ 670 void GLGuiWidget::setForegroundTexture(const std::string& textureName) 671 { 672 for (unsigned int i = 0; i < GLGUI_STATE_COUNT; ++i) 673 _style[i]._foreground.setDiffuseMap(textureName); 674 this->_currentStyle._foreground.setDiffuseMap(textureName); 675 } 676 677 /** 678 * @brief sets the Foreground Texture. 679 * @param texture the Texture. 680 * @param state the State to setup. 681 */ 682 void GLGuiWidget::setForegroundTexture(const Texture& texture, OrxGui::State state) 683 { 684 _style[state]._background.setDiffuseMap(texture); 685 if (state == _state) 686 _currentStyle._background.setDiffuseMap(texture); 687 } 688 689 690 691 /** 692 * @brief sets the Foreground Texture. 693 * @param texture the Texture. 694 * @param stateName the State to setup. 695 */ 696 void GLGuiWidget::setForegroundTexture(const std::string& textureName, const std::string& stateName) 697 { 698 OrxGui::State state; 699 if (getState(stateName, &state)) 700 ; /// FIXME this->setForegroundTexture(textureName, state); 701 else 702 ; /// this->setForegroundTexture(textureName); 653 703 } 654 704 -
trunk/src/lib/gui/gl/glgui_widget.h
r8983 r8990 192 192 void setForegroundColorS(float r, float g, float b, float a, const std::string& stateName); 193 193 194 void setForegroundTexture(const Texture& texture); 195 void setForegroundTexture(const std::string& textureName); 196 void setForegroundTexture(const Texture& texture, OrxGui::State state); 197 void setForegroundTexture(const std::string& textureName, const std::string& stateName); 198 194 199 void loadBackgroundMaterial(const Material& material); 195 200 void loadBackgroundMaterial(const Material& material, OrxGui::State state);
Note: See TracChangeset
for help on using the changeset viewer.