// // Computergraphik II // Prof. Dr. Juergen Doellner // Wintersemester 2001/02 // // Rahmenprogramm zu Aufgabenzettel 5 // #ifndef CG_WAVE_H #define CG_WAVE_H #include "cgapplication.h" #include "vector.h" class CGWave : public CGApplication { public: CGWave(); virtual ~CGWave(); // Ueberschreibe alle diese Ereignisse: virtual void onInit(); virtual void onDraw(); virtual void onIdle(); virtual void onKey(unsigned char key); virtual void onSize(unsigned int newWidth, unsigned int newHeight); // value Methode unsigned char value(int x, int z) const; private: void drawScene(); void drawObject(); void buildPatch(int detail); void handleVertex(const Vector& v) const; Vector WavedNormal(const Vector& v) const; int width_; int height_; double zoom_; double rot_; double periode_; bool culling_; bool run_; bool showNormals_; bool periodAnim_; bool lightAnim_; int num_; Vector* list_; }; #endif // CG_WAVE_H