[D3D12] Put shared memory in PS resource state because vfetch seems allowed in PS

This commit is contained in:
Triang3l 2018-11-16 13:12:51 +03:00
parent 38f421e89f
commit e46244a996
1 changed files with 3 additions and 1 deletions

View File

@ -538,8 +538,10 @@ void SharedMemory::TransitionBuffer(D3D12_RESOURCE_STATES new_state) {
} }
void SharedMemory::UseForReading() { void SharedMemory::UseForReading() {
// Vertex fetch also seems to be allowed in pixel shaders.
TransitionBuffer(D3D12_RESOURCE_STATE_INDEX_BUFFER | TransitionBuffer(D3D12_RESOURCE_STATE_INDEX_BUFFER |
D3D12_RESOURCE_STATE_NON_PIXEL_SHADER_RESOURCE); D3D12_RESOURCE_STATE_NON_PIXEL_SHADER_RESOURCE |
D3D12_RESOURCE_STATE_PIXEL_SHADER_RESOURCE);
} }
void SharedMemory::UseForWriting() { void SharedMemory::UseForWriting() {