Commit Graph

1129 Commits

Author SHA1 Message Date
ocornut
dee5bf3ec3 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_dx10.cpp
#	backends/imgui_impl_dx9.cpp
#	backends/imgui_impl_glfw.cpp
#	backends/imgui_impl_metal.mm
#	backends/imgui_impl_opengl2.cpp
#	backends/imgui_impl_opengl3.cpp
#	backends/imgui_impl_vulkan.cpp
#	imgui.cpp
2026-04-23 16:07:01 +02:00
ocornut
ac06ad7b48 ImDrawList: made AddCallback() user data default to NULL + minor amends/comments. 2026-04-23 15:58:44 +02:00
ocornut
b065713cec Backends: OpenGL2/3, SDLRenderer2/3, DirectX9, Metal: moved Init/Shutdown code lower in the file.
Allows to point to local functions without forward declaring them.
2026-04-23 15:53:28 +02:00
ocornut
ac261203a5 (Breaking) Backends: Vulkan: redesigned to use separate ImageView + Sampler instead of Combined Image Sampler. (fixes, amends) (#914) 2026-04-22 14:43:44 +02:00
yaz0r
0453ae96e8 (Breaking) Backends: Vulkan: redesigned to use separate ImageView + Sampler instead of Combined Image Sampler. (WIP) (#914) 2026-04-22 14:43:44 +02:00
ocornut
a5fd597be3 Backends: Vulkan: minor changes. 2026-04-22 14:23:42 +02:00
ocornut
2d131ef5b7 Backends: Vulkan: renaming and moving code around to reduce diff in upcoming change. Should be no-op. 2026-04-21 22:22:06 +02:00
ocornut
a1e05521e9 Backends: GLFW: added a Win32-specific implementation of ImGui_ImplGlfw_GetContentScaleXXXX functions for legacy GLFW 3.2. (#9003)
Since we ship GLFW 3.2 binaries for Windows this makes our examples a little better behaving by default.
Ideally we'd use ImGui_ImplWin32_GetDpiScaleForHwnd() and ImGui_ImplWin32_GetDpiScaleForMonitor() but they are too much code to copy.
2026-04-21 17:24:41 +02:00
ocornut
329c5a6b3b Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_metal.mm
#	backends/imgui_impl_sdl2.cpp
2026-04-16 15:29:57 +02:00
ocornut
0e318a5182 Backends: SDL2: Made ImGui_ImplSDL2_GetContentScaleXXX helpers return a minimum of 1.0f, as some Linux setup seems to report <1.0f value and this breaks scaling border size. (#9369) 2026-04-16 11:32:07 +02:00
Andy Grundman
4b80d409e7 Backends: Metal: use a dedicated bufferCacheLock to avoid crashing when bufferCache is replaced by a new object while being used for synchronize(). (#9367)
This also removes the dispatch onto main when adding the finished buffers back into the cache. This operation should be fine to run on any thread as long as it's inside the sync block.
2026-04-14 17:14:08 +02:00
ocornut
bbcc83e999 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_metal.mm
#	imgui.cpp
2026-04-08 21:40:40 +02:00
hunam
49df3116bc Backends: Metal: avoid redundant vertex buffer bind in SetupRenderState. (#9343) 2026-04-03 19:14:23 +02:00
ocornut
fe5c5298a6 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_glfw.cpp
#	imgui.h
2026-03-31 21:48:34 +02:00
ocornut
64f88934a7 Viewports: only apply AdjustWindowRectExForDpi() when Per-Monitor DPI Aware V2. Amend 54a865e. (#8897)
Arghhh.
2026-03-31 20:23:28 +02:00
ocornut
54a865e472 Viewports: fixed setting/getting correct size when viewports have OS decorations (e.g. io.ConfigViewportsNoDecoration = false) and process is running in Per-Monitor V2 DPI mode. (#8897) 2026-03-31 17:56:56 +02:00
JoshBot-Debug
b003a85143 Backends: Vulkan: use a single call to vkCmdPushConstants(). (#9183, #9327) 2026-03-31 16:07:46 +02:00
ocornut
8d8892ce0e Backends: SDL3: use SDL_HAS_EVENT_DISPLAY_USABLE_BOUNDS_CHANGED (SDL 3.4.0+) when available to avoid refreshing monitor work area every frame on Windows. (#8415) 2026-03-25 17:25:32 +01:00
ocornut
59183cf782 Backends, Examples: WebGPU: added support for WGVK. Remaining amends. (#9316, #9246, #9257) 2026-03-25 15:31:39 +01:00
r-lyeh
59780020f6 Backends, Examples: WebGPU: added support for WGVK. (#9316, #9246, #9257)
Squashed: minified SPIRV binaries by stripping strings + emitting in binary_to_compressed_c.
2026-03-25 15:31:35 +01:00
ocornut
51f590a2a8 Backends: GLFW: mouse cursor is properly restored if changed by user app/code while using glfwSetInputMode(..., GLFW_CURSOR_DISABLED) or ImGuiConfigFlags_NoMouseCursorChange. (#9322)
Amend 9a4fd69f6
2026-03-25 14:17:29 +01:00
ocornut
79411a0405 Backends, Examples: WebGPU: fixed warnings + scale initial surface height for native. 2026-03-23 16:21:50 +01:00
ocornut
e05bd9deb9 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_dx9.cpp
#	backends/imgui_impl_metal.mm
#	backends/imgui_impl_opengl2.cpp
#	backends/imgui_impl_opengl3.cpp
#	backends/imgui_impl_sdlgpu3.cpp
#	imgui.cpp
#	imgui_internal.h
#	imgui_widgets.cpp
2026-03-20 16:37:35 +01:00
ocornut
386ce49c58 Backends: DirectX9: fixed build typo in 0500e54. 2026-03-19 18:17:35 +01:00
ocornut
358d3912c9 Backends: SDLRenderer2/3: fixed build, typo in 0500e54. 2026-03-19 12:34:11 +01:00
ocornut
0500e546b5 Backends: DX9, Metal, SDLRenderer2/3: fixed more assumptions that ImTextureID_Invald == 0 + Amend Changelogs. (#9310, #9293) 2026-03-19 11:47:01 +01:00
Starman
7fc3092870 Backends: SDLGPU3: Prevent DestroyTexture from deleting invalid textures if ImTextureID_Invalid != 0. (#9310, #9293)
Amend 0db5919
2026-03-19 11:31:48 +01:00
ocornut
60d7fb207e Merge branch 'master' into docking
# Conflicts:
#	imgui.cpp
2026-03-13 17:09:34 +01:00
ocornut
6dbda97fee Backends: OpenGL2, OpenGL3, SDLRenderer3: replaced erroneous IM_ASSERT(tex->TexID == 0) calls. (#9295, #9293)
Amend/fix 0db5919 which revealed this.
2026-03-12 19:29:39 +01:00
ocornut
80f8298769 Backends: Vulkan: fixed warning. 2026-03-11 22:07:56 +01:00
Michael Böhme
7546f1eb16 Backends: Vulkan: ImGui_ImplVulkan_AddTexture() skips updating descriptor_set if failing to allocate. (#8677)
Reduce error surface to the check_vk_result() call.
2026-03-11 21:22:50 +01:00
ocornut
8f63c3691d Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_vulkan.cpp
#	imgui.cpp
#	imgui_demo.cpp
2026-03-11 21:07:46 +01:00
MaciejDziuban
decb5cdf10 Backends: Vulkan: added ImGui_ImplVulkan_PipelineInfo::ExtraDynamicStates. (#9211)
This new setting allows an application to force the pipeline created by vulkan backend to specify more dynamic states than just default viewport and scissor.
It is useful e.g. when using draw list callbacks, e.g. adding VK_DYNAMIC_STATE_COLOR_BLEND_EQUATION_EXT to be able to use vkCmdSetColorBlendEquationEXT inside callbacks.
2026-03-11 17:00:47 +01:00
ocornut
83fa0ae263 Backends, Examples: removed Emscripten < 4.0.10 support. Removed IMGUI_IMPL_WEBGPU_BACKEND_WGPU. Amends. (#9281, #8381) 2026-03-09 16:18:59 +01:00
Yan Pujante
e92820db2a Backends, Examples: removed Emscripten < 4.0.10 support. Removed IMGUI_IMPL_WEBGPU_BACKEND_WGPU. (#9281, #8381)
- This commit removes the option of using -sUSE_WEBGPU=1 from CMake and make
- Compiling with a version of Emscripten >= 4.0.10 will work the same way as it was before
- Compiling with a version of Emscripten < 4.0.10 will print an error message and abort the build (in the case of CMake)
- Since there can only be 1 implementation for the backend in the case of Emscripten, this commit cleans the code accordingly
2026-03-09 15:45:34 +01:00
ocornut
aeaaee8090 Backends: SDL2, SDL3: fixed an issue in 06c2c9f45 causing ImGuiBackendFlags_HasMouseHoveredViewport to never be set. (#9284) 2026-03-09 14:42:00 +01:00
ocornut
934c6a5f5e Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_sdlgpu3.cpp
#	imgui.cpp
2026-02-25 19:48:53 +01:00
Seppo Räisänen
dd5c604768 Backends: SDLGPU3: remove unnecessary call to SDL_WaitForGPUIdle when releasing vertex/index buffers. (#9262) 2026-02-25 18:08:27 +01:00
ocornut
2b415e642b Backends: WebGPU: fixed Emscripten version check. (#8381)
Amend ff673d3.
2026-02-24 17:49:08 +01:00
ocornut
2a1b69f057 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_sdl2.cpp
#	backends/imgui_impl_sdl3.cpp
#	imgui.h
#	imgui_demo.cpp
#	imgui_internal.h
2026-02-17 18:09:30 +01:00
ocornut
ff673d31df Backends: WebGPU: minor build fix for Emscripten 5.0.0 (note: our examples currently don't build with 5.0.1).
Getting 'warning: unused function 'CreateWGPUSurface' [-Wunused-function]' in some build paths.
cc #9246
2026-02-16 18:04:20 +01:00
ocornut
acdaaef625 Backends: further zealous warning fixes. (#9247) 2026-02-16 16:45:08 +01:00
Laurenz Altenmüller
fbe973a8d0 Cast this to (void*) in zero-clearing memset calls to fix -Wnontrivial-memcall (#9247, #8295, #8129, #8135)
Clang 20+ warns on memset(this, ...) for non-trivially copyable types via -Wnontrivial-memcall.
Should separately investigate -Wnonontrivial-memaccess vs -Wnonontrivial-memcall.
2026-02-16 16:29:00 +01:00
ocornut
9f2b3bcf7a Backends: SDL2, SDL3: systems other than X11 are back to starting mouse capture on mouse down. Only X11 requires waiting for a drag by defaultadded ImGui_ImplSDL2_SetMouseCaptureMode(), ImGui_ImplSDL3_SetMouseCaptureMode(). (#9235, #3650, #6410, #3956, #3835)
Amend aa83d5d455
2026-02-13 16:01:08 +01:00
ocornut
943fcc4f10 Merge branch 'master' into docking
# Conflicts:
#	backends/imgui_impl_glfw.cpp
#	imgui.cpp
2026-02-10 20:52:55 +01:00
ocornut
9f30044333 Backends: GLFW: try to set IMGUI_IMPL_GLFW_DISABLE_X11 / IMGUI_IMPL_GLFW_DISABLE_WAYLAND automatically if headers are not available. (#9225)
Amend/fix 10d0162378 for system without X11/Wayland headers. (#8921, #8920, #8969)
2026-02-10 20:50:46 +01:00
tanksdude
5fe48b6a0e Docs: fixed some typos (#9217) 2026-02-10 16:40:52 +01:00
ocornut
d6d5580099 Merge branch 'master' into docking w/ custom fix in Scrollbar()
# Conflicts:
#	backends/imgui_impl_win32.cpp
#	imgui.cpp
2026-01-29 17:52:30 +01:00
Ahmed Samy
960aff24fc Backends: Win32: use XInput Packet to avoid resubmitting gamepad data. (#9202, #8556) 2026-01-28 15:30:49 +01:00
ocornut
63e9fbc265 Backends: GLFW: fix previous commit, would break multi-monitor. (#9195, #7902, #5683)
Amend be2cfc2
2026-01-28 14:51:21 +01:00