mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-24 10:48:53 +01:00
internal/graphicsdriver/metal: Refactoring
This commit is contained in:
parent
3ec02f767b
commit
19f034e818
@ -826,7 +826,10 @@ func (g *Graphics) HasHighPrecisionFloat() bool {
|
||||
}
|
||||
|
||||
func (g *Graphics) MaxImageSize() int {
|
||||
if g.maxImageSize == 0 {
|
||||
if g.maxImageSize != 0 {
|
||||
return g.maxImageSize
|
||||
}
|
||||
|
||||
g.maxImageSize = 4096
|
||||
// https://developer.apple.com/metal/Metal-Feature-Set-Tables.pdf
|
||||
switch {
|
||||
@ -853,7 +856,6 @@ func (g *Graphics) MaxImageSize() int {
|
||||
default:
|
||||
panic("metal: there is no supported feature set")
|
||||
}
|
||||
}
|
||||
return g.maxImageSize
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user