Interface Filler
- 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.
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 TypeMethodDescriptioncolor
(Barycentrics b, Point2i p) Gets the color for the point on specified barycentrics and/or pixel coordinates.
-
Method Details
-
color
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 coordinatesp
- pixel coordinates- Returns:
- color for this point; can be
null
- Throws:
NullPointerException
- ifb
orp
isnull
- Since:
- 2.0.0
-