Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/branches/water/src/world_entities/environments/mapped_water.h @ 7740

Last change on this file since 7740 was 7740, checked in by patrick, 18 years ago

water: the stuff is drawn twice now, there where some logical errors in the code. not yet drawn on the texture i'm afraid

File size: 803 bytes
Line 
1/*!
2 * @file mapped_water.h
3 *
4*/
5
6#ifndef _MAPPED_WATER_H
7#define _MAPPED_WATER_H
8
9/* INCLUDES */
10#include "world_entity.h"
11#include "material.h"
12#include "texture.h"
13
14
15class MappedWater : public WorldEntity
16{
17  public:
18    MappedWater(const TiXmlElement* root = NULL);
19    virtual ~MappedWater();
20
21    void loadParams(const TiXmlElement* root);
22
23    void activateReflection();
24    void deactivateReflection();
25
26    void activateRefraction();
27    void deactivateRefraction();
28
29    void draw() const;
30    void tick(float dt);
31
32  private:
33    void setHeight(float height);
34
35  private:
36    float           waterHeight;       //!< y-coord of the Water
37    Material        mat;
38
39    Texture         texture;
40    int             textureSize;       //!< size of the texture
41
42};
43
44#endif  /* _MAPPED_WATER_H */
Note: See TracBrowser for help on using the repository browser.