From e33e19d0587146859d48a134ec9fd94e7b7ba5cd Mon Sep 17 00:00:00 2001 From: "FWoltermann@gmail.com" Date: Thu, 8 Dec 2011 14:53:40 +0000 Subject: Initial upload --- nGenEx/Water.h | 54 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) create mode 100644 nGenEx/Water.h (limited to 'nGenEx/Water.h') diff --git a/nGenEx/Water.h b/nGenEx/Water.h new file mode 100644 index 0000000..2f88db0 --- /dev/null +++ b/nGenEx/Water.h @@ -0,0 +1,54 @@ +/* Project nGenEx + Destroyer Studios LLC + Copyright © 1997-2006. All Rights Reserved. + + SUBSYSTEM: nGen.lib + FILE: Water.h + AUTHOR: John DiCamillo + + + OVERVIEW + ======== + Water surface effect w/ reflection and refraction +*/ + +#ifndef Water_h +#define Water_h + +#include "Geometry.h" +#include "Polygon.h" +#include "Color.h" + +// +--------------------------------------------------------------------+ + +struct WATER_SURFACE; + +// +--------------------------------------------------------------------+ + +class Water +{ +public: + Water(); + virtual ~Water(); + + virtual void Init(int nVerts, float size, float depth); + virtual void CalcWaves(double seconds); + virtual void UpdateSurface(Vec3& eyePos, VertexSet* vset); + +protected: + float size; + float depth; + float scaleTex; + float avgHeight; + + DWORD nVertices; + + WATER_SURFACE* surface; + float* waves; + float offsets[16]; +}; + +// +--------------------------------------------------------------------+ + +#endif Water_h + -- cgit v1.1