app,gpu: move errDeviceLost from package app to package gpu

The Vulkan backend can return device lost error from more than just
Present.

Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
Elias Naur
2021-09-20 11:48:17 +02:00
parent b5e3756ee8
commit bdd0893dd0
5 changed files with 9 additions and 8 deletions
+4
View File
@@ -28,3 +28,7 @@ type Direct3D11 = driver.Direct3D11
// Metal denotes the Apple Metal API.
type Metal = driver.Metal
// ErrDeviceLost is returned from GPU operations when the underlying GPU device
// is lost and should be recreated.
var ErrDeviceLost = driver.ErrDeviceLost
+2
View File
@@ -54,6 +54,8 @@ type Device interface {
Release()
}
var ErrDeviceLost = errors.New("GPU device lost")
type LoadDesc struct {
Action LoadAction
ClearColor f32color.RGBA