diff options
Diffstat (limited to 'src/glsphere.h')
| -rw-r--r-- | src/glsphere.h | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/glsphere.h b/src/glsphere.h new file mode 100644 index 0000000..9aae032 --- /dev/null +++ b/src/glsphere.h @@ -0,0 +1,29 @@ +#ifndef GLSPHERE_H +#define GLSPHERE_H + +#include <cmath> + +#include "glbody.h" + + +class GLSphere : public GLBody +{ +public: + GLSphere(double radius = 1.0, int stacks = 10, int slices = 10); + virtual void makeSurface(QVector<GLPoint> *pointContainer, + QVector<GLshort> *indexContainer); + +private: + /** + * @brief calculatePoint + * @param zRotation + * @param yRotation + * @return + */ + QVector3D calculatePoint(double sliceRotation, double stackRotation); + + int m_stacks; + int m_slices; +}; + +#endif // GLSPHERE_H |
