Make RHI usable for complex 3D scenarios - #181
Open
kunitoki wants to merge 2 commits into
Open
Conversation
kunitoki
force-pushed
the
dev/rhi_perfection
branch
from
September 6, 2026 23:56
1923159 to
1c390cb
Compare
kunitoki
force-pushed
the
dev/rhi_perfection
branch
from
September 7, 2026 00:14
ede8252 to
7804807
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces major improvements and new features to the graphics rendering infrastructure, with a focus on GPU resource management, rendering performance, and new demo content. The changes include backend optimizations, expanded API capabilities, new demos, and documentation updates to reflect the latest features and fixes.
Graphics Backend and API Enhancements
GpuTexturenow caches backend texture views by view descriptor, reducing redundant allocations and improving performance, especially on Metal.GpuRenderPassnow encodes all draws in a pass into a single backend render pass, avoiding expensive per-draw encoder creation and improving frame efficiency.GpuFrameno longer blocks on the GPU at scope end, reducing pipeline stalls and relying on backend-specific resource management. Frame numbers are now correctly reported to the ore context for better resource reclamation.GpuTexture::create()andupload()for direct texture allocation and pixel upload, supporting all backend formats and shapes. AddedGpuSamplerandGpuRenderPass::setSampler()for customizable sampling. [1] [2]GpuRenderPassnow supports multiple color attachments, explicit depth/stencil, MSAA resolve, and expanded draw/viewport/scissor/blend operations. Bind groups are validated and errors are reported. [1] [2]New Features and Demos
PBR IBLdemo (physically based rendering with image-based lighting) and aFluid Simulationdemo (Navier-Stokes solver with GPU post-processing and bloom) to the graphics example app. [1] [2]Performance and Synchronization Improvements
Componenteffect paths now reuse offscreenGpuCanvasacross frames for efficiency.ComponentNative::vsyncflag (withOptions::withVSync()) synchronizes presentation to display refresh, improving pacing and avoiding timer conflicts.framerateRedrawis very high and improved timer precision on macOS.Documentation Updates
Bug Fixes
ShaderTranspilernow defaults toprecision highp float;for GLSL ES fragment output, fixing math corruption on OpenGL ES.KMeterStateby making all relevant fields atomic and updating thread ownership.These changes significantly enhance the graphics subsystem's flexibility, performance, and reliability, while providing new demos and clearer documentation for advanced rendering features.