Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/orxonox/trunk/src/glmenu/glmenu_imagescreen.h @ 4110

Last change on this file since 4110 was 4104, checked in by bensch, 20 years ago

orxonox/trunk: loadScreen now loadable as well

File size: 1.4 KB
Line 
1/*!
2    \file glmenu_imagescreen
3    \brief class to display a image
4*/
5
6
7#ifndef _GLMENU_IMAGESCREEN_H
8#define _GLMENU_IMAGESCREEN_H
9
10#include "base_object.h"
11
12class Material;
13class TiXmlElement;
14
15class GLMenuImageScreen : public BaseObject {
16
17 public:
18  GLMenuImageScreen ();
19  GLMenuImageScreen (TiXmlElement* root);
20  void load(TiXmlElement* root);
21  virtual ~GLMenuImageScreen ();
22
23  void init ();
24
25  void draw ();
26 
27  void setBackgroundImage(const char* backImageName);
28  void setPosition(float offsetX, float offsetY);
29  void setScale (float scaleX, float scaleY);
30
31  void setBarImage(const char* barImage);
32  void setBarPosScale(float barX, float barY, float barW, float barH);
33
34  void setMaximum (int maxValue);
35  int getMaximum ();
36  void setValue (int currentValue);
37  int getValue ();
38  void step ();
39
40 private:
41  char* backImageName;       //!< the name of the file of the background image
42  float scaleX, scaleY;      //!< hight and width of the image
43  float offsetX, offsetY;    //!< offset of the image from left and up
44  Material* backMat;         //!< Background Material.
45  float barX, barY, barW, barH; //!< Position and Scale of the bar.
46  Material* barMat;          //!< A Material for the Loading-Bar
47
48  /* progress bar values */
49  int currentValue;          //!< the current count of step() calls fired yet
50  int maxValue;              //!< total count of steps
51
52};
53
54#endif /* _GLMENU_IMAGESCREEN_H */
Note: See TracBrowser for help on using the repository browser.