Class Mesh2D

java.lang.Object
io.github.espressoengine.object.Object
io.github.espressoengine.object.Mesh2D
Direct Known Subclasses:
Circle, Rect

public class Mesh2D extends Object
A "base" mesh class utilizing java.awt.geom.
Version:
$Id: $Id
Author:
pastthepixels
  • Field Details

    • geometry

      public Shape geometry
    • strokeColor

      public Color strokeColor
    • strokeWidth

      public int strokeWidth
    • fillColor

      public Color fillColor
  • Constructor Details

    • Mesh2D

      public Mesh2D()
  • Method Details

    • updateGeometry

      public void updateGeometry()
      Recreates the geometry of the object taking in factors like its position. This function is designed to be overridden and is called automaticaly when the mesh is drawn.
    • updateBoundingBox

      public void updateBoundingBox(AffineTransform transform)
      Recreates a bounding box from an java.awt.geom.AffineTransform. This function called every time a scene is drawn and is yet another empty function designed to be overridden.
      Overrides:
      updateBoundingBox in class Object
      Parameters:
      transform - a AffineTransform object