You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm rewriting my DirectX rust project in C# and this piece of code (same logic of the rust project) throws an Acces Violation exception.
Actual behavior
vardescriptorHeapDescription=newD3D12_DESCRIPTOR_HEAP_DESC(){NumDescriptors=3,Type=D3D12_DESCRIPTOR_HEAP_TYPE.D3D12_DESCRIPTOR_HEAP_TYPE_RTV};// Device is an object that implements ID3D12Device10.Device.CreateDescriptorHeap(descriptorHeapDescription,typeof(ID3D12DescriptorHeap).GUID,outobjectdescriptorHeap);((ID3D12DescriptorHeap)descriptorHeap).GetCPUDescriptorHandleForHeapStart();
That last line where i call the .GetCPUDescriptorHandleForHeapStart() is where this exception is thrown:
Exception thrown at 0x00007FFB01900657 (D3D12Core.dll) in DirectXPInvoke.exe: 0xC0000005: Access violation writing location 0x0000000000000009.
Expected behavior
As this doesn't happen on rust and I'm basically translating from one language to another I expect this to work normally and return the handle.
I also put ID3D12Device10.CreateDescriptorHeap inside the preserveSigMethods of NativeMethods.json, and checked if the HRESULT of the Heap Creation was successful returning S_OK. It did create succesfully the heap.
I'm rewriting my DirectX rust project in C# and this piece of code (same logic of the rust project) throws an Acces Violation exception.
Actual behavior
That last line where i call the
.GetCPUDescriptorHandleForHeapStart()
is where this exception is thrown:Exception thrown at 0x00007FFB01900657 (D3D12Core.dll) in DirectXPInvoke.exe: 0xC0000005: Access violation writing location 0x0000000000000009.
Expected behavior
As this doesn't happen on rust and I'm basically translating from one language to another I expect this to work normally and return the handle.
I also put
ID3D12Device10.CreateDescriptorHeap
inside thepreserveSigMethods
of NativeMethods.json, and checked if the HRESULT of the Heap Creation was successful returning S_OK. It did create succesfully the heap.Repro steps
NativeMethods.txt
content:NativeMethods.json
Context
The text was updated successfully, but these errors were encountered: