Class BoundingBox

java.lang.Object
com.fs.starfarer.api.impl.campaign.velfield.BoundingBox

public class BoundingBox extends Object
  • Field Details

    • points

      protected transient List<org.lwjgl.util.vector.Vector2f> points
    • convexHull

      protected transient List<org.lwjgl.util.vector.Vector2f> convexHull
    • box

      protected List<org.lwjgl.util.vector.Vector2f> box
    • padding

      protected float padding
    • rotatedBox

      protected float[] rotatedBox
    • angle

      protected float angle
    • boxComputed

      protected boolean boxComputed
    • center

      protected org.lwjgl.util.vector.Vector2f center
    • radius

      protected float radius
  • Constructor Details

    • BoundingBox

      public BoundingBox(float padding)
  • Method Details

    • create

    • pointNeedsDetailedCheck

      public boolean pointNeedsDetailedCheck(org.lwjgl.util.vector.Vector2f p)
    • pointNeedsDetailedCheck

      public boolean pointNeedsDetailedCheck(org.lwjgl.util.vector.Vector2f p, float extraRange)
    • compute

      public void compute(List<org.lwjgl.util.vector.Vector2f> points)
    • computeCenterAndRadius

      public void computeCenterAndRadius()
    • computeBox

      public void computeBox()
    • rotate

      public static List<org.lwjgl.util.vector.Vector2f> rotate(List<org.lwjgl.util.vector.Vector2f> points, float angle)
    • getBoundingBox

      public static float[] getBoundingBox(List<org.lwjgl.util.vector.Vector2f> points)
    • computeConvexHull

      public void computeConvexHull(List<org.lwjgl.util.vector.Vector2f> points)
    • getTurnDir

      public static float getTurnDir(org.lwjgl.util.vector.Vector2f p1, org.lwjgl.util.vector.Vector2f p2, org.lwjgl.util.vector.Vector2f p3)
    • renderDebug

      public void renderDebug(float alpha)