1 //
2 // Computergraphik II
3 // Prof. Dr. Juergen Doellner
4 // Wintersemester 2001/2002
5 //
6 // Rahmenprogramm fuer Aufgabenzettel 3
7 //
8 // Autoren: Florian Kirsch (kirsch@hpi.uni-potsdam.de)
9 // Marc Nienhaus (nienhaus@hpi.uni-potsdam.de)
10 // Juergen Doellner (doellner@hpi.uni-potsdam.de)
11 //
12
13 #ifndef CG_HSVCOLORS_H
14 #define CG_HSVCOLORS_H
15
16 #include "cgapplication.h"
17 #include "cgraster.h"
18
19 class CGHSVColors : public CGApplication {
20 public:
21 CGHSVColors(int width, int height);
22
23 virtual void onInit();
24 virtual void onDraw();
25 virtual void onSize(unsigned int newWidth,unsigned int newHeight);
26 virtual void onKey(unsigned char key);
27 virtual void onIdle();
28
29 virtual void onButton(MouseButton button, int x, int y);
30
31 enum { SHOWNCOLORS = 128 };
32
33 private:
34
35 enum MODE { DrawGrid, DrawCube };
36 MODE mode_;
37
38 // interne Raster-Klasse
39 CGRaster raster_;
40
41 // Fenstergroesse speichern
42 int winWidth_;
43 int winHeight_;
44 int hSubWindow;
45
46 Color clrFrom;
47 Color clrTo;
48
49 bool run_;
50 double angle_;
51
52 };
53
54 #endif // CG_HSVCOLORS_H
55
56