Backends: Metal: fixed secondary viewport rendering. (#6015, #4821, #2778)

This commit is contained in:
ocornut 2023-01-03 12:34:47 +01:00
parent 6939676372
commit 42e166089a
2 changed files with 2 additions and 1 deletions

View File

@ -415,7 +415,7 @@ static void ImGui_ImplMetal_CreateWindow(ImGuiViewport* viewport)
void* handle = viewport->PlatformHandleRaw ? viewport->PlatformHandleRaw : viewport->PlatformHandle;
IM_ASSERT(handle != nullptr);
id<MTLDevice> device = [bd->SharedMetalContext.depthStencilState device];
id<MTLDevice> device = bd->SharedMetalContext.device;
CAMetalLayer* layer = [CAMetalLayer layer];
layer.device = device;
layer.framebufferOnly = YES;

View File

@ -150,6 +150,7 @@ Docking+Viewports Branch:
remapping list are docked on the left or top side of a split. (#6035)
- Backends: OSX: fixed typo in ImGui_ImplOSX_GetWindowSize that would cause issues when resiing
from OS decorations, if they are enabled on secondary viewports. (#6009) [@sivu]
- Backends: Metal: fixed secondary viewport rendering. (#6015) [@dmirty-kuzmenko]
-----------------------------------------------------------------------