microsoft / D3D12TranslationLayer

A library containing utilities for mapping higher-level graphics work to D3D12
MIT License
327 stars 47 forks source link

Use per-plane map refcounts instead of just a bitmask #52

Closed jenatali closed 2 years ago

jenatali commented 2 years ago

This was originally written with D3D11 in mind, which will block recursive maps, but D3D9 (and older) will let them through. This fixes a bug with double-unmap attempting to access a null pRenameResource.

Also fix the calls to actually map the heaps to use subresource index instead of plane index.