All Known Implementing Classes:
GradientFiller, SolidFiller
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface Filler
An interface that represents a function to get the colors to fill the triangle.

Can be used for filling triangles with one color, gradients or textures.

Standard implementations for monotone and gradient fill can be found in the library. You can use them as examples for creating your own class/function.

Since:
2.0.0
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Gets the color for the point on specified barycentrics and/or pixel coordinates.
  • Method Details

    • color

      Colorf color(Barycentrics b, Point2i p)
      Gets the color for the point on specified barycentrics and/or pixel coordinates.

      The parameters can be not copies, but references to the objects, used by the triangler.

      Parameters:
      b - barycentric coordinates
      p - pixel coordinates
      Returns:
      color for this point; can be null
      Throws:
      NullPointerException - if b or p is null
      Since:
      2.0.0