u02/tool_base: Add draw with three points

Simon Bruder 2023-05-07 15:23:49 +02:00
parent 0fae793f28
commit edb9e7400c
Signed by: simon
GPG Key ID: 8D3C82F9F309F8EC
2 changed files with 8 additions and 0 deletions

View File

@ -41,6 +41,8 @@ public:
virtual void draw(int x, int y);
// Draw with two points provided
virtual void draw(int x0, int y0, int x1, int y1);
// Draw with three points provided
virtual void draw(int x0, int y0, int x1, int y1, int x2, int y2);
// Get the shape that this tool will draw
const ToolShape get_shape() const;

View File

@ -29,6 +29,12 @@ void tool_base::draw(int from_x, int from_y, int to_x, int to_y) {
// this method if needed
}
// Draw with three points provided
void tool_base::draw(int x0, int y0, int x1, int y1, int x2, int y2) {
// Nothing implemented here. Children of this class can implement
// this method if needed
}
// Get the shape that this tool will draw
const ToolShape tool_base::get_shape() const { return shape; }