#include <polyver.h>


Public Member Functions | |
| a2dArcSegment (double x1=0, double y1=0, double x2=0, double y2=0) | |
| create arc segment | |
| a2dArcSegment (const a2dLineSegment &prev, double xc, double yc, double angle) | |
| create arc segment | |
| a2dArcSegment (const a2dLineSegment &prev, double xc, double yc, double x1, double y1, double x2, double y2) | |
| create arc segment | |
| a2dArcSegment (const a2dArcSegment &other) | |
| copy constructor | |
| ~a2dArcSegment () | |
| destructor | |
| virtual a2dLineSegment * | Clone () |
| create exact copy | |
| bool | CalcR (const a2dLineSegment &prev, double &radius, double ¢er_x, double ¢er_y, double &beginrad, double &midrad, double &endrad, double &phit) const |
| Calculation of center for the Arc. | |
| virtual double | Length (const a2dLineSegment &prev) |
| calculate length | |
| void | CalcMidPoint (const a2dLineSegment &prev, double center_x, double center_y, double radius, bool clockwise) |
| calculate new mid point bsed on prev segment radius and center. | |
| a2dPoint2D | GetMidPoint () const |
| get middle on arc segment between end and start | |
| void | SetMidPoint (const a2dLineSegment &prev, double xm, double ym) |
| set middle point of arc segment | |
| double | GetOx (const a2dLineSegment &prev) const |
| Get origin X of arc. | |
| double | GetOy (const a2dLineSegment &prev) const |
| Get origin Y of arc. | |
| a2dPoint2D | GetOrigin (const a2dLineSegment &prev) const |
| Get origin of arc. | |
| a2dBoundingBox | GetBbox (const a2dLineSegment &prev, const a2dAffineMatrix &lworld=a2dIDENTITY_MATRIX) const |
| Get bounding box of arc. | |
Public Attributes | |
| double | m_x2 |
| x2 x of arc midpoint | |
| double | m_y2 |
| y2 y of arc midpoint | |
Create an circular Arc segment. From the previous segment to this segment position, create an arc passing through a thrid point. The Third point defines the Arc segment going clockwise or anticlockwise from begin to end point.
Definition at line 366 of file polyver.h.
| a2dArcSegment::a2dArcSegment | ( | double | x1 = 0, |
|
| double | y1 = 0, |
|||
| double | x2 = 0, |
|||
| double | y2 = 0 | |||
| ) |
create arc segment
Begin point of arc is position/endpoint of previous segment
| x1 | x of arc endpoint | |
| y1 | y of arc endpoint | |
| x2 | x of arc midpoint | |
| y2 | y of arc midpoint |
Definition at line 299 of file polyver.cpp.
| a2dArcSegment::a2dArcSegment | ( | const a2dLineSegment & | prev, | |
| double | xc, | |||
| double | yc, | |||
| double | angle | |||
| ) |
create arc segment
Begin point of arc is position/endpoint of previous segment
| prev | previous segment | |
| xc | x of arc center | |
| yc | y of arc center | |
| angle | angle of arc in degrees relative from the previous segment endpoint (negatif for clockwise) |
Definition at line 307 of file polyver.cpp.
| a2dArcSegment::a2dArcSegment | ( | const a2dLineSegment & | prev, | |
| double | xc, | |||
| double | yc, | |||
| double | x1, | |||
| double | y1, | |||
| double | x2, | |||
| double | y2 | |||
| ) |
create arc segment
Begin point of arc is position/endpoint of previous segment
| prev | previous segment | |
| xc | x of arc center | |
| yc | y of arc center | |
| x1 | x of arc endpoint | |
| y1 | y of arc endpoint | |
| x2 | x (xc,yc) ( x2,y2) define a line which the arc will cross | |
| y2 | y (xc,yc) ( x2,y2) define a line which the arc will cross |
Definition at line 325 of file polyver.cpp.
| bool a2dArcSegment::CalcR | ( | const a2dLineSegment & | prev, | |
| double & | radius, | |||
| double & | center_x, | |||
| double & | center_y, | |||
| double & | beginrad, | |||
| double & | midrad, | |||
| double & | endrad, | |||
| double & | phit | |||
| ) | const |
Calculation of center for the Arc.
output :
| prev | the previous segment, to get start point of arc. | |
| radius | radius of the circle calculated | |
| center_x | x of the center calculated | |
| center_y | y of the center calculated | |
| beginrad | calculated starting angle in radians | |
| midrad | calculated middle angle in radians | |
| endrad | calculated end angle in radians | |
| phit | total calculated in radians (AntiClockwise positif, else negatif ) |
Definition at line 408 of file polyver.cpp.
| void a2dArcSegment::CalcMidPoint | ( | const a2dLineSegment & | prev, | |
| double | center_x, | |||
| double | center_y, | |||
| double | radius, | |||
| bool | clockwise | |||
| ) |
calculate new mid point bsed on prev segment radius and center.
| prev | the previous segment, to get start point of arc. | |
| radius | radius of the circle calculated | |
| center_x | x of the center calculated | |
| center_y | y of the center calculated | |
| clockwise | if true a clockwise arc segment is assumed for creating the mid point |
Definition at line 386 of file polyver.cpp.
| void a2dArcSegment::SetMidPoint | ( | const a2dLineSegment & | prev, | |
| double | xm, | |||
| double | ym | |||
| ) |
set middle point of arc segment
| prev | the previous segment, to get start point of arc. | |
| xm | x of middle point | |
| ym | y of middle point |
Definition at line 359 of file polyver.cpp.