lab 5 part 2 complete

This commit is contained in:
2022-05-10 01:45:01 -05:00
parent 780c2bba3c
commit 6a425d5300
10 changed files with 345 additions and 102 deletions

View File

@@ -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