internal/graphicscommand: Misspelling

This commit is contained in:
Hajime Hoshi 2021-07-05 23:32:19 +09:00
parent 5e1d6c06f1
commit 59fa689f22

View File

@ -489,7 +489,7 @@ func (c *drawTrianglesCommand) CanMergeWithDrawTrianglesCommand(dst *Image, srcs
} }
if c.evenOdd || evenOdd { if c.evenOdd || evenOdd {
if c.evenOdd && evenOdd { if c.evenOdd && evenOdd {
return !mightOverlapsDstRegions(c.vertices, vertices) return !mightOverlapDstRegions(c.vertices, vertices)
} }
return false return false
} }
@ -526,7 +526,7 @@ func dstRegionFromVertices(vertices []float32) (minX, minY, maxX, maxY float32)
return return
} }
func mightOverlapsDstRegions(vertices1, vertices2 []float32) bool { func mightOverlapDstRegions(vertices1, vertices2 []float32) bool {
minX1, minY1, maxX1, maxY1 := dstRegionFromVertices(vertices1) minX1, minY1, maxX1, maxY1 := dstRegionFromVertices(vertices1)
minX2, minY2, maxX2, maxY2 := dstRegionFromVertices(vertices2) minX2, minY2, maxX2, maxY2 := dstRegionFromVertices(vertices2)
const mergin = 1 const mergin = 1