codac 2.0.0
|
Interface for 2D figures. More...
#include <codac2_Figure2DInterface.h>
Public Member Functions | |
virtual void | draw_point (const Vector &c, const StyleProperties &s=StyleProperties())=0 |
Draws a point on the figure. | |
virtual void | draw_box (const IntervalVector &x, const StyleProperties &s=StyleProperties())=0 |
Draws a box on the figure. | |
virtual void | draw_circle (const Vector &c, double r, const StyleProperties &s=StyleProperties())=0 |
Draws a circle on the figure. | |
virtual void | draw_ring (const Vector &c, const Interval &r, const StyleProperties &s=StyleProperties())=0 |
Draws a ring on the figure. | |
virtual void | draw_polyline (const std::vector< Vector > &x, float tip_length, const StyleProperties &s=StyleProperties())=0 |
Draws a polyline on the figure. | |
virtual void | draw_polygon (const std::vector< Vector > &x, const StyleProperties &s=StyleProperties())=0 |
Draws a polygone on the figure. | |
virtual void | draw_pie (const Vector &c, const Interval &r, const Interval &theta, const StyleProperties &s=StyleProperties())=0 |
Draws a pie on the figure. | |
virtual void | draw_ellipse (const Vector &c, const Vector &ab, double theta, const StyleProperties &s=StyleProperties())=0 |
Draws an ellipse on the figure. | |
virtual void | draw_tank (const Vector &x, float size, const StyleProperties &s=StyleProperties())=0 |
Draws a tank on the figure. | |
virtual void | draw_AUV (const Vector &x, float size, const StyleProperties &s=StyleProperties())=0 |
Draws an AUV on the figure. | |
virtual void | draw_motor_boat (const Vector &x, float size, const StyleProperties &s=StyleProperties())=0 |
Draws a motor boat on the figure. | |
Interface for 2D figures.
This class is used to display 2D figures. It defines the basic drawing functions.
This class is purely virtual and should not be used directly. It is used as an interface for the Figure2D class.
This interface contains the “low-level” methods that need to be overloaded to implement graphic primitives in the output view. The Figure2D class may contain methods not listed here: these methods are more “high-level” and do not require a specific implementation related to the graphic tool. For example, Figure2D::draw_line calls Figure2D::draw_polyline (a line is a special case of a two-point polyline), so only draw_polyline needs to be implemented in this interface.
|
pure virtual |
Draws a point on the figure.
c | Coordinates of the point |
s | Style of the point (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws a box on the figure.
x | Box to draw |
s | Style of the box (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws a circle on the figure.
c | Center of the circle |
r | Radius of the circle |
s | Style of the circle (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws a ring on the figure.
c | Center of the ring |
r | Inner and outer radius of the ring |
s | Style of the ring (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws a polyline on the figure.
x | Vector of the points of the polyline |
tip_length | Length of the tip of the arrow |
s | Style of the polyline (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws a polygone on the figure.
x | Vector of the points of the polygone |
s | Style of the polygone (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws a pie on the figure.
c | Center of the pie |
r | Inner and outer radius of the pie |
theta | Start and end angle of the pie (in radians) |
s | Style of the pie (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws an ellipse on the figure.
c | Center of the ellipse |
ab | Half-lengths of the ellipse |
theta | Rotation angle of the ellipse (in radians) |
s | Style of the ellipse (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws a tank on the figure.
x | Coordinates of the tank |
size | Size of the tank |
s | Style of the tank (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws an AUV on the figure.
x | Coordinates of the AUV |
size | Size of the AUV |
s | Style of the AUV (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.
|
pure virtual |
Draws a motor boat on the figure.
x | Coordinates of the motor boat |
size | Size of the motor boat |
s | Style of the motor boat (edge color and fill color) |
Implemented in codac2::Figure2D_IPE, and codac2::Figure2D_VIBes.