mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-11-10 04:57:26 +01:00
internal/graphicsdriver/metal: bug fix: a path for CoreGraphics.framework didn't work
Closes #2595
This commit is contained in:
parent
f9f1736a4b
commit
36e2d0ec40
@ -52,7 +52,7 @@ type MetalLayer struct {
|
||||
//
|
||||
// Reference: https://developer.apple.com/documentation/quartzcore/cametallayer.
|
||||
func MakeMetalLayer() (MetalLayer, error) {
|
||||
coreGraphics, err := purego.Dlopen("/System/Library/Frameworks/CoreGraphics.framework/Versions/Current/CoreGraphics", purego.RTLD_LAZY|purego.RTLD_GLOBAL)
|
||||
coreGraphics, err := purego.Dlopen("CoreGraphics.framework/CoreGraphics", purego.RTLD_LAZY|purego.RTLD_GLOBAL)
|
||||
if err != nil {
|
||||
return MetalLayer{}, err
|
||||
}
|
||||
|
@ -35,7 +35,7 @@ func init() {
|
||||
//go:cgo_import_dynamic _ _ "Metal.framework/Metal"
|
||||
|
||||
// It is also necessary for CoreGraphics to be linked
|
||||
_, _ = purego.Dlopen("/System/Library/Frameworks/CoreGraphics.framework/Versions/Current/CoreGraphics", purego.RTLD_LAZY|purego.RTLD_GLOBAL)
|
||||
_, _ = purego.Dlopen("CoreGraphics.framework/CoreGraphics", purego.RTLD_LAZY|purego.RTLD_GLOBAL)
|
||||
}
|
||||
|
||||
func Example_listDevices() {
|
||||
|
Loading…
Reference in New Issue
Block a user