lab 5 part 2 complete
This commit is contained in:
@@ -20,23 +20,31 @@ class Shape{
|
||||
public:
|
||||
// Constructor
|
||||
Shape();
|
||||
|
||||
// Copy Constructor
|
||||
Shape(const Shape& from);
|
||||
|
||||
// Destructor
|
||||
virtual ~Shape();
|
||||
|
||||
// Draw shape
|
||||
virtual void draw(GraphicsContext *gc) = 0;
|
||||
|
||||
// Print to output stream
|
||||
virtual void out(std::ostream& os)const = 0;
|
||||
|
||||
// Virtual Constructor
|
||||
virtual Shape* clone() = 0; // Pure virtual "=0"
|
||||
protected:
|
||||
// Matrix containing the coords of each point in the shape
|
||||
Matrix* coords;
|
||||
|
||||
// RGB color
|
||||
uint32_t color;
|
||||
|
||||
// Assignment Operator
|
||||
virtual Shape& operator=(const Shape& rhs);
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user