mirror of
https://github.com/ubiquitarianism/leonida.git
synced 2026-11-26 23:10:53 +01:00
[PR #537] RT-XAPPCAPTURE: serve XAppCaptureImpl in the xgameruntime shim - the exe's last unserved thunk #584
Labels
No labels
bug
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
starred/leonida#584
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
📋 Pull Request Information
Original PR: https://github.com/ubiquitarianism/leonida/pull/537
Author: @tengotengo
Created: 11/24/2026
Status: 🔄 Open
Base:
main← Head:rt-xappcapture📝 Commits (2)
e7dc1e2xgameruntime: serve XAppCaptureImpl (RT-XAPPCAPTURE) - the exe's last unserved thunk2581f6ddocs: rewrite the served-classes note for post-#401 main (XAppCapture offline E_NOTIMPL availability)📊 Changes
4 files changed (+72 additions, -15 deletions)
View changed files
📝
docs/runtime_imports.md(+11 -7)📝
runtime/shims/xgameruntime.cpp(+41 -4)📝
runtime/test/xgameruntime_test.cpp(+19 -3)📝
tests/test_gdk_runtime_calls.py(+1 -1)📄 Description
Claimed in the coordination issue as: RT-XAPPCAPTURE (#14)
What and why
The retail executable's one xgameruntime reference this file used to refuse: it queries the class
a4f1aee2-4bf1-4485-b008-a7c26d52ac27forIXAppCaptureImpl4and calls slot 5,XAppCaptureTakeScreenshot(measured ingame_scarlett_master.exe; one thunk).QueryApiImplanswered
kClassNotProvidedfor it, so the call died on a null pointer path andXGameRuntimeIsFeatureAvailable(XAppCapture)reported false.This pull request serves the class from
runtime/shims/xgameruntime.cpp:IXAppCaptureImpl .. 4layout fromtools/gdk_runtime_classes.json(18 slots:IUnknown + Impl's 8 + Impl2's 4 + Impl3's 2 + Impl4's 1). The class id is also
IXAppCaptureImpl's id, and the object answers the class id and the v2/v3/v4 interface ids(the executable requests with the v4 interface id).
E_NOTIMPL(thenet_not_implementedpattern): a title that checks the HRESULT sees unsupported, andXAppCapturein the feature table becomes available, which matches Microsoft documenting itfor Windows.
kAppCaptureClassIdrenamed tokAppCaptureClass, sotools/gdk_runtime_calls.pycounts theclass as served.
With it, every thunk the executable references is served: the tool's report on the exe goes
from
not-served-referenced: XAppCaptureImpl (slot 5)tonot-served=- not-served-referenced=-(161 thunks, 158 referenced, 17 classes).
Tested
Windows cross-build (clang-cl 23.1.4 + xwin SDK 10.0.26100 splat) on a Linux box with an RTX 5060 Ti:
runtime/test/xgameruntime_testunder Wine 11.21: 161 checks, all pass - three new: the objectanswers the class id and the v4 interface id, slot 5 refuses with
E_NOTIMPL, a bogus interfaceid is
E_NOINTERFACE; the feature-availability consistency check now covers XAppCapture=true.ctestunder Wine: 23 failures before and after this change, byte-identical failure set(276/299 pass both ways) - the 23 are the documented headless-Wine environment failures
(presentation without a display, host-D3D12 comparisons, GameInput/SDL3), not regressions.
python3 -I tests/test_gdk_runtime_calls.py: 23 tests OK (the served-class assertion updatedfrom notIn to
kAppCaptureClass).tools/gdk_runtime_calls.pyre-run on the exe: XAppCaptureImpl now "served by the runtime";zero unserved classes.
scripts/check_no_game_data.pyon the changed files: clean.retail package.
AI-assisted: yes (Claude Code)
Checklist
docs/design.md, with how it was confirmed. (not applicable: no translator change)🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.