mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-05-29 13:20:54 +00:00
Disable blending when rendering custom shader output
This commit is contained in:
@@ -514,13 +514,7 @@ bool D3D12Replay::RenderTextureInternal(D3D12_CPU_DESCRIPTOR_HANDLE rtv, Texture
|
||||
pipeDesc.NumRenderTargets = 1;
|
||||
pipeDesc.RTVFormats[0] = DXGI_FORMAT_R16G16B16A16_FLOAT;
|
||||
pipeDesc.DSVFormat = DXGI_FORMAT_UNKNOWN;
|
||||
pipeDesc.BlendState.RenderTarget[0].BlendEnable = TRUE;
|
||||
pipeDesc.BlendState.RenderTarget[0].SrcBlend = D3D12_BLEND_SRC_ALPHA;
|
||||
pipeDesc.BlendState.RenderTarget[0].DestBlend = D3D12_BLEND_INV_SRC_ALPHA;
|
||||
pipeDesc.BlendState.RenderTarget[0].BlendOp = D3D12_BLEND_OP_ADD;
|
||||
pipeDesc.BlendState.RenderTarget[0].SrcBlendAlpha = D3D12_BLEND_SRC_ALPHA;
|
||||
pipeDesc.BlendState.RenderTarget[0].DestBlendAlpha = D3D12_BLEND_INV_SRC_ALPHA;
|
||||
pipeDesc.BlendState.RenderTarget[0].BlendOpAlpha = D3D12_BLEND_OP_ADD;
|
||||
pipeDesc.BlendState.RenderTarget[0].BlendEnable = FALSE;
|
||||
pipeDesc.BlendState.RenderTarget[0].RenderTargetWriteMask = D3D12_COLOR_WRITE_ENABLE_ALL;
|
||||
|
||||
HRESULT hr = m_pDevice->CreateGraphicsPipelineState(&pipeDesc, __uuidof(ID3D12PipelineState),
|
||||
|
||||
@@ -643,7 +643,7 @@ bool GLReplay::RenderTextureInternal(TextureDisplay cfg, TexDisplayFlags flags)
|
||||
drv.glUnmapBuffer(eGL_UNIFORM_BUFFER);
|
||||
}
|
||||
|
||||
if(cfg.rawOutput || !blendAlpha)
|
||||
if(cfg.rawOutput || !blendAlpha || cfg.customShaderId != ResourceId())
|
||||
{
|
||||
drv.glDisable(eGL_BLEND);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user