Repository navigation
Conversation
XMA source voices play through a Windows PCM16 voice, and the callback wrapper passed that voice's OnVoiceProcessingPassStart BytesRequired (the PCM16 it needs) on to the title. Microsoft's documentation: "For xWMA and XMA data BytesRequired will always be zero". A title that streams just in time from this value would see its XMA voice as starving and submit more than it needs. The voice state now records whether the title submits XMA, and only then is 0 passed on. Opus voices, which the documentation does not cover, keep the count as before. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner
Author
|
Upstream PR xcl-dev#1149 was closed or merged. |
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.
XMA source voices play through a Windows PCM16 voice. XCL's callback wrapper passed that voice's
OnVoiceProcessingPassStartBytesRequired(the PCM16 it needs) on to the title. Microsoft's documentation ofIXAudio2VoiceCallback::OnVoiceProcessingPassStartsays that for xWMA and XMA dataBytesRequiredis always zero. A title that streams just in time from this value sees its XMA voice as starving and submits more data than it needs.The voice state now records whether the title submits XMA, and only then passes 0 on. Opus voices, which the documentation does not cover, keep the count as before.
What is in it
crates/xcl/src/hle/xaudio2.rs:DecodedVoiceStateremembers whether the voice is XMA; the pass-start wrapper reports 0 for it. Testdecoded_voice_reports_no_bytes_required_to_the_title(XMA reports 0, an Opus voice still reports the PCM count).Tested
cargo test --workspace -- --test-threads=4on 41c4305: 742 passed, 0 failed, 41 ignored; no SKIPPED GPU testsplaced_title_textures_share_vram_and_preserve_pixels(the cubemap reuse flake of Tests: placed_title_textures_share_vram_and_preserve_pixels fails now and then at its cubemap reuse check (main 9ce2070) xcl-dev/xcl#718, two other tests then failed on its poisoned lock);cargo test -p xcl --lib hle::d3d12x::then passed 3 times in a row on this head, and the whole suite again (the counts above)Regression run
main:
this PR:
Not tested
BytesRequired: the smoke title does not show a difference in its run.AI use
🤖 Generated with Claude Code
Mirror of xcl-dev#1149 (auto-synced, do not edit).