HLE: implement remaining XAccessibility closed-caption, high-contrast, and speech-to-text slots #2076
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!2076
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-2076"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@fuzeofficlal on GitHub · 2026-11-25 04:23 UTC · original
fuzeofficlal:feat/hle-xaccessibility-slots-865→main· +274 −25 · 1 files · 1 commits · openCloses #865.
Summary
0x18,0x20): implementXClosedCaptionGetProperties(ClosedCaptionPropertiesmatching the 28-byte GDK layout, returningHRESULT_FROM_WIN32(ERROR_NOT_FOUND)while captions are disabled andS_OKonce enabled viaXClosedCaptionSetEnabled).0x28): implementXHighContrastGetModereportingXHighContrastMode::Off(0).0x30,0x38,0x88,0x90,0x98,0xa0): wire position hints, string submission, and monotonic non-zero hypothesis IDs across begin/update/finalize/cancel.Testing
crates/victory-hle/src/modules/speech.rscoveringClosedCaptionPropertiesfield offsets/layout, disabled -> enabled -> disabled state transitions, null out-pointer checks, high-contrast mode, and all speech-to-text slots.cargo test -p victory-hle --locked,cargo clippy --workspace --all-targets --all-features -- -D warnings, andcargo xtask policy.@Marvisak on GitHub · 2026-11-25 10:29 UTC · original · edited 2026-11-25 14:47 UTC
Automated triage for the maintainers.
Merge candidate. This fills the remaining
missingslots of the accessibility object incrates/victory-hle/src/modules/speech.rs: closed captions (0x18/0x20), high contrast (0x28, reports off) and speech-to-text (0x30/0x38, 0x88..0xa0, log-only stubs plus hypothesis ids). Both points from the last note are done at8aa346c.caption_propertiesnow always fills the struct withenabledfollowingset_captions_enabledand returnsS_OK(E_INVALIDARGonly for a null pointer, through the sharedput). The code no longer names the console SDK; it uses public function names only, as the rest ofvictory-hledoes. The struct follows the public field order (28 bytes, asserted), and the tests cover the layout, the enable/disable cycle and the stubs. CI check: passing.For the maintainer: the order of the four hypothesis slots inside 0x88..0xa0 is inferred from main's grouping, not from a trace. Only 0x88 writes through an argument (its fifth, on the stack), so that slot is the one to watch if a run shows trouble. The PR description still mentions the old
ERROR_NOT_FOUNDbehaviour and the SDK name; please update it before merge so the squash message is clean.Reply to @fuzeofficlal: thanks, both changes are in and match what was asked.
Generated by Claude Code
@fuzeofficlal on GitHub · 2026-11-25 10:53 UTC · original
Updated in
3ed35da8per triage feedback:ClosedCaptionPropertiesand reworded all comments to cite only the public Microsoft Learn GDK Game Accessibility (XAccessibility) API reference.0x18XClosedCaptionGetProperties,0x20XClosedCaptionSetEnabled,0x28XHighContrastGetMode,0x30XSpeechToTextSetPositionHint,0x38XSpeechToTextSendString, and0x88..=0xa0XSpeechToTextBegin/Update/Finalize/CancelHypothesisString).// shortcut:onNOT_FOUND(0x8007_0490): the publicXClosedCaptionGetPropertiesreference specifies that it succeeds only when closed captions are enabled (SUCCEEDED(...)) and otherwise returns an errorHRESULTwithout naming a specific code, soHRESULT_FROM_WIN32(ERROR_NOT_FOUND)is used as a disabled-state error distinct fromE_NOTIMPL, transitioning toS_OKonce0x20enables captions.@fuzeofficlal on GitHub · 2026-11-25 13:09 UTC · original
Updated in
8aa346c6(rebased onto940d32f):caption_properties(slot0x18): Always writesClosedCaptionProperties(DEFAULT_CAPTIONSwithenabledreflectingCAPTIONS_ENABLED) and returnsS_OKwhenoutis non-null (E_INVALIDARGon null), removingNOT_FOUND. Updatedclosed_captions_follow_enabled_state_and_layoutaccordingly.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.