Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 20, 2006, 1:27:38 PM (19 years ago)
Author:
stefalie
Message:

water: cleanup… and hey: the mighty reflection is back :-)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/water/src/world_entities/environments/mapped_water.h

    r8617 r8622  
    33 *
    44*/
    5 /* example input in .oxw file
     5/* example input in .oxw file with the standard values
    66<MappedWater>
    7   <waterpos>-500,0,-500</waterpos>
    8   <watersize>1000,1000</watersize>
    9   <wateruv>10</wateruv>
    10   <waterflow>0.003</waterflow>
    11   <lightpos>100,150,100</lightpos>
    12 </MappedWater> */
     7  <waterpos>0,0,0</waterpos>
     8  <watersize>100,100</watersize>
     9  <wateruv>9</wateruv><!-- size of the waves -->
     10  <waterflow>0.08</waterflow>
     11  <lightpos>0,10,0</lightpos>
     12  <waterangle>0</waterangle>
     13  <normalmapscale>0.25</normalmapscale><!-- you won't see a big differnce if you change that -->
     14</MappedWater>
     15*/
    1316
    1417
     
    4144
    4245    // functions to set parameters for the water, usually they're called through loadparam
    43     void setLightPosition(float x, float y, float z) { this->lightPos = Vector(x,y,z); };
     46    void setLightPos(float x, float y, float z) { this->lightPos = Vector(x,y,z); };
    4447    void setWaterPos(float x, float y, float z) { this->waterPos = Vector(x,y,z); };
    4548    void setWaterSize(float x, float z) { this->xWidth = x; this->zWidth = z; };
     49    void setWaterAngle(float angle) { this->waterAngle = angle; };
    4650    void setWaterUV(float uv) { this->waterUV = uv; };
    4751    void setWaterFlow(float flow) { this->waterFlow = flow; };
     
    5559    float               xWidth, zWidth;             //!< size of the water quad
    5660    Vector              lightPos;                   //!< position of the light that is used to render the reflection
     61    float               waterAngle;                 //!< defines how much the water will be turned around the point waterPos
    5762
    5863    float               move;                       //!< textures coords, speeds, positions for the shaded textures....
Note: See TracChangeset for help on using the changeset viewer.