Class Name: Arc

Superclass - Linear Geometry

Definition

Three locations in space that represent the beginning, mid, and ending points on an Arc. The beginning and ending points are the Vertices, and the mid point is the Location 3D.

Primary Page in DRM Diagram:

Example

A geometric representation of a treeline, or a string of lights that follow the path of the arc (see Light Source).

FAQs

An Arc can be defined in different ways. Rather than using SEDRIS' method of three points that define the beginning, mid, and ending points on an Arc, I define an Arc with a center point, radius, beginning angle, and ending angle. How can I implement this in SEDRIS?
The following formulas show how center point, radius, beginning and ending angles can be derived from the first set of information (beginning, mid, and ending points on the Arc).
        double x1, y1,              /* beginning point */
               x2, y2,              /* mid point */
               x3, y3,              /* ending point */

               sx1, sx2, sx3,       /* squared x values */
               sy1, sy2, sy3,       /* squared y values */
               ad, D, E, F,         /* determinate values */
               dc, ec, fc,          /* coefficient values */

               centerx, centery,    /* center point of arc */
               r,                   /* radius of arc */
               ab, ae;              /* beginning & ending angles */

        /* get squared values */
        sx1 = x1*x1;   sx2 = x2*x2;   sx3 = x3*x3;
        sy1 = y1*y1;   sy2 = y2*y2;   sy3 = y3*y3;

        /* get 'a' determinate */
        ad = x1*(y2 - y3) - y1*(x2-x3) + x2*y3 - x3*y2;

        /* get 'D' determinate */
        D = (sx1 + sy1)*(y2 - y3) - y1*((sx2 + sy2) - (sx3 + sy3))
            + y3*(sx2 + sy2) - y2*(sx3 + sy3);

        /* get 'E' determinate */
        E = (sx1 + sy1)*(x2 - x3) - x1*((sx2 + sy2) - (sx3 + sy3))
            + x3*(sx2 + sy2) - x2*(sx3 + sy3);

        /* get 'F' determinate */
        F = (sx1 + sy1)*(x2*y3 - x3*y2) -
             x1*(y3*(sx2 + sy2) - y2(sx3 + sy3)) +
             y1*(x3*(sx2 + sy2) - x2*(sx3 + sy3));

        D = -D;            F = -F;

        /* check for colinear point */
        if (ad == 0.0) {
            fprintf(stderr, "ERROR! colinear point\n");
            fflush(stderr);
            exit(-1);
        }

        /* get coefficients */
        dc = D/(2.0*ad);
        ec = E/(2.0*ad);
        fc = F/ad;

        /* get center point */
        centerx = -dc;    centery = -ec;

        /* get radius */
        r = sqrt((dc*dc + ec*ec - fc));

        /* get beginning and ending angles */
        ab = atan2(y1 - centery, x1 - centerx);
        ae = atan2(y3 - centery, x3 - centerx);
    

Constraints

Composed of (one-way)(inherited)

Composed of (one-way)

Composed of (two-way)(inherited)

Composed of (two-way)

Composed of (one-way metadata)(inherited)

Component of (two-way)(inherited)

Inherited Field Elements

SE_UINT16 count; (notes)
SE_BOOLEAN suppressLast; (notes)

Notes

Fields Notes

count

 the number of evenly divided segments/points along the
 <Linear Geometry>. The default value of 0 indicates that
 the <Linear Geometry> is solid.

suppressLast

 flag indicating whether the last segment/point is suppressed.

Prev: Animation Related Geometry. Next: Areal Feature. Up:Index.