DXMT: forward D3D10 start instance location#761
Conversation
|
Thank you for your pull request and welcome to our community! To contribute, please sign the Oracle Contributor Agreement (OCA).
To sign the OCA, please create an Oracle account and sign the OCA in Oracle's Contributor Agreement Application. When signing the OCA, please provide your GitHub username. After signing the OCA and getting an OCA approval from Oracle, this PR will be automatically updated. If you are an Oracle employee, please make sure that you are a member of the main Oracle GitHub organization, and your membership in this organization is public. |
|
DXMT v0.80 audit update: Updating the vendored DXMT tree to v0.80 would not address this. DXMT v0.80 and current DXMT I opened the equivalent upstream DXMT issue and PR: |
Signed-off-by: Roberto Nibali <rnibali@gmail.com>
3c2e8d5 to
828de51
Compare
Summary
Forward the D3D10
DrawIndexedInstancedstart-instance argument to the underlying D3D11 context.The patch changes one argument at the wrapper boundary: the final D3D11 parameter now uses the incoming
StartInstanceLocationrather than repeatingStartIndexLocation.Deterministic reproduction
Call the D3D10 wrapper with distinct values, for example:
Current code calls the D3D11 context with final argument
6; the D3D10 and D3D11 method declarations both specify that the final argument is the start-instance location, so the forwarded value must be2. The one-line patch makes that mapping exact.Impact
D3D10 indexed instanced draws with a non-zero start instance can otherwise use the start-index value as the base instance, selecting incorrect instance IDs or per-instance vertex data.
Validation
origin/main(5ac81eda).git diff --checkpasses.kmk VBoxDxMton macOS/Arm with LLVM 15.0.7.VBoxDxMt.dylib.Closes #760.
Signed-off-by: Roberto Nibali rnibali@gmail.com