Enum Class TLcdAWTPath.WindingRule

java.lang.Object
java.lang.Enum<TLcdAWTPath.WindingRule>
com.luciad.view.gxy.TLcdAWTPath.WindingRule
All Implemented Interfaces:
Serializable, Comparable<TLcdAWTPath.WindingRule>, Constable
Enclosing class:
TLcdAWTPath

public static enum TLcdAWTPath.WindingRule extends Enum<TLcdAWTPath.WindingRule>
Specifies how the interior of a shape is determined for self-intersecting polygons, i.e. how to calculate whether a point is outside or inside the shape.
  • Enum Constant Details

    • WIND_EVEN_ODD

      public static final TLcdAWTPath.WindingRule WIND_EVEN_ODD
      The odd-even winding rule typically does not fill overlapping regions in self-intersecting polygons.

      The rule is as follows: for a given point, draw a straight line from that point in any direction towards infinity. Find all the intersections of the shape with this line. If this number is odd, the point is inside; if even, the point is outside.

    • WIND_NON_ZERO

      public static final TLcdAWTPath.WindingRule WIND_NON_ZERO
      The non-zero winding rule typically fills overlapping regions in self-intersecting polygons.

      The rule is as follows: for a given point, draw a straight line from that point in any direction towards infinity. Find all the intersections of the shape with this line. Score up the winding number as follows: for every clockwise intersection (the shape passing through the ray from left to right, as viewed from the point) subtract 1; for every counter-clockwise intersection (shape passing from right to left, as viewed from the point) add 1. If the total winding number is zero, the point is outside the shape; otherwise, it is inside.

  • Method Details

    • values

      public static TLcdAWTPath.WindingRule[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static TLcdAWTPath.WindingRule valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null