3
0
Fork 0
mirror of https://github.com/lubosz/overte.git synced 2025-04-27 07:35:30 +02:00

Added outline to statsGPU script

This commit is contained in:
Olivier Prat 2017-10-19 16:52:29 +02:00
parent 382262da3d
commit fc66dcfdea
2 changed files with 16 additions and 2 deletions
libraries/render-utils/src
scripts/developer/utilities/render

View file

@ -176,6 +176,7 @@ void RenderDeferredTask::build(JobModel& task, const render::Varying& input, ren
const auto toneMappingInputs = ToneMappingDeferred::Inputs(lightingFramebuffer, primaryFramebuffer).asVarying();
task.addJob<ToneMappingDeferred>("ToneMapping", toneMappingInputs);
const auto outlineRangeTimer = task.addJob<BeginGPURangeTimer>("BeginOutlineRangeTimer", "Outline");
// Select items that need to be outlined
const auto selectionBaseName = "contextOverlayHighlightList";
const auto selectedItems = addSelectItemJobs(task, selectionBaseName, metas, opaques, transparents);
@ -187,12 +188,11 @@ void RenderDeferredTask::build(JobModel& task, const render::Varying& input, ren
selectionName << i;
outlineGroups[i] = addSelectItemJobs(task, selectionName.str().c_str(), metas, opaques, transparents);
}
const auto outlineRangeTimer = task.addJob<BeginGPURangeTimer>("BeginOutlineRangeTimer", "Outline");
const auto outlineInputs = DrawOutlineTask::Inputs(outlineGroups, deferredFramebuffer, primaryFramebuffer, deferredFrameTransform).asVarying();
task.addJob<DrawOutlineTask>("DrawOutline", outlineInputs);
task.addJob<EndGPURangeTimer>("EndOutlineRangeTimer", outlineRangeTimer);
task.addJob<EndGPURangeTimer>("OutlineRangeTimer", outlineRangeTimer);
{ // DEbug the bounds of the rendered items, still look at the zbuffer
task.addJob<DrawBounds>("DrawMetaBounds", metas);

View file

@ -65,6 +65,13 @@ Item {
label: "tone and post",
color: "#FF0000"
}
,
{
object: Render.getConfig("RenderMainView.OutlineRangeTimer"),
prop: "gpuRunTime",
label: "outline",
color: "#FFFF00"
}
]
}
PlotPerf {
@ -105,6 +112,13 @@ Item {
label: "tone and post",
color: "#FF0000"
}
,
{
object: Render.getConfig("RenderMainView.OutlineRangeTimer"),
prop: "batchRunTime",
label: "outline",
color: "#FFFF00"
}
]
}
}