Class SmoothingRenderer
java.lang.Object
com.realtime.crossfire.jxclient.gui.map.SmoothingRenderer
Renderer for painting smoothed faces into map views.
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
SmoothingRenderer
(@NotNull SmoothFaces smoothFaces, @NotNull FacesProvider facesProvider) Creates a new instance. -
Method Summary
Modifier and TypeMethodDescriptionvoid
paintSmooth
(@NotNull Graphics graphics, int x, int y, int px, int py, int layer, @NotNull CfMap map, int tileSize) Draw the smoothing information at given position of map, for a given limit smoothlevel, at a given layer.
-
Constructor Details
-
SmoothingRenderer
protected SmoothingRenderer(@NotNull @NotNull SmoothFaces smoothFaces, @NotNull @NotNull FacesProvider facesProvider) Creates a new instance.- Parameters:
smoothFaces
- the smooth faces to usefacesProvider
- the face provider for looking up faces
-
-
Method Details
-
paintSmooth
public void paintSmooth(@NotNull @NotNull Graphics graphics, int x, int y, int px, int py, int layer, @NotNull @NotNull CfMap map, int tileSize) Draw the smoothing information at given position of map, for a given limit smoothlevel, at a given layer. This operation may be recursive, if all layer above current are to be drawn too.- Parameters:
graphics
- where to draw (graphics)x
- the x-coordinate of the map square to draw, in map coordinatesy
- the y-coordinate of the map square to draw, in map coordinatespx
- the x offset for paintingpy
- the y offset paintinglayer
- the layer to paintmap
- the rendered maptileSize
- the size of one tile in pixel
-