restorable: Record more drawing image history items

Fixes #813
This commit is contained in:
Hajime Hoshi 2019-02-13 10:45:05 +09:00
parent ef31a6bb21
commit 27dbf1bbb7

View File

@ -355,7 +355,8 @@ func (i *Image) appendDrawImageHistory(image *Image, vertices []float32, indices
if i.stale || i.volatile || i.screen {
return
}
const maxDrawImageHistoryNum = 100
// TODO: Would it be possible to merge draw image history items?
const maxDrawImageHistoryNum = 1024
if len(i.drawImageHistory)+1 > maxDrawImageHistoryNum {
i.makeStale()
return