Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add UpdateSubresource and MemcpySubresource overloads taking D3D12_SUBRESOURCE_INFO* #635

Merged
merged 2 commits into from
Aug 12, 2020

Conversation

john-h-k
Copy link
Contributor

Adds overloads for all 3 UpdateSubresources and MemcpySubresource which takes D3D12_SUBRESOURCE_INFO (which stores an offset rather than an absolute pointer) and a const void* rather than D3D12_SUBRESOURCE_DATA, which is useful in several scenarios working with D3D from .NET (where interior data pointers cannot be trivially passed around or stored on the heap, as well general scenarios where offsets are stored rather than the absolute subresource pointers)

cc @jenatali as i mentioned in discord 😄

…BRESOURCE_INFO*

Adds overloads for all 3 `UpdateSubresources` and `MemcpySubresource` which takes `D3D12_SUBRESOURCE_INFO` (which stores an offset rather than an absolute pointer) and a `const void*` rather than `D3D12_SUBRESOURCE_DATA`, which is useful in several scenarios working with D3D from .NET (where interior data pointers cannot be trivially passed around or stored on the heap),
Copy link
Member

@jenatali jenatali left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks reasonable to me. I'm wondering if there was a cleaner way other than copy/pasting the full implementation, but I can't really think of one that would be worth the effort.

@sebmerry
Copy link
Member

@john-h-k thank you! I resolved a conflict, if you're happy with the change I'll merge it and update the rest of the samples to use this new version of d3dx12.h.

@john-h-k
Copy link
Contributor Author

Thanks! Looks good to me

@sebmerry sebmerry merged commit 1f37cd2 into microsoft:master Aug 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants