feat(runtime): the native window, for a graphics API that makes its own surface
win_native_window / win_native_instance hand a Vulkan swapchain what it is created on: the HWND and module instance on Windows (VkWin32SurfaceCreateInfoKHR), the game's view on macOS. Headless builds define both as null (weak on macOS, so a windowed link keeps cocoa.ll's), so code that asks for them links everywhere and simply finds no window. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
parent
f97d54aa2a
commit
51d82063aa
4 changed files with 48 additions and 0 deletions
|
|
@ -366,3 +366,13 @@ entry:
|
|||
%t = add i64 %m, %us
|
||||
ret i64 %t
|
||||
}
|
||||
|
||||
; headless on macOS: no window, so nothing for a graphics API to make a surface on
|
||||
define weak ptr @win_native_window() {
|
||||
entry:
|
||||
ret ptr null
|
||||
}
|
||||
define weak ptr @win_native_instance() {
|
||||
entry:
|
||||
ret ptr null
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue