mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-25 11:18:54 +01:00
ebiten: English
This commit is contained in:
parent
654c4c286c
commit
922784f574
4
image.go
4
image.go
@ -513,7 +513,7 @@ func (i *Image) DrawTrianglesShader(vertices []Vertex, indices []uint16, shader
|
||||
b := img.Bounds()
|
||||
x, y := img.adjustPosition(b.Min.X, b.Min.Y)
|
||||
// (sx, sy) is the left-upper position of the first image.
|
||||
// Calculate the direction between the current image's left-upper position and the first one's.
|
||||
// Calculate the distance between the current image's left-upper position and the first one's.
|
||||
offsets[i][0] = float32(x - sx)
|
||||
offsets[i][1] = float32(y - sy)
|
||||
}
|
||||
@ -612,7 +612,7 @@ func (i *Image) DrawRectShader(width, height int, shader *Shader, options *DrawR
|
||||
b := img.Bounds()
|
||||
x, y := img.adjustPosition(b.Min.X, b.Min.Y)
|
||||
// (sx, sy) is the left-upper position of the first image.
|
||||
// Calculate the direction between the current image's left-upper position and the first one's.
|
||||
// Calculate the distance between the current image's left-upper position and the first one's.
|
||||
offsets[i][0] = float32(x - sx)
|
||||
offsets[i][1] = float32(y - sy)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user