ID_CANVAS = FXMainWindow::ID_LAST,
ID_LAST
};
-
+
+
/**
* Constructor
- * @param application the FOX application object
- * @param lsystem the Lindenmayer-system
+ * @param application the application object
*/
- RenderingSurface(FXApp *application, LindenmayerSystem *lsystem);
-
+ RenderingSurface(FXApp *application);
+
+ /**
+ * Destructor
+ */
+ virtual ~RenderingSurface();
+
+
/**
* Create and initialize the window
*/
- void create();
+ virtual void create();
/**
* Initialize OpenGL
*/
void draw();
+
/**
* Called by the system when the left mouse button is pressed
* @param sender the sender object
* @return
*/
long onRepaint(FXObject *sender, FXSelector selector, void *data);
+
+ /**
+ * Called by the system when the close button is pressed
+ * @param sender the sender object
+ * @param selector message type and id
+ * @param data event related data
+ * @return
+ */
+ long onQuit(FXObject *sender, FXSelector selector, void *data);
+
+
+ /**
+ * Set current L-system generator
+ * @param lsystem the L-system generator
+ */
+ void setLSystem(LindenmayerSystem *lsystem);
protected:
*/
RenderingSurface() {}
-private:
FXGLVisual *_visual; // Pixel format info
FXGLCanvas *_canvas; // OpenGL-capable drawing area
- LindenmayerSystem *_lsystem; // The Lindenmayer System
+ LindenmayerSystem *_lsystem; // The Lindenmayer system generator
+
// Model position
double _modelX,