mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-10 04:57:26 +01:00
graphicsdriver/metal: Bug fix: synchronizing must be skipped on iOS
This commit is contained in:
parent
9f76b96c1f
commit
5a176d6f4f
@ -832,6 +832,13 @@ func (i *Image) IsInvalidated() bool {
|
||||
}
|
||||
|
||||
func (i *Image) syncTexture() {
|
||||
// The texture's storage must be 'managed' to synchronize.
|
||||
//
|
||||
// https://developer.apple.com/documentation/metal/mtlblitcommandencoder/1400757-synchronize
|
||||
if storageMode == mtl.StorageModeShared {
|
||||
return
|
||||
}
|
||||
|
||||
i.graphics.t.Call(func() error {
|
||||
if i.graphics.cb != (mtl.CommandBuffer{}) {
|
||||
panic("metal: command buffer must be empty at syncTexture: flush is not called yet?")
|
||||
|
Loading…
Reference in New Issue
Block a user