Only selectively compile Metal & fix some compilation issues

This commit is contained in:
Evan Husted 2025-01-18 10:52:32 -06:00
parent 2f93a0f706
commit beda3206e0
5 changed files with 7 additions and 8 deletions

View file

@ -897,7 +897,7 @@ namespace Ryujinx.Ava
{
#pragma warning disable CA1416 // This call site is reachable on all platforms
// SelectGraphicsBackend does a check for Mac, on top of checking if it's an ARM Mac. This isn't a problem.
GraphicsBackend.Metal => new MetalRenderer((RendererHost.EmbeddedWindow as EmbeddedWindowMetal)!.CreateSurface),
GraphicsBackend.Metal => new MetalRenderer(() => new SharpMetal.QuartzCore.CAMetalLayer(((EmbeddedWindowMetal)RendererHost.EmbeddedWindow).MetalLayer)),
#pragma warning restore CA1416
GraphicsBackend.Vulkan => VulkanRenderer.Create(
ConfigurationState.Instance.Graphics.PreferredGpu,