mirror of
https://github.com/ocornut/imgui.git
synced 2026-01-09 23:54:20 +00:00
Backends, Examples: WebGPU: simplified ifndef (#8381)
This commit is contained in:
parent
635eb1d8e9
commit
86daa8930e
5 changed files with 10 additions and 10 deletions
|
|
@ -1015,7 +1015,7 @@ void ImGui_ImplWGPU_DebugPrintAdapterInfo(const WGPUAdapter& adapter)
|
|||
wgpuAdapterInfoFreeMembers(info);
|
||||
}
|
||||
|
||||
#if defined(IMGUI_IMPL_WEBGPU_BACKEND_WGPU) || defined(IMGUI_IMPL_WEBGPU_BACKEND_DAWN) && !defined(__EMSCRIPTEN__)
|
||||
#ifndef __EMSCRIPTEN__
|
||||
|
||||
#if defined(__APPLE__)
|
||||
// MacOS specific: is necessary to compile with "-x objective-c++" flags
|
||||
|
|
@ -1079,7 +1079,7 @@ WGPUSurface ImGui_ImplWGPU_CreateWGPUSurfaceHelper(ImGui_ImplWGPU_CreateSurfaceI
|
|||
#endif
|
||||
return surface;
|
||||
}
|
||||
#endif
|
||||
#endif // #ifndef __EMSCRIPTEN__
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
|
|
|
|||
|
|
@ -105,7 +105,7 @@ const char* ImGui_ImplWGPU_GetLogLevelName(WGPULogLevel level);
|
|||
#endif
|
||||
|
||||
// (Optional) Helper to create a surface on macOS/Wayland/X11/Window
|
||||
#if defined(IMGUI_IMPL_WEBGPU_BACKEND_WGPU) || defined(IMGUI_IMPL_WEBGPU_BACKEND_DAWN) && !defined(__EMSCRIPTEN__)
|
||||
#ifndef __EMSCRIPTEN__
|
||||
struct ImGui_ImplWGPU_CreateSurfaceInfo
|
||||
{
|
||||
WGPUInstance Instance;
|
||||
|
|
@ -116,6 +116,6 @@ struct ImGui_ImplWGPU_CreateSurfaceInfo
|
|||
void* RawInstance; // 0 | 0 | 0 | HINSTANCE
|
||||
};
|
||||
WGPUSurface ImGui_ImplWGPU_CreateWGPUSurfaceHelper(ImGui_ImplWGPU_CreateSurfaceInfo* info);
|
||||
#endif
|
||||
#endif // #ifndef __EMSCRIPTEN__
|
||||
|
||||
#endif // #ifndef IMGUI_DISABLE
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue