Definition of a sphere. More...
#include <shapes.h>
Public Member Functions | |
virtual Shape * | clone () const |
Create a copy of this shape. | |
virtual void | print (std::ostream &out=std::cout) const |
Print information about this shape. | |
virtual void | scaleAndPadd (double scale, double padd) |
Scale and padd this shape. | |
Sphere () | |
Sphere (double r) | |
The radius of the shpere. | |
Public Attributes | |
double | radius |
The radius of the sphere. | |
Static Public Attributes | |
static const std::string | STRING_NAME = "sphere" |
The type of the shape, as a string. |
Definition at line 59 of file shapes.cpp.
shapes::Sphere::Sphere | ( | double | r | ) |
The radius of the shpere.
Definition at line 65 of file shapes.cpp.
shapes::Shape * shapes::Sphere::clone | ( | ) | const [virtual] |
void shapes::Sphere::print | ( | std::ostream & | out = std::cout | ) | const [virtual] |
Print information about this shape.
Reimplemented from shapes::Shape.
Definition at line 321 of file shapes.cpp.
void shapes::Sphere::scaleAndPadd | ( | double | scale, |
double | padd | ||
) | [virtual] |
double shapes::Sphere::radius |
const std::string shapes::Sphere::STRING_NAME = "sphere" [static] |