Class Circle2ai.CirclePerimeterIterator<P extends Point2D<? super P,​? super V>,​V extends Vector2D<? super V,​? super P>>

  • Type Parameters:
    P - the type of the points.
    V - the type of the vectors.
    All Implemented Interfaces:
    Iterator<P>
    Enclosing interface:
    Circle2ai<ST extends Shape2ai<?,​?,​IE,​P,​V,​B>,​IT extends Circle2ai<?,​?,​IE,​P,​V,​B>,​IE extends PathElement2ai,​P extends Point2D<? super P,​? super V>,​V extends Vector2D<? super V,​? super P>,​B extends Rectangle2ai<?,​?,​IE,​P,​V,​B>>

    public static class Circle2ai.CirclePerimeterIterator<P extends Point2D<? super P,​? super V>,​V extends Vector2D<? super V,​? super P>>
    extends Object
    implements Iterator<P>
    Iterates on points on the perimeter of a circle.

    The rastrerization is based on a Bresenham algorithm.

    Since:
    13.0
    Version:
    17.0 2020-01-04 14:41:43
    Author:
    Stéphane GALLAND
    Maven Group Id:
    org.arakhne.afc.core
    Maven Artifact Id:
    mathgeom
    • Constructor Detail

      • CirclePerimeterIterator

        public CirclePerimeterIterator​(GeomFactory2D<V,​P> factory,
                                       int centerX,
                                       int centerY,
                                       int radius,
                                       int initialOctant,
                                       int lastOctant,
                                       boolean skip)
        Construct the iterator from the initialOctant (inclusive) to the lastOctant (exclusive).
        Parameters:
        factory - the point factory.
        centerX - the x coordinate of the center of the circle.
        centerY - the y coordinate of the center of the circle.
        radius - the radius of the circle.
        initialOctant - the octant from which the iteration must start.
        lastOctant - the first octant that must not be iterated on.
        skip - indicates if the first point on an octant must be skip, because it is already replied when treating the previous octant.