]> Dogcows Code - chaz/yoink/blobdiff - src/Moof/Sphere.cc
new lua scripting for scene loading
[chaz/yoink] / src / Moof / Sphere.cc
index 97298323a61efb9590c67ca7b0e84571403485d2..5e43e0d42e414a60c7ab394e7ae1804203648322 100644 (file)
@@ -41,7 +41,17 @@ void Sphere::encloseVertices(const Vector3 vertices[], unsigned count)
 
 void Sphere::draw(Scalar alpha) const
 {
-       // TODO
+       GLUquadricObj* sphereObj = gluNewQuadric();
+       gluQuadricDrawStyle(sphereObj, GLU_LINE);
+
+       glPushMatrix();
+
+       glTranslate(point[0], point[1], point[2]);
+       gluSphere(sphereObj, (GLdouble)radius, 16, 16);
+
+       glPopMatrix();
+
+       gluDeleteQuadric(sphereObj);
 }
 
 bool Sphere::isVisible(const Frustum& frustum) const
This page took 0.020018 seconds and 4 git commands to generate.