Repository navigation
perf(streaming): reclaim 1080i depth memory and configure GPU buffers - #367
Merged
Merged
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #367 +/- ##
==========================================
+ Coverage 74.49% 74.63% +0.14%
==========================================
Files 72 72
Lines 8237 8288 +51
Branches 3532 3554 +22
==========================================
+ Hits 6136 6186 +50
+ Misses 1101 1099 -2
- Partials 1000 1003 +3
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report in Codecov by Harness.
|
|
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.



Description
pbkit allocates a 10.55 MiB depth and stencil surface during 1080i GPU setup. Streaming uses the GPU color surface as a background, so it can release the depth surface once setup is complete.
After clearing the background and allocating the requested YUY2 buffers, detach depth and stencil, wait for GPU completion, and free the depth allocation before the first video submission. Keep the allocation order because allocating the spare after freeing depth slowed xemu playback. If detaching depth times out, the presenter returns a fallback reason and leaves cleanup to pbkit.
Settings → Display → GPU Video Buffers applies to new GPU streams at any resolution. Auto tries three buffers for 720p output when the packed frame fits and uses two elsewhere. 2 uses the required pair, and 3 tries a spare. Playback uses two buffers if the spare allocation fails. The preference is saved as
streaming.gpu_buffer_count, and the stream log reports the active buffer count.Screenshot
Issues Fixed or Closed
Roadmap Issues
Testing
Compared base commit
7655ca2with the depth release and the default buffer policy in Vulkan xemu. Both used 64 MiB of guest RAM, fixed H.264 video, stereo Opus audio, and live stats. The results show new video frames submitted per second and minimum free guest RAM during playback.The buffer setting was tested separately at 30 and 60 FPS using the same xemu workload. Each pair compares the Auto policy baseline with the explicit setting.
cmake --build cmake-build-release --parallel 8built the Xbox release ISO.ctest --test-dir cmake-build-release --output-on-failurepassed all 510 native tests, including buffer count selection across output modes, settings persistence and validation, depth release ordering, and allocation and timeout fallbacks.cmake --build cmake-build-release --target docspassed the strict API docs build.uv run --locked lb-update-clang-formatandgit diff --checkpassed.Physical Xbox validation is pending.
Type of Change
Checklist
AI Usage
See our AI usage policy.