23 this->operator=(sphere);
29 radius = sphere.radius;
30 material = sphere.material;
54 bBox.SetSmallerX(-radius);
55 bBox.SetSmallerY(-radius);
56 bBox.SetSmallerZ(-radius);
57 bBox.SetGreaterX(radius);
58 bBox.SetGreaterY(radius);
59 bBox.SetGreaterZ(radius);
65 GLUquadricObj* qObj = gluNewQuadric();
70 if( material.GetTexture().HasData() )
72 gluQuadricTexture(qObj,GL_TRUE);
74 result = material.DrawOGL();
75 gluQuadricDrawStyle(qObj, GLU_FILL);
76 gluQuadricNormals(qObj, GLU_SMOOTH);
77 gluSphere(qObj, radius, 15, 15);
78 gluDeleteQuadric(qObj);
81 bBox.DrawInstanceOGL();
83 recBBox.DrawInstanceOGL();
Base class for objects that compose a scene graph.
virtual VART::SceneNode * Copy()
Returns a copy of an Sphere. Every derived class must reimplements this method, to avoid errors with ...
Header file for V-ART class "Sphere".
bool DrawInstanceOGL() const
Draws the sphere using OpenGL engine.
An scene node that is associated with a shape.
SceneNode & operator=(const SceneNode &node)
virtual void ComputeBoundingBox()
Computes the bounding box.
VART::Sphere & operator=(const VART::Sphere &sphere)
Copies all Sphere data to another sphere.