Class SmoothingRenderer
- java.lang.Object
-
- net.sf.gridarta.var.crossfire.gui.map.renderer.SmoothingRenderer
-
public class SmoothingRenderer extends java.lang.ObjectRenderer for smoothed faces as used by Crossfire.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedSmoothingRenderer(@NotNull MapModel<GameObject,MapArchObject,Archetype> mapModel, @NotNull SmoothFaces smoothFaces, @NotNull FaceObjectProviders faceObjectProviders)Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidpaintSmooth(@NotNull java.awt.Graphics graphics, @NotNull java.awt.Point pos, int level, int firstLayer, boolean allLayers, int borderOffsetX, int borderOffsetY)Draw the smoothing information at given position of map, for a given limit smoothlevel, at a given layer.
-
-
-
Constructor Detail
-
SmoothingRenderer
protected SmoothingRenderer(@NotNull @NotNull MapModel<GameObject,MapArchObject,Archetype> mapModel, @NotNull @NotNull SmoothFaces smoothFaces, @NotNull @NotNull FaceObjectProviders faceObjectProviders)Creates a new instance.- Parameters:
mapModel- the map model to rendersmoothFaces- the smooth faces to usefaceObjectProviders- the face object providers for looking up faces
-
-
Method Detail
-
paintSmooth
public void paintSmooth(@NotNull @NotNull java.awt.Graphics graphics, @NotNull @NotNull java.awt.Point pos, int level, int firstLayer, boolean allLayers, int borderOffsetX, int borderOffsetY)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)pos- the coordinate of the map square to draw, in map coordinateslevel- the limit smoothlevel (smooth levels above this are drawn)firstLayer- the layer (map z coordinate) to draw; note that invisible objects are supposed to not use a layer, to stay coherent with client behaviorallLayers- whether or not to draw also layers above current oneborderOffsetX- the border x offsetborderOffsetY- the border y offset
-
-