Commit Graph
430 Commits
Author SHA1 Message Date
Branimir Karadžić 7a09f00333 Fixed MSAA/framebuffer, format caps, stencil, and debug name issues. (#3895) 2026-08-15 06:08:05 +00:00
Branimir Karadžić c53bdbbadc VK: Fixed BGFX_STATE_BLEND_SRC_ALPHA_SAT using source alpha instead of the saturated factor. (#3891) 2026-08-14 17:13:21 -07:00
Branimir Karadžić 56ef37bcf8 Implemented BGFX_SAMPLER_SAMPLE_STENCIL in all backends. (#3884) 2026-08-13 15:38:58 -07:00
Branimir Karadžić 3d3b08778e Support depth-1 volume textures. (#3883) 2026-08-12 18:24:25 -07:00
Alessandro Muntoniandalemuntoni d2633c6ac2 Fix vkCmdBeginRenderPass crash on unused views in headless mode (#3871)
* Fix vkCmdBeginRenderPass crash on unused views in headless mode

* add m_needPresent and m_currentFramebuffer initializers

---------

Co-authored-by: alemuntoni <alemuntoni@users.noreply.github.com>
2026-08-05 21:44:58 +00:00
Branimir Karadžić aa736d5691 VK: Fixed device memory leaks, pipeline layout lifetime, compressed blit extent, and view rect clipping. (#3865) 2026-08-02 02:42:07 +00:00
Branimir Karadžić 980c02ecd7 VK: Added BGFX_CONFIG_RENDERER_VULKAN_ROBUST_BUFFER_ACCESS. Fixes #3855. (#3859) 2026-07-30 04:45:54 +00:00
Branimir Karadžić 8377801ee0 Add BC4S, BC5S, BC6HU, RGB10A2U and D32FS8 texture formats. (#3857) 2026-07-29 21:25:53 +00:00
Branimir Karadžić ce18bdb6c6 Allow negative x/y in bgfx::setViewRect. (#3848) 2026-07-25 15:04:06 +00:00
Branimir Karadžić 8e50cd586c Fixed auto-gen mips on resolved MSAA render targets. (#3845) 2026-07-24 22:44:05 +00:00
Alessandro Muntoni c1da9d62b0 check validity of XGetXCBConnection (#3844) 2026-07-23 14:16:34 +00:00
Branimir Karadžić 435627021d Added clear texture API. (#3836) 2026-07-16 05:41:58 +00:00
Branimir Karadžić d219e7c2d6 Cleanup. (#3835) 2026-07-15 06:52:38 +00:00
Jason Millard af0256b57a VK: Fix init crash w/external device on GPU w/o video decode queues (#3834) 2026-07-14 22:40:08 -07:00
Branimir Karadžić a4555482f9 Increased number of texcoord attributes, increased instance data, added int32/uint32 vertex attributes. (#3832) 2026-07-14 05:15:13 +00:00
Branimir Karadžić 6eb09a4a9b Added setImage with array layer range for compute images. (#3829) 2026-07-13 04:19:07 +00:00
Branimir Karadžić 39a2a05a3c Fixed warnings. (#3830) 2026-07-13 03:53:02 +00:00
Branimir Karadžić 7c6a7e5f00 D3D11/VK/Metal/GL: Fixed dangling framebuffer handle on destroy. (#3827) 2026-07-12 20:30:42 -07:00
Branimir Karadžić 1fae5a8b06 D3D11/D3D12/VK/WebGPU: Fixed blend-state, and blend factor for MRT. (#3825) 2026-07-13 01:43:24 +00:00
Branimir Karadžić 2877442edc Fixed BC texture block-size rounding in readback/create/update. (#3822) 2026-07-12 00:07:51 -07:00
Branimir Karadžić 3920502547 VK: Mark BGRA8/RGBA8 as valid backbuffer texture formats when in headless mode. (#3824) 2026-07-12 00:00:47 -07:00
Branimir Karadžić 7b38346442 Added stencil write mask. (#3821) 2026-07-11 23:46:38 -07:00
Branimir Karadžić f30da05ce3 Metal: Cache last pipeline. Dedup pipeline binds. (#3799) 2026-06-28 22:47:43 +00:00
Branimir Karadžić fd1a8b48fc VK: Cache last pipeline. (#3798) 2026-06-28 11:23:54 -07:00
Branimir Karadžić 40aa1c2220 VK: Grow descriptor pools on demand. (#3793) 2026-06-28 06:14:30 +00:00
Kyle Emmerich c9bb37b668 Vulkan: Fixed capture buffer size. (#3783)
captureSize used m_width for the row count, but the swap-chain readback
copies m_height rows (capture() reports _size = height * pitch, and
ReadbackVK::pitch() is width * bpp/8). A backbuffer taller than wide
under-allocates the readback buffer and overruns it. Use m_height, which
matches the GL backend's width*height*4.
2026-06-25 15:43:37 +00:00
Branimir Karadžić fd5fa66370 VK: Fixed present crash on resize. (#3773) 2026-06-20 06:44:18 -07:00
Branimir Karadžić 73629ada72 Dedup bindings per encoder. (#3772) 2026-06-20 05:22:12 +00:00
Branimir Karadžić 4f101d98be Don't present BGFX_FRAME_FLUSH frames. Fixed D3D12/VK flush sync. (#3771) 2026-06-19 19:39:42 +00:00
Branimir Karadžić 09eaac37ae VK: Added descriptor set cache. (#3770) 2026-06-19 18:21:52 +00:00
Francis De Brabandere 1d8f6d8ee9 Vulkan: do not block acquiring window swap chain images (#3752)
Acquiring waited forever for an image on every swap chain from the one
submit thread, so a single swap chain that is no longer served (e.g. a
fully occluded window on a Wayland compositor without fifo-v1, which
stops releasing buffers) stalled rendering of all windows. Window swap
chains now acquire without blocking and are skipped for the frame when
no image is available; only the main back buffer may block, as that is
the frame pacing. Image availability acts as natural back pressure, no
compositor specific behavior is needed.
2026-06-17 14:05:02 +00:00
Francis De Brabandere edbec2f2cc Vulkan: recreate window swap chains flagged for recreation (#3751)
When acquiring a window frame buffer swap chain returns
VK_SUBOPTIMAL_KHR or VK_ERROR_OUT_OF_DATE_KHR it is flagged with
m_needToRecreateSwapchain and acquire then refuses forever: only the
main back buffer is recreated (by updateResolution), so the window
permanently stops updating (easily triggered by moving the window to a
display with a different scale). Recreate flagged window swap chains
when acquiring them.
2026-06-17 03:56:24 +00:00
Branimir Karadžić d5ea625272 Added video decoder support. (#3756) 2026-06-14 06:49:15 +00:00
Branimir Karadžić 1dac10c2ad Fixed transcoded texture update using wrong decode/copy pitch with explicit source pitch. (#3747) 2026-06-08 23:02:33 -07:00
Branimir Karadžić f19f599cde D3D11/D3D12/VK: Fixed partial update of transcoded texture overrunning buffer. Closes #2713. (#3744) 2026-06-08 21:52:24 -07:00
Branimir Karadžić e92490c3f7 Added _layer parameter to bgfx::readTexture for texture array/cubemap readback. Closes #3235. (#3737) 2026-06-07 09:22:37 -07:00
Branimir Karadžić 944ccff1e4 D3D11/D3D12/VK/WebGPU: Fixed independent blend _rgba. (#3736) 2026-06-07 08:37:37 -07:00
Branimir Karadžić 81b63b81c9 Unified ChunkedScratchBuffer implementation. (#3730) 2026-06-07 03:29:09 +00:00
Branimir Karadžić 11151de78d Added setTexture view API. (#3728) 2026-06-06 17:34:02 +00:00
Branimir Karadžić 7b8927049a Fix updateTexture2D pitch handling for compressed textures. Fixed #3705. (#3722) 2026-06-02 04:22:46 +00:00
Branimir Karadžić 7d03e160fa Fix MSAA + mipmaps combination on D3D11/D3D12/Vulkan/Metal. (#3717) 2026-05-21 22:53:17 +00:00
Branimir Karadžić de332e5937 VK: Fixed VK_EXT_swapchain_maintenance1 missing instance exp deps, and timer query inside render pass. (#3711)
* Fixed dynamic frame vsync on RADV.

* Fix timer query inside render pass.
2026-05-17 23:51:31 +00:00
Branimir Karadžić d4c91be81d Cleanup. (#3710) 2026-05-17 16:43:20 +00:00
Vincent Bousquet a8250ceaf9 Lighter per frame VSync on/off for D3D11, D3D12 & Vulkan (#3706) 2026-05-17 15:44:33 +00:00
Branimir Karadžić 65f9425d8c Updated to new SIMD. (#3699) 2026-05-03 18:51:10 +00:00
Branimir Karadžić 58faaadf1c VK: Split FrameBufferVK::acquire into swap-chain acquire + markDirty(). (#3694) 2026-04-27 18:32:53 +00:00
attilaz b2a7d94d57 Update renderer_vk.cpp (#3693)
Fix PROFILE_SCOPE typo
2026-04-27 14:22:28 +00:00
Branimir Karadžić 331783cf9a Renamed bx::uint32_min/max/clamp/cntlz/cnttz/mod to typed equivalents. (#3692) 2026-04-27 04:19:08 +00:00
Branimir Karadžić 50bf41b224 Fixed stremMask check. (#3682) 2026-04-21 11:21:40 -07:00
unravel-dev 4212c8ed27 Fix BGFX_RESET_VSYNC not affecting secondary swap chains on D3D11, Vulkan, OpenGL (#3675)
Toggling BGFX_RESET_VSYNC via bgfx::reset() only updated the main/init swap
chain. Secondary swap chains created through createFrameBuffer(nwh, ...) kept
their initial vsync state, leaving framerate capped at refresh rate. D3D12
already handled this correctly.

D3D11: forward present flags to FrameBufferD3D11::present so it can pass
DXGI_PRESENT_ALLOW_TEARING alongside syncInterval=0. Compute presentFlags once
in flip() and reuse for both secondary framebuffers and the main swap chain.

Vulkan: in updateResolution, iterate m_windows and call FrameBufferVK::update
on each valid secondary framebuffer so SwapChainVK::update sees the new
BGFX_RESET_VSYNC and recreates the swapchain with the correct present mode.

OpenGL (WGL/EGL): wglSwapIntervalEXT is per-context, eglSwapInterval is
per-surface. Cache the desired interval in GlContext::m_swapInterval and
re-apply it in makeCurrent() whenever a different context/surface becomes
current, so secondary SwapChainGL instances pick up the current value. Also
honor the initial BGFX_RESET_VSYNC flag in create() instead of hard-coding 0.
2026-04-19 22:35:57 +00:00