Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Feb 3, 2006, 4:33:45 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: Using TextEngine in the Menu

File:
1 copied

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/elements/text_element.h

    r7016 r7019  
    11/*!
    2  * @file image_entity.h
    3  *  Definition of an ImageEntity
     2 * @file text_element.h
     3 *  Definition of an TextElement
    44 */
    55
    6 #ifndef _IMAGE_ENTITY_H
    7 #define _IMAGE_ENTITY_H
     6#ifndef _TEXT_ELEMENT_H
     7#define _TEXT_ELEMENT_H
    88
    99#include "p_node.h"
    10 #include "element_2d.h"
     10#include "text.h"
    1111#include "event_listener.h"
    1212
     
    2020
    2121//! A class that enables the
    22 class ImageEntity : public PNode, public Element2D {
     22class TextElement : public Text {
    2323
    2424 public:
    25   ImageEntity(const TiXmlElement* root = NULL);
    26   virtual ~ImageEntity();
     25  TextElement(const TiXmlElement* root = NULL);
     26  virtual ~TextElement();
    2727
    2828  void init();
    2929  virtual void loadParams(const TiXmlElement* root);
    3030
    31   void setSize(float sizeX, float sizeY);
    32   void setTexture(const char* textureFile);
    33   /** @param rotationSpeed the speed at what the crosshair should rotate */
    34   void setRotationSpeed(float rotationSpeed) { this->rotationSpeed = rotationSpeed; };
    35   void toggleBillboarding();
    36 
    37   virtual void tick(float dt);
    38   virtual void draw() const;
     31  void setText(const char* text);
     32  void setFont(const char* font);
    3933
    4034 private:
    41    Material*        material;             //!< a material for the Aim.
    42    float            rotationSpeed;        //!< Speed of the Rotation.
    43    bool             bBillboarding;        //!< true if billboarding is on
     35
    4436};
    4537
    46 #endif /* _IMAGE_ENTITY_H */
     38#endif /* _TEXT_ELEMENT_H */
Note: See TracChangeset for help on using the changeset viewer.