Last change
on this file since 4842 was
4840,
checked in by bensch, 20 years ago
|
orxonox/trunk: more definitions for element2D
|
File size:
1.0 KB
|
Line | |
---|
1 | /*! |
---|
2 | * @file element_2d.h |
---|
3 | * @brief Definition of the 2D elements rendered on top through the GraphicsEngine |
---|
4 | */ |
---|
5 | |
---|
6 | #ifndef _ELEMENT_2D_H |
---|
7 | #define _ELEMENT_2D_H |
---|
8 | |
---|
9 | #include "base_object.h" |
---|
10 | |
---|
11 | // FORWARD DECLARATION |
---|
12 | |
---|
13 | //!< An enumerator defining the Depth of a 2D-element. |
---|
14 | typedef enum |
---|
15 | { |
---|
16 | E2D_TOP, //!< Will be rendered on top of everything else |
---|
17 | E2D_MEDIUM, //!< Will be rendered on the medium Layer. |
---|
18 | E2D_BOTTOM, //!< Will be rendered on the bottom Layer |
---|
19 | E2D_BELOW_ALL //!< Will be rendered below the 3D-scene. @todo make this work. |
---|
20 | } E2DLayer; |
---|
21 | |
---|
22 | //! A class for ... |
---|
23 | class Element2D : public BaseObject { |
---|
24 | |
---|
25 | public: |
---|
26 | Element2D(); |
---|
27 | virtual ~Element2D(); |
---|
28 | |
---|
29 | |
---|
30 | void setPosition(int xCoord, int yCoord); |
---|
31 | void setLayer(E2DLayer layer); |
---|
32 | |
---|
33 | |
---|
34 | virtual void draw() const = NULL; |
---|
35 | |
---|
36 | private: |
---|
37 | bool visible; |
---|
38 | int position2D[2]; //!< X-coord, Y-Coord |
---|
39 | E2DLayer layer; |
---|
40 | |
---|
41 | }; |
---|
42 | |
---|
43 | |
---|
44 | #endif /* _ELEMENT_2D_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.