+
+void glDisplayFunc()
+{
+ glClear(GL_COLOR_BUFFER_BIT);
+
+ seaView->setupView();
+ sea->update();
+ surface->draw();
+
+ glutSwapBuffers();
+ glutPostRedisplay();
+}
+
+void glReshapeFunc(int width, int height)
+{
+ glMatrixMode(GL_PROJECTION);
+ glLoadIdentity();
+ gluPerspective(50.0, ((float)width/(float)height), 0, 1000.0);
+ glViewport(0, 0, width, height);
+}
+
+void glMouseFunc(int button, int state, int x, int y)
+{
+ seaView->onMouseEvent(button, state, x, y);
+}
+
+void glMotionFunc(int x, int y)
+{
+ seaView->onMouseMove(x, y);
+}