// // Computergraphik II // Prof. Dr. Juergen Doellner // Wintersemester 2001/02 // // Rahmenprogramm zu Aufgabenzettel 9 // #ifndef CG_TEXTURE_H #define CG_TEXTURE_H #include "cgapplication.h" #include "vector.h" class CGTexture : public CGApplication { public: CGTexture(); virtual ~CGTexture(); virtual void onInit(); virtual void onDraw(); virtual void onIdle(); virtual void onKey(unsigned char key); virtual void onSize(unsigned int newWidth, unsigned int newHeight); void readImage(); // value Methode unsigned char value(int x, int z) const; private: void drawScene(); void drawObject(); void buildPatch(int detail); void createNoiseTexture3D(); // Dimensionen des Viewports int width_; int height_; // Display-List GLint torus_; bool usetorus_; // Zoom double zoom_; // Dimensionen der Textur int texWidth_; int texHeight_; int texDepth_; // Texture ID GLuint texName1_; GLuint texName2_; GLuint texName3_; // Rotation bool run_; }; #endif // CG_WAVE_H