themes and styles
This commit is contained in:
@@ -44,16 +44,17 @@ func (w *World) drawPointInTile(drawer PrimitiveDrawer, plan RenderPlan, td Tile
|
||||
|
||||
func (w *World) drawCircleInTile(drawer PrimitiveDrawer, plan RenderPlan, td TileDrawPlan, c Circle, allowWrap bool, lastStyle Style) {
|
||||
var shifts []wrapShift
|
||||
effRadius := circleRadiusEffFp(c.Radius, w.circleRadiusScaleFp)
|
||||
if allowWrap {
|
||||
shifts = circleWrapShifts(c, w.W, w.H)
|
||||
shifts = circleWrapShifts(c.X, c.Y, effRadius, w.W, w.H)
|
||||
} else {
|
||||
shifts = []wrapShift{{dx: 0, dy: 0}}
|
||||
}
|
||||
|
||||
rPx := worldSpanFixedToCanvasPx(c.Radius, plan.ZoomFp)
|
||||
rPx := worldSpanFixedToCanvasPx(effRadius, plan.ZoomFp)
|
||||
|
||||
for _, s := range shifts {
|
||||
if allowWrap && !circleCopyIntersectsTile(c, s.dx, s.dy, td.Tile, w.W, w.H) {
|
||||
if allowWrap && !circleCopyIntersectsTile(c.X, c.Y, effRadius, s.dx, s.dy, td.Tile, w.W, w.H) {
|
||||
continue
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user