ebiten: Update the comments of (*Image).SubImage

Closes #1643
This commit is contained in:
Hajime Hoshi 2021-05-13 21:23:17 +09:00
parent 97fa948e5e
commit d05bd7a58c

View File

@ -601,7 +601,9 @@ func (i *Image) DrawRectShader(width, height int, shader *Shader, options *DrawR
//
// If the image is disposed, SubImage returns nil.
//
// In the current Ebiten implementation, SubImage is available only as a rendering source.
// A sub-image returned by SubImage can be used as a rendering source and a rendering destination.
// If a sub-image is used as a rendering source, the image is used as if it is a small image.
// If a sub-image is used as a rendering destination, the region being rendered is clipped.
func (i *Image) SubImage(r image.Rectangle) image.Image {
i.copyCheck()
if i.isDisposed() {