Sat, 16 Mar 2013 13:08:24 +0200
Convert the static getCoordinateRep to a common ftoa, use this function to get proper coordinate representation when converting objects to LDraw code
#ifndef __REND_H__ #define __REND_H__ #include <QGLWidget> #include "common.h" #include "ldtypes.h" class renderer : public QGLWidget { Q_OBJECT public: renderer(QWidget* parent = NULL); void hardRefresh (); void CompileObjects (); double fRotX, fRotY, fRotZ; QPoint lastPos; double fZoom; protected: void initializeGL (); void resizeGL (int w, int h); void paintGL (); void mouseMoveEvent (QMouseEvent *event); private: GLuint objlist; void CompileOneObject (LDObject* obj); void ClampAngle (double& fAngle); }; #endif