internal/atlas: Bug fix: Fix test

This commit is contained in:
Hajime Hoshi 2021-08-14 22:23:06 +09:00
parent 8a6302f9dc
commit 1e062a4245
2 changed files with 2 additions and 1 deletions

View File

@ -16,6 +16,7 @@ package atlas
const (
BaseCountToPutOnAtlas = baseCountToPutOnAtlas
PaddingSize = paddingSize
)
func PutImagesOnAtlasForTesting() error {

View File

@ -522,7 +522,7 @@ func TestExtendWithBigImage(t *testing.T) {
// Issue #1217
func TestMaxImageSize(t *testing.T) {
// This tests that a too-big image is allocated correctly.
s := maxImageSizeForTesting
s := maxImageSizeForTesting - 2*PaddingSize
img := NewImage(s, s)
defer img.MarkDisposed()
img.ReplacePixels(make([]byte, 4*s*s))