Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 9 additions & 3 deletions src/Deferred.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -378,8 +378,11 @@ void Deferred::DeferredPasses()
auto& normalRoughnessCopy = renderer->GetRuntimeData().renderTargets[normalRoughnessCopyRT];
float2 resolution = Util::ConvertToDynamic(globals::state->screenSize);
D3D11_BOX srcBox = { 0, 0, 0, (UINT)resolution.x, (UINT)resolution.y, 1 };
context->CopySubresourceRegion(mainCopy.texture, 0, 0, 0, 0, main.texture, 0, &srcBox);
context->CopySubresourceRegion(normalRoughnessCopy.texture, 0, 0, 0, 0, normalRoughness.texture, 0, &srcBox);
{
TracyD3D11Zone(globals::state->tracyCtx, "Deferred Composite - Copies");
context->CopySubresourceRegion(mainCopy.texture, 0, 0, 0, 0, main.texture, 0, &srcBox);
context->CopySubresourceRegion(normalRoughnessCopy.texture, 0, 0, 0, 0, normalRoughness.texture, 0, &srcBox);
}

// Constant buffers
{
Expand Down Expand Up @@ -443,7 +446,10 @@ void Deferred::DeferredPasses()
context->IASetInputLayout(nullptr);
context->IASetPrimitiveTopology(D3D11_PRIMITIVE_TOPOLOGY_TRIANGLELIST);

context->Draw(3, 0);
{
TracyD3D11Zone(globals::state->tracyCtx, "Deferred Composite - Draw");
context->Draw(3, 0);
}

stateBackup.Restore(context);
}
Expand Down
5 changes: 5 additions & 0 deletions src/Features/Upscaling.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1912,6 +1912,8 @@ void Upscaling::UpscaleDepth()
};

{
TracyD3D11Zone(globals::state->tracyCtx, "Upscaling - Depth Upscale");

// Engine copies kMAIN→kMAIN_COPY during 3D scene rendering.
// In non-3D contexts (map, main menu, loading, pause) the engine skips its copy.
auto* ui = globals::game::ui;
Expand Down Expand Up @@ -1947,6 +1949,8 @@ void Upscaling::UpscaleDepth()
}

{
TracyD3D11Zone(globals::state->tracyCtx, "Upscaling - Underwater Mask");

viewport.Width = screenSize.x * 0.5f;
viewport.Height = screenSize.y * 0.5f;
context->RSSetViewports(1, &viewport);
Expand All @@ -1969,6 +1973,7 @@ void Upscaling::UpscaleDepth()

// Now propagate the upscaled depth to kMAIN_COPY so downstream VR passes see it.
if (globals::game::isVR) {
TracyD3D11Zone(globals::state->tracyCtx, "Upscaling - Depth VR Propagate");
copyIfNonAliased(depthCopy.texture, depth.texture);
}

Expand Down
Loading