GINO Graphics Suite - GINO v9.0  

gDrawArc

Syntax

[C/C++:]
void gDrawArcBy2D(float dxc, float dyc, float dxe, float dye, int sense);
void gDrawArcBy3D(float dxc, float dyc, float dzc,float dxe, float dye, float dze,float dxt, float dyt, float dzt);
void gDrawArcTo2D(float xc, float yc, float xe, float ye, int sense);
void gDrawArcTo3D(float xc, float yc, float zc,float xe, float ye, float ze, float dxt, float dyt, float dzt);
[F90:]
subroutine gDrawArcBy2D(dxc, dyc, dxe, dye, sense)
subroutine gDrawArcBy3D(dxc, dyc, dzc, dxe, dye, dze, dxt, dyt, dzt)
subroutine gDrawArcTo2D(xc, yc, xe, ye, sense)
subroutine gDrawArcTo3D(xc, yc, zc, xe, ye, ze, dxt, dyt, dzt)

real, intent(in) :: dxc,dyc,dzc,dxe,dye,dze,dxt,dyt,dzt
real, intent(in) :: xc,yc,zc,xe,ye,ze
integer, intent(in) :: sense

Arguments

dxc,dyc,dzc,xc,yc,zc
Position of the arc centre defined as either relative to the current drawing position or an absolute position

dxe,dye,dze,xe,ye,ze
A relative or absolute position defining a vector from the arc's centre on which the arc will terminate

sense
Direction of drawing

= GANTICLOCKWISE, The arc is drawn positively
= GCLOCKWISE, The arc is drawn negatively

dxt,dyt,dzt
Direction vector defining the starting direction or plane of a 3D arc

Description

These routines draw a two or three dimensional circular arc using relative or absolute coordinates to define its centre and end positions. Where relative positions are given, these are relative to the current drawing position.

The drawing of all arcs start at the current drawing position and have a radius equal to the distance from the start to the specified centre position. The arc is terminated at a point that lies on a line from the specified arc centre through the specified end point.

For 2D arcs, the direction of drawing is given by sense, but for 3D arcs, the start direction is indicated by the direction vector (dxt,dyt,dzt) . If the start, centre and end points are collinear the direction vector gives the plane of the arc, otherwise it merely indicates whether the major or minor arc is required. If the direction vector is parallel to this same line, an error message is output and no arc is output.

If transformations are being used, it is essential that the current drawing position is set by a routine using absolute coordinates (e.g. gMoveTo2D/3D()) after the transformation is changed and before gDrawArcTo2D/3D() is called.

If the output device cannot support hardware arcs or if software arcs have been requested by calling gSetArcMode(), the arc is drawn as a series of straight vectors. However, sufficient vectors are provided to give the curve a smooth appearance.

See Also

gDrawArcxx2D Usage
gDrawArcxx3D Usage
gSetArcMode