mirror of https://github.com/RPCS3/rpcs3.git
d3d12: depth read doesnt crash anymore
This commit is contained in:
parent
3f31976080
commit
7b25483b67
|
@ -87,7 +87,7 @@ D3D12GSRender::D3D12GSRender()
|
||||||
|
|
||||||
D3D12_RESOURCE_DESC resDesc = {};
|
D3D12_RESOURCE_DESC resDesc = {};
|
||||||
resDesc.Dimension = D3D12_RESOURCE_DIMENSION_BUFFER;
|
resDesc.Dimension = D3D12_RESOURCE_DIMENSION_BUFFER;
|
||||||
resDesc.Width = (UINT)1024 * 1024;
|
resDesc.Width = (UINT)1024 * 1024 * 16;
|
||||||
resDesc.Height = 1;
|
resDesc.Height = 1;
|
||||||
resDesc.DepthOrArraySize = 1;
|
resDesc.DepthOrArraySize = 1;
|
||||||
resDesc.SampleDesc.Count = 1;
|
resDesc.SampleDesc.Count = 1;
|
||||||
|
@ -208,7 +208,7 @@ D3D12GSRender::D3D12GSRender()
|
||||||
|
|
||||||
// Texture
|
// Texture
|
||||||
D3D12_HEAP_DESC heapDescription = {};
|
D3D12_HEAP_DESC heapDescription = {};
|
||||||
heapDescription.SizeInBytes = 256 * 256 * 256;
|
heapDescription.SizeInBytes = 256 * 256 * 256 * 16;
|
||||||
heapDescription.Properties.Type = D3D12_HEAP_TYPE_UPLOAD;
|
heapDescription.Properties.Type = D3D12_HEAP_TYPE_UPLOAD;
|
||||||
check(m_device->CreateHeap(&heapDescription, IID_PPV_ARGS(&m_uploadTextureHeap)));
|
check(m_device->CreateHeap(&heapDescription, IID_PPV_ARGS(&m_uploadTextureHeap)));
|
||||||
|
|
||||||
|
@ -676,7 +676,6 @@ void D3D12GSRender::ExecCMD()
|
||||||
for (u32 i = 0; i < m_textures_count; ++i)
|
for (u32 i = 0; i < m_textures_count; ++i)
|
||||||
{
|
{
|
||||||
if (!m_textures[i].IsEnabled()) continue;
|
if (!m_textures[i].IsEnabled()) continue;
|
||||||
|
|
||||||
ID3D12Resource *Texture, *vramTexture;
|
ID3D12Resource *Texture, *vramTexture;
|
||||||
size_t textureSize = m_textures[i].GetWidth() * m_textures[i].GetHeight() * 4;
|
size_t textureSize = m_textures[i].GetWidth() * m_textures[i].GetHeight() * 4;
|
||||||
D3D12_RESOURCE_DESC textureDesc = {};
|
D3D12_RESOURCE_DESC textureDesc = {};
|
||||||
|
@ -721,6 +720,7 @@ void D3D12GSRender::ExecCMD()
|
||||||
));
|
));
|
||||||
|
|
||||||
m_currentStorageOffset += textureSize;
|
m_currentStorageOffset += textureSize;
|
||||||
|
m_currentStorageOffset = (m_currentStorageOffset + 65536 - 1) & ~65535;
|
||||||
|
|
||||||
D3D12_TEXTURE_COPY_LOCATION dst = {}, src = {};
|
D3D12_TEXTURE_COPY_LOCATION dst = {}, src = {};
|
||||||
dst.pResource = vramTexture;
|
dst.pResource = vramTexture;
|
||||||
|
|
Loading…
Reference in New Issue