mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 09:48:44 +02:00
Fix the local lights issue, and correct the script relying on the Render.getConfig(), this one is on me...
This commit is contained in:
parent
ded1a1eb02
commit
03f3a7eefd
12 changed files with 116 additions and 111 deletions
|
@ -548,6 +548,7 @@ glm::ivec3 LightClusters::updateClusters() {
|
||||||
|
|
||||||
|
|
||||||
LightClusteringPass::LightClusteringPass() {
|
LightClusteringPass::LightClusteringPass() {
|
||||||
|
_lightClusters = std::make_shared<LightClusters>();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -566,12 +567,7 @@ void LightClusteringPass::run(const render::RenderContextPointer& renderContext,
|
||||||
auto deferredTransform = inputs.get0();
|
auto deferredTransform = inputs.get0();
|
||||||
auto lightingModel = inputs.get1();
|
auto lightingModel = inputs.get1();
|
||||||
auto surfaceGeometryFramebuffer = inputs.get2();
|
auto surfaceGeometryFramebuffer = inputs.get2();
|
||||||
|
|
||||||
|
|
||||||
if (!_lightClusters) {
|
|
||||||
_lightClusters = std::make_shared<LightClusters>();
|
|
||||||
}
|
|
||||||
|
|
||||||
// first update the Grid with the new frustum
|
// first update the Grid with the new frustum
|
||||||
if (!_freeze) {
|
if (!_freeze) {
|
||||||
_lightClusters->updateFrustum(args->getViewFrustum());
|
_lightClusters->updateFrustum(args->getViewFrustum());
|
||||||
|
|
|
@ -13,6 +13,7 @@ import "configSlider"
|
||||||
import "../lib/plotperf"
|
import "../lib/plotperf"
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
|
property var mainViewTask: Render.getConfig("RenderMainView")
|
||||||
spacing: 8
|
spacing: 8
|
||||||
Column {
|
Column {
|
||||||
id: surfaceGeometry
|
id: surfaceGeometry
|
||||||
|
@ -32,7 +33,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr(modelData.split(":")[0])
|
label: qsTr(modelData.split(":")[0])
|
||||||
integral: (modelData.split(":")[3] == 'true')
|
integral: (modelData.split(":")[3] == 'true')
|
||||||
config: Render.getConfig("AmbientOcclusion")
|
config: mainViewTask.getConfig("AmbientOcclusion")
|
||||||
property: modelData.split(":")[1]
|
property: modelData.split(":")[1]
|
||||||
max: modelData.split(":")[2]
|
max: modelData.split(":")[2]
|
||||||
min: 0.0
|
min: 0.0
|
||||||
|
@ -50,8 +51,8 @@ Column {
|
||||||
]
|
]
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: qsTr(modelData.split(":")[0])
|
text: qsTr(modelData.split(":")[0])
|
||||||
checked: Render.getConfig("AmbientOcclusion")[modelData.split(":")[1]]
|
checked: mainViewTask.getConfig("AmbientOcclusion")[modelData.split(":")[1]]
|
||||||
onCheckedChanged: { Render.getConfig("AmbientOcclusion")[modelData.split(":")[1]] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("AmbientOcclusion")[modelData.split(":")[1]] = checked }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -62,8 +63,8 @@ Column {
|
||||||
]
|
]
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: qsTr(modelData.split(":")[0])
|
text: qsTr(modelData.split(":")[0])
|
||||||
checked: Render.getConfig("DebugAmbientOcclusion")[modelData.split(":")[1]]
|
checked: mainViewTask.getConfig("DebugAmbientOcclusion")[modelData.split(":")[1]]
|
||||||
onCheckedChanged: { Render.getConfig("DebugAmbientOcclusion")[modelData.split(":")[1]] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DebugAmbientOcclusion")[modelData.split(":")[1]] = checked }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -72,7 +73,7 @@ Column {
|
||||||
PlotPerf {
|
PlotPerf {
|
||||||
title: "Timing"
|
title: "Timing"
|
||||||
height: 50
|
height: 50
|
||||||
object: Render.getConfig("AmbientOcclusion")
|
object: mainViewTask.getConfig("AmbientOcclusion")
|
||||||
valueUnit: "ms"
|
valueUnit: "ms"
|
||||||
valueScale: 1
|
valueScale: 1
|
||||||
valueNumDigits: "3"
|
valueNumDigits: "3"
|
||||||
|
|
|
@ -14,8 +14,9 @@ import "configSlider"
|
||||||
Column {
|
Column {
|
||||||
id: root
|
id: root
|
||||||
spacing: 8
|
spacing: 8
|
||||||
property var sceneOctree: Render.getConfig("DrawSceneOctree");
|
property var mainViewTask: Render.getConfig("RenderMainView");
|
||||||
property var itemSelection: Render.getConfig("DrawItemSelection");
|
property var sceneOctree: mainViewTask.getConfig("DrawSceneOctree");
|
||||||
|
property var itemSelection: mainViewTask.getConfig("DrawItemSelection");
|
||||||
|
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
sceneOctree.enabled = true;
|
sceneOctree.enabled = true;
|
||||||
|
@ -30,8 +31,8 @@ Column {
|
||||||
Component.onDestruction: {
|
Component.onDestruction: {
|
||||||
sceneOctree.enabled = false;
|
sceneOctree.enabled = false;
|
||||||
itemSelection.enabled = false;
|
itemSelection.enabled = false;
|
||||||
Render.getConfig("FetchSceneSelection").freezeFrustum = false;
|
mainViewTask.getConfig("FetchSceneSelection").freezeFrustum = false;
|
||||||
Render.getConfig("CullSceneSelection").freezeFrustum = false;
|
mainViewTask.getConfig("CullSceneSelection").freezeFrustum = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
GroupBox {
|
GroupBox {
|
||||||
|
@ -45,8 +46,8 @@ Column {
|
||||||
text: "Freeze Culling Frustum"
|
text: "Freeze Culling Frustum"
|
||||||
checked: false
|
checked: false
|
||||||
onCheckedChanged: {
|
onCheckedChanged: {
|
||||||
Render.getConfig("FetchSceneSelection").freezeFrustum = checked;
|
mainViewTask.getConfig("FetchSceneSelection").freezeFrustum = checked;
|
||||||
Render.getConfig("CullSceneSelection").freezeFrustum = checked;
|
mainViewTask.getConfig("CullSceneSelection").freezeFrustum = checked;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Label {
|
Label {
|
||||||
|
@ -103,7 +104,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr(modelData.split(":")[0])
|
label: qsTr(modelData.split(":")[0])
|
||||||
integral: true
|
integral: true
|
||||||
config: Render.getConfig(modelData.split(":")[1])
|
config: mainViewTask.getConfig(modelData.split(":")[1])
|
||||||
property: "maxDrawn"
|
property: "maxDrawn"
|
||||||
max: config.numDrawn
|
max: config.numDrawn
|
||||||
min: -1
|
min: -1
|
||||||
|
|
|
@ -34,5 +34,5 @@ function setDebugCursor(x, y) {
|
||||||
nx = (x / Window.innerWidth);
|
nx = (x / Window.innerWidth);
|
||||||
ny = 1.0 - ((y) / (Window.innerHeight - 32));
|
ny = 1.0 - ((y) / (Window.innerHeight - 32));
|
||||||
|
|
||||||
Render.getConfig("DebugAmbientOcclusion").debugCursorTexcoord = { x: nx, y: ny };
|
Render.getConfig("RenderMainView").getConfig("DebugAmbientOcclusion").debugCursorTexcoord = { x: nx, y: ny };
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,5 +33,5 @@ function setDebugCursor(x, y) {
|
||||||
nx = (x / Window.innerWidth);
|
nx = (x / Window.innerWidth);
|
||||||
ny = 1.0 - ((y) / (Window.innerHeight - 32));
|
ny = 1.0 - ((y) / (Window.innerHeight - 32));
|
||||||
|
|
||||||
Render.getConfig("DebugScattering").debugCursorTexcoord = { x: nx, y: ny };
|
Render.getConfig("RenderMainView").getConfig("DebugScattering").debugCursorTexcoord = { x: nx, y: ny };
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,6 +13,7 @@ import "configSlider"
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
property var mainViewTask: Render.getConfig("RenderMainView")
|
||||||
|
|
||||||
Row {
|
Row {
|
||||||
spacing: 8
|
spacing: 8
|
||||||
|
@ -29,8 +30,8 @@ Column {
|
||||||
]
|
]
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: modelData.split(":")[0]
|
text: modelData.split(":")[0]
|
||||||
checked: Render.getConfig(modelData.split(":")[1])[modelData.split(":")[2]]
|
checked: mainViewTask.getConfig(modelData.split(":")[1])[modelData.split(":")[2]]
|
||||||
onCheckedChanged: { Render.getConfig(modelData.split(":")[1])[modelData.split(":")[2]] = checked }
|
onCheckedChanged: { mainViewTask.getConfig(modelData.split(":")[1])[modelData.split(":")[2]] = checked }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -49,8 +50,8 @@ Column {
|
||||||
]
|
]
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: modelData.split(":")[0]
|
text: modelData.split(":")[0]
|
||||||
checked: Render.getConfig(modelData.split(":")[1])[modelData.split(":")[2]]
|
checked: mainViewTask.getConfig(modelData.split(":")[1])[modelData.split(":")[2]]
|
||||||
onCheckedChanged: { Render.getConfig(modelData.split(":")[1])[modelData.split(":")[2]] = checked }
|
onCheckedChanged: { mainViewTask.getConfig(modelData.split(":")[1])[modelData.split(":")[2]] = checked }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -69,8 +70,8 @@ Column {
|
||||||
]
|
]
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: modelData.split(":")[0]
|
text: modelData.split(":")[0]
|
||||||
checked: Render.getConfig(modelData.split(":")[1])[modelData.split(":")[2]]
|
checked: mainViewTask.getConfig(modelData.split(":")[1])[modelData.split(":")[2]]
|
||||||
onCheckedChanged: { Render.getConfig(modelData.split(":")[1])[modelData.split(":")[2]] = checked }
|
onCheckedChanged: { mainViewTask.getConfig(modelData.split(":")[1])[modelData.split(":")[2]] = checked }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -83,7 +84,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr(modelData.split(":")[0])
|
label: qsTr(modelData.split(":")[0])
|
||||||
integral: false
|
integral: false
|
||||||
config: Render.getConfig(modelData.split(":")[1])
|
config: mainViewTask.getConfig(modelData.split(":")[1])
|
||||||
property: modelData.split(":")[2]
|
property: modelData.split(":")[2]
|
||||||
max: modelData.split(":")[3]
|
max: modelData.split(":")[3]
|
||||||
min: modelData.split(":")[4]
|
min: modelData.split(":")[4]
|
||||||
|
@ -107,7 +108,7 @@ Column {
|
||||||
ListElement { text: "Filmic"; color: "White" }
|
ListElement { text: "Filmic"; color: "White" }
|
||||||
}
|
}
|
||||||
width: 200
|
width: 200
|
||||||
onCurrentIndexChanged: { Render.getConfig("ToneMapping")["curve"] = currentIndex }
|
onCurrentIndexChanged: { mainViewTask.getConfig("ToneMapping")["curve"] = currentIndex }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -120,7 +121,7 @@ Column {
|
||||||
anchors.left: root.left
|
anchors.left: root.left
|
||||||
}
|
}
|
||||||
|
|
||||||
property var config: Render.getConfig("DebugDeferredBuffer")
|
property var config: mainViewTask.getConfig("DebugDeferredBuffer")
|
||||||
|
|
||||||
function setDebugMode(mode) {
|
function setDebugMode(mode) {
|
||||||
framebuffer.config.enabled = (mode != 0);
|
framebuffer.config.enabled = (mode != 0);
|
||||||
|
@ -168,40 +169,40 @@ Column {
|
||||||
|
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Opaques"
|
text: "Opaques"
|
||||||
checked: Render.getConfig("DrawOpaqueBounds")["enabled"]
|
checked: mainViewTask.getConfig("DrawOpaqueBounds")["enabled"]
|
||||||
onCheckedChanged: { Render.getConfig("DrawOpaqueBounds")["enabled"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DrawOpaqueBounds")["enabled"] = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Transparents"
|
text: "Transparents"
|
||||||
checked: Render.getConfig("DrawTransparentBounds")["enabled"]
|
checked: mainViewTask.getConfig("DrawTransparentBounds")["enabled"]
|
||||||
onCheckedChanged: { Render.getConfig("DrawTransparentBounds")["enabled"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DrawTransparentBounds")["enabled"] = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Overlay Opaques"
|
text: "Overlay Opaques"
|
||||||
checked: Render.getConfig("DrawOverlayOpaqueBounds")["enabled"]
|
checked: mainViewTask.getConfig("DrawOverlayOpaqueBounds")["enabled"]
|
||||||
onCheckedChanged: { Render.getConfig("DrawOverlayOpaqueBounds")["enabled"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DrawOverlayOpaqueBounds")["enabled"] = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Overlay Transparents"
|
text: "Overlay Transparents"
|
||||||
checked: Render.getConfig("DrawOverlayTransparentBounds")["enabled"]
|
checked: mainViewTask.getConfig("DrawOverlayTransparentBounds")["enabled"]
|
||||||
onCheckedChanged: { Render.getConfig("DrawOverlayTransparentBounds")["enabled"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DrawOverlayTransparentBounds")["enabled"] = checked }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Column {
|
Column {
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Metas"
|
text: "Metas"
|
||||||
checked: Render.getConfig("DrawMetaBounds")["enabled"]
|
checked: mainViewTask.getConfig("DrawMetaBounds")["enabled"]
|
||||||
onCheckedChanged: { Render.getConfig("DrawMetaBounds")["enabled"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DrawMetaBounds")["enabled"] = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Lights"
|
text: "Lights"
|
||||||
checked: Render.getConfig("DrawLightBounds")["enabled"]
|
checked: mainViewTask.getConfig("DrawLightBounds")["enabled"]
|
||||||
onCheckedChanged: { Render.getConfig("DrawLightBounds")["enabled"] = checked; }
|
onCheckedChanged: { mainViewTask.getConfig("DrawLightBounds")["enabled"] = checked; }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Zones"
|
text: "Zones"
|
||||||
checked: Render.getConfig("DrawZones")["enabled"]
|
checked: mainViewTask.getConfig("DrawZones")["enabled"]
|
||||||
onCheckedChanged: { Render.getConfig("ZoneRenderer")["enabled"] = checked; Render.getConfig("DrawZones")["enabled"] = checked; }
|
onCheckedChanged: { mainViewTask.getConfig("ZoneRenderer")["enabled"] = checked; mainViewTask.getConfig("DrawZones")["enabled"] = checked; }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,18 +17,19 @@ Column {
|
||||||
Column {
|
Column {
|
||||||
id: lightClustering
|
id: lightClustering
|
||||||
spacing: 10
|
spacing: 10
|
||||||
|
property var mainViewTask: Render.getConfig("RenderMainView");
|
||||||
|
|
||||||
Column{
|
Column{
|
||||||
PlotPerf {
|
PlotPerf {
|
||||||
title: "Light CLustering Timing"
|
title: "Light CLustering Timing"
|
||||||
height: 50
|
height: 50
|
||||||
object: Render.getConfig("LightClustering")
|
object: mainViewTask.getConfig("LightClustering")
|
||||||
valueUnit: "ms"
|
valueUnit: "ms"
|
||||||
valueScale: 1
|
valueScale: 1
|
||||||
valueNumDigits: "4"
|
valueNumDigits: "4"
|
||||||
plots: [
|
plots: [
|
||||||
{
|
{
|
||||||
object: Render.getConfig("LightClustering"),
|
object: mainViewTask.getConfig("LightClustering"),
|
||||||
prop: "cpuRunTime",
|
prop: "cpuRunTime",
|
||||||
label: "time",
|
label: "time",
|
||||||
scale: 1,
|
scale: 1,
|
||||||
|
@ -40,19 +41,19 @@ Column {
|
||||||
PlotPerf {
|
PlotPerf {
|
||||||
title: "Lights"
|
title: "Lights"
|
||||||
height: 50
|
height: 50
|
||||||
object: Render.getConfig("LightClustering")
|
object: mainViewTask.getConfig("LightClustering")
|
||||||
valueUnit: ""
|
valueUnit: ""
|
||||||
valueScale: 1
|
valueScale: 1
|
||||||
valueNumDigits: "0"
|
valueNumDigits: "0"
|
||||||
plots: [
|
plots: [
|
||||||
{
|
{
|
||||||
object: Render.getConfig("LightClustering"),
|
object: mainViewTask.getConfig("LightClustering"),
|
||||||
prop: "numClusteredLights",
|
prop: "numClusteredLights",
|
||||||
label: "visible",
|
label: "visible",
|
||||||
color: "#D959FE"
|
color: "#D959FE"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("LightClustering"),
|
object: mainViewTask.getConfig("LightClustering"),
|
||||||
prop: "numInputLights",
|
prop: "numInputLights",
|
||||||
label: "input",
|
label: "input",
|
||||||
color: "#FED959"
|
color: "#FED959"
|
||||||
|
@ -63,25 +64,25 @@ Column {
|
||||||
PlotPerf {
|
PlotPerf {
|
||||||
title: "Scene Lights"
|
title: "Scene Lights"
|
||||||
height: 80
|
height: 80
|
||||||
object: Render.getConfig("LightClustering")
|
object: mainViewTask.getConfig("LightClustering")
|
||||||
valueUnit: ""
|
valueUnit: ""
|
||||||
valueScale: 1
|
valueScale: 1
|
||||||
valueNumDigits: "0"
|
valueNumDigits: "0"
|
||||||
plots: [
|
plots: [
|
||||||
{
|
{
|
||||||
object: Render.getConfig("LightClustering"),
|
object: mainViewTask.getConfig("LightClustering"),
|
||||||
prop: "numSceneLights",
|
prop: "numSceneLights",
|
||||||
label: "current",
|
label: "current",
|
||||||
color: "#00B4EF"
|
color: "#00B4EF"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("LightClustering"),
|
object: mainViewTask.getConfig("LightClustering"),
|
||||||
prop: "numFreeSceneLights",
|
prop: "numFreeSceneLights",
|
||||||
label: "free",
|
label: "free",
|
||||||
color: "#1AC567"
|
color: "#1AC567"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("LightClustering"),
|
object: mainViewTask.getConfig("LightClustering"),
|
||||||
prop: "numAllocatedSceneLights",
|
prop: "numAllocatedSceneLights",
|
||||||
label: "allocated",
|
label: "allocated",
|
||||||
color: "#9495FF"
|
color: "#9495FF"
|
||||||
|
@ -92,7 +93,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr("Range Near [m]")
|
label: qsTr("Range Near [m]")
|
||||||
integral: false
|
integral: false
|
||||||
config: Render.getConfig("LightClustering")
|
config: mainViewTask.getConfig("LightClustering")
|
||||||
property: "rangeNear"
|
property: "rangeNear"
|
||||||
max: 20.0
|
max: 20.0
|
||||||
min: 0.1
|
min: 0.1
|
||||||
|
@ -100,7 +101,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr("Range Far [m]")
|
label: qsTr("Range Far [m]")
|
||||||
integral: false
|
integral: false
|
||||||
config: Render.getConfig("LightClustering")
|
config: mainViewTask.getConfig("LightClustering")
|
||||||
property: "rangeFar"
|
property: "rangeFar"
|
||||||
max: 500.0
|
max: 500.0
|
||||||
min: 100.0
|
min: 100.0
|
||||||
|
@ -108,7 +109,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr("Grid X")
|
label: qsTr("Grid X")
|
||||||
integral: true
|
integral: true
|
||||||
config: Render.getConfig("LightClustering")
|
config: mainViewTask.getConfig("LightClustering")
|
||||||
property: "dimX"
|
property: "dimX"
|
||||||
max: 32
|
max: 32
|
||||||
min: 1
|
min: 1
|
||||||
|
@ -116,7 +117,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr("Grid Y")
|
label: qsTr("Grid Y")
|
||||||
integral: true
|
integral: true
|
||||||
config: Render.getConfig("LightClustering")
|
config: mainViewTask.getConfig("LightClustering")
|
||||||
property: "dimY"
|
property: "dimY"
|
||||||
max: 32
|
max: 32
|
||||||
min: 1
|
min: 1
|
||||||
|
@ -124,33 +125,33 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr("Grid Z")
|
label: qsTr("Grid Z")
|
||||||
integral: true
|
integral: true
|
||||||
config: Render.getConfig("LightClustering")
|
config: mainViewTask.getConfig("LightClustering")
|
||||||
property: "dimZ"
|
property: "dimZ"
|
||||||
max: 31
|
max: 31
|
||||||
min: 1
|
min: 1
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Freeze"
|
text: "Freeze"
|
||||||
checked: Render.getConfig("LightClustering")["freeze"]
|
checked: mainViewTask.getConfig("LightClustering")["freeze"]
|
||||||
onCheckedChanged: { Render.getConfig("LightClustering")["freeze"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("LightClustering")["freeze"] = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Draw Grid"
|
text: "Draw Grid"
|
||||||
checked: Render.getConfig("DebugLightClusters")["doDrawGrid"]
|
checked: mainViewTask.getConfig("DebugLightClusters")["doDrawGrid"]
|
||||||
onCheckedChanged: { Render.getConfig("DebugLightClusters")["doDrawGrid"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DebugLightClusters")["doDrawGrid"] = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Draw Cluster From Depth"
|
text: "Draw Cluster From Depth"
|
||||||
checked: Render.getConfig("DebugLightClusters")["doDrawClusterFromDepth"]
|
checked: mainViewTask.getConfig("DebugLightClusters")["doDrawClusterFromDepth"]
|
||||||
onCheckedChanged: { Render.getConfig("DebugLightClusters")["doDrawClusterFromDepth"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DebugLightClusters")["doDrawClusterFromDepth"] = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Draw Content"
|
text: "Draw Content"
|
||||||
checked: Render.getConfig("DebugLightClusters")["doDrawContent"]
|
checked: mainViewTask.getConfig("DebugLightClusters")["doDrawContent"]
|
||||||
onCheckedChanged: { Render.getConfig("DebugLightClusters")["doDrawContent"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DebugLightClusters")["doDrawContent"] = checked }
|
||||||
}
|
}
|
||||||
Label {
|
Label {
|
||||||
text: "Num Cluster Items = " + Render.getConfig("LightClustering")["numClusteredLightReferences"].toFixed(0)
|
text: "Num Cluster Items = " + mainViewTask.getConfig("LightClustering")["numClusteredLightReferences"].toFixed(0)
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,7 +21,8 @@ Item {
|
||||||
spacing: 8
|
spacing: 8
|
||||||
anchors.fill:parent
|
anchors.fill:parent
|
||||||
|
|
||||||
property var config: Render.getConfig("Stats")
|
property var mainViewTask: Render.getConfig("RenderMainView");
|
||||||
|
property var config: mainViewTask.getConfig("Stats")
|
||||||
|
|
||||||
function evalEvenHeight() {
|
function evalEvenHeight() {
|
||||||
// Why do we have to do that manually ? cannot seem to find a qml / anchor / layout mode that does that ?
|
// Why do we have to do that manually ? cannot seem to find a qml / anchor / layout mode that does that ?
|
||||||
|
@ -182,9 +183,9 @@ Item {
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
property var drawOpaqueConfig: Render.getConfig("DrawOpaqueDeferred")
|
property var drawOpaqueConfig: mainViewTask.getConfig("DrawOpaqueDeferred")
|
||||||
property var drawTransparentConfig: Render.getConfig("DrawTransparentDeferred")
|
property var drawTransparentConfig: mainViewTask.getConfig("DrawTransparentDeferred")
|
||||||
property var drawLightConfig: Render.getConfig("DrawLight")
|
property var drawLightConfig: mainViewTask.getConfig("DrawLight")
|
||||||
|
|
||||||
PlotPerf {
|
PlotPerf {
|
||||||
title: "Items"
|
title: "Items"
|
||||||
|
@ -199,13 +200,13 @@ Item {
|
||||||
color: "#1AC567"
|
color: "#1AC567"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("DrawTransparentDeferred"),
|
object: mainViewTask.getConfig("DrawTransparentDeferred"),
|
||||||
prop: "numDrawn",
|
prop: "numDrawn",
|
||||||
label: "Translucents",
|
label: "Translucents",
|
||||||
color: "#00B4EF"
|
color: "#00B4EF"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("DrawLight"),
|
object: mainViewTask.getConfig("DrawLight"),
|
||||||
prop: "numDrawn",
|
prop: "numDrawn",
|
||||||
label: "Lights",
|
label: "Lights",
|
||||||
color: "#FED959"
|
color: "#FED959"
|
||||||
|
@ -222,25 +223,25 @@ Item {
|
||||||
valueNumDigits: "2"
|
valueNumDigits: "2"
|
||||||
plots: [
|
plots: [
|
||||||
{
|
{
|
||||||
object: Render.getConfig("DrawOpaqueDeferred"),
|
object: mainViewTask.getConfig("DrawOpaqueDeferred"),
|
||||||
prop: "cpuRunTime",
|
prop: "cpuRunTime",
|
||||||
label: "Opaques",
|
label: "Opaques",
|
||||||
color: "#1AC567"
|
color: "#1AC567"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("DrawTransparentDeferred"),
|
object: mainViewTask.getConfig("DrawTransparentDeferred"),
|
||||||
prop: "cpuRunTime",
|
prop: "cpuRunTime",
|
||||||
label: "Translucents",
|
label: "Translucents",
|
||||||
color: "#00B4EF"
|
color: "#00B4EF"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("RenderDeferred"),
|
object: mainViewTask.getConfig("RenderDeferred"),
|
||||||
prop: "cpuRunTime",
|
prop: "cpuRunTime",
|
||||||
label: "Lighting",
|
label: "Lighting",
|
||||||
color: "#FED959"
|
color: "#FED959"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("RenderDeferredTask"),
|
object: mainViewTask.getConfig("RenderDeferredTask"),
|
||||||
prop: "cpuRunTime",
|
prop: "cpuRunTime",
|
||||||
label: "RenderFrame",
|
label: "RenderFrame",
|
||||||
color: "#E2334D"
|
color: "#E2334D"
|
||||||
|
|
|
@ -21,7 +21,8 @@ Item {
|
||||||
spacing: 8
|
spacing: 8
|
||||||
anchors.fill:parent
|
anchors.fill:parent
|
||||||
|
|
||||||
property var config: Render.getConfig("Stats")
|
property var mainViewTask: Render.getConfig("RenderMainView");
|
||||||
|
property var config: mainViewTask.getConfig("Stats")
|
||||||
|
|
||||||
function evalEvenHeight() {
|
function evalEvenHeight() {
|
||||||
// Why do we have to do that manually ? cannot seem to find a qml / anchor / layout mode that does that ?
|
// Why do we have to do that manually ? cannot seem to find a qml / anchor / layout mode that does that ?
|
||||||
|
@ -38,31 +39,31 @@ Item {
|
||||||
valueNumDigits: "4"
|
valueNumDigits: "4"
|
||||||
plots: [
|
plots: [
|
||||||
{
|
{
|
||||||
object: Render.getConfig("OpaqueRangeTimer"),
|
object: mainViewTask.getConfig("OpaqueRangeTimer"),
|
||||||
prop: "gpuRunTime",
|
prop: "gpuRunTime",
|
||||||
label: "Opaque",
|
label: "Opaque",
|
||||||
color: "#FFFFFF"
|
color: "#FFFFFF"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("LinearDepth"),
|
object: mainViewTask.getConfig("LinearDepth"),
|
||||||
prop: "gpuRunTime",
|
prop: "gpuRunTime",
|
||||||
label: "LinearDepth",
|
label: "LinearDepth",
|
||||||
color: "#00FF00"
|
color: "#00FF00"
|
||||||
},{
|
},{
|
||||||
object: Render.getConfig("SurfaceGeometry"),
|
object: mainViewTask.getConfig("SurfaceGeometry"),
|
||||||
prop: "gpuRunTime",
|
prop: "gpuRunTime",
|
||||||
label: "SurfaceGeometry",
|
label: "SurfaceGeometry",
|
||||||
color: "#00FFFF"
|
color: "#00FFFF"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("RenderDeferred"),
|
object: mainViewTask.getConfig("RenderDeferred"),
|
||||||
prop: "gpuRunTime",
|
prop: "gpuRunTime",
|
||||||
label: "DeferredLighting",
|
label: "DeferredLighting",
|
||||||
color: "#FF00FF"
|
color: "#FF00FF"
|
||||||
}
|
}
|
||||||
,
|
,
|
||||||
{
|
{
|
||||||
object: Render.getConfig("ToneAndPostRangeTimer"),
|
object: mainViewTask.getConfig("ToneAndPostRangeTimer"),
|
||||||
prop: "gpuRunTime",
|
prop: "gpuRunTime",
|
||||||
label: "tone and post",
|
label: "tone and post",
|
||||||
color: "#FF0000"
|
color: "#FF0000"
|
||||||
|
@ -78,31 +79,31 @@ Item {
|
||||||
valueNumDigits: "3"
|
valueNumDigits: "3"
|
||||||
plots: [
|
plots: [
|
||||||
{
|
{
|
||||||
object: Render.getConfig("OpaqueRangeTimer"),
|
object: mainViewTask.getConfig("OpaqueRangeTimer"),
|
||||||
prop: "batchRunTime",
|
prop: "batchRunTime",
|
||||||
label: "Opaque",
|
label: "Opaque",
|
||||||
color: "#FFFFFF"
|
color: "#FFFFFF"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("LinearDepth"),
|
object: mainViewTask.getConfig("LinearDepth"),
|
||||||
prop: "batchRunTime",
|
prop: "batchRunTime",
|
||||||
label: "LinearDepth",
|
label: "LinearDepth",
|
||||||
color: "#00FF00"
|
color: "#00FF00"
|
||||||
},{
|
},{
|
||||||
object: Render.getConfig("SurfaceGeometry"),
|
object: mainViewTask.getConfig("SurfaceGeometry"),
|
||||||
prop: "batchRunTime",
|
prop: "batchRunTime",
|
||||||
label: "SurfaceGeometry",
|
label: "SurfaceGeometry",
|
||||||
color: "#00FFFF"
|
color: "#00FFFF"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
object: Render.getConfig("RenderDeferred"),
|
object: mainViewTask.getConfig("RenderDeferred"),
|
||||||
prop: "batchRunTime",
|
prop: "batchRunTime",
|
||||||
label: "DeferredLighting",
|
label: "DeferredLighting",
|
||||||
color: "#FF00FF"
|
color: "#FF00FF"
|
||||||
}
|
}
|
||||||
,
|
,
|
||||||
{
|
{
|
||||||
object: Render.getConfig("ToneAndPostRangeTimer"),
|
object: mainViewTask.getConfig("ToneAndPostRangeTimer"),
|
||||||
prop: "batchRunTime",
|
prop: "batchRunTime",
|
||||||
label: "tone and post",
|
label: "tone and post",
|
||||||
color: "#FF0000"
|
color: "#FF0000"
|
||||||
|
|
|
@ -16,28 +16,29 @@ Column {
|
||||||
Column {
|
Column {
|
||||||
id: scattering
|
id: scattering
|
||||||
spacing: 10
|
spacing: 10
|
||||||
|
property var mainViewTask: Render.getConfig("RenderMainView");
|
||||||
|
|
||||||
Column{
|
Column{
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Scattering"
|
text: "Scattering"
|
||||||
checked: Render.getConfig("Scattering").enableScattering
|
checked: mainViewTask.getConfig("Scattering").enableScattering
|
||||||
onCheckedChanged: { Render.getConfig("Scattering").enableScattering = checked }
|
onCheckedChanged: { mainViewTask.getConfig("Scattering").enableScattering = checked }
|
||||||
}
|
}
|
||||||
|
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Show Scattering BRDF"
|
text: "Show Scattering BRDF"
|
||||||
checked: Render.getConfig("Scattering").showScatteringBRDF
|
checked: mainViewTask.getConfig("Scattering").showScatteringBRDF
|
||||||
onCheckedChanged: { Render.getConfig("Scattering").showScatteringBRDF = checked }
|
onCheckedChanged: { mainViewTask.getConfig("Scattering").showScatteringBRDF = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Show Curvature"
|
text: "Show Curvature"
|
||||||
checked: Render.getConfig("Scattering").showCurvature
|
checked: mainViewTask.getConfig("Scattering").showCurvature
|
||||||
onCheckedChanged: { Render.getConfig("Scattering").showCurvature = checked }
|
onCheckedChanged: { mainViewTask.getConfig("Scattering").showCurvature = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Show Diffused Normal"
|
text: "Show Diffused Normal"
|
||||||
checked: Render.getConfig("Scattering").showDiffusedNormal
|
checked: mainViewTask.getConfig("Scattering").showDiffusedNormal
|
||||||
onCheckedChanged: { Render.getConfig("Scattering").showDiffusedNormal = checked }
|
onCheckedChanged: { mainViewTask.getConfig("Scattering").showDiffusedNormal = checked }
|
||||||
}
|
}
|
||||||
Repeater {
|
Repeater {
|
||||||
model: [ "Scattering Bent Red:Scattering:bentRed:2.0",
|
model: [ "Scattering Bent Red:Scattering:bentRed:2.0",
|
||||||
|
@ -50,7 +51,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr(modelData.split(":")[0])
|
label: qsTr(modelData.split(":")[0])
|
||||||
integral: false
|
integral: false
|
||||||
config: Render.getConfig(modelData.split(":")[1])
|
config: mainViewTask.getConfig(modelData.split(":")[1])
|
||||||
property: modelData.split(":")[2]
|
property: modelData.split(":")[2]
|
||||||
max: modelData.split(":")[3]
|
max: modelData.split(":")[3]
|
||||||
min: 0.0
|
min: 0.0
|
||||||
|
@ -58,23 +59,23 @@ Column {
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Scattering Profile"
|
text: "Scattering Profile"
|
||||||
checked: Render.getConfig("DebugScattering").showProfile
|
checked: mainViewTask.getConfig("DebugScattering").showProfile
|
||||||
onCheckedChanged: { Render.getConfig("DebugScattering").showProfile = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DebugScattering").showProfile = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Scattering Table"
|
text: "Scattering Table"
|
||||||
checked: Render.getConfig("DebugScattering").showLUT
|
checked: mainViewTask.getConfig("DebugScattering").showLUT
|
||||||
onCheckedChanged: { Render.getConfig("DebugScattering").showLUT = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DebugScattering").showLUT = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Cursor Pixel"
|
text: "Cursor Pixel"
|
||||||
checked: Render.getConfig("DebugScattering").showCursorPixel
|
checked: mainViewTask.getConfig("DebugScattering").showCursorPixel
|
||||||
onCheckedChanged: { Render.getConfig("DebugScattering").showCursorPixel = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DebugScattering").showCursorPixel = checked }
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Skin Specular Beckmann"
|
text: "Skin Specular Beckmann"
|
||||||
checked: Render.getConfig("DebugScattering").showSpecularTable
|
checked: mainViewTask.getConfig("DebugScattering").showSpecularTable
|
||||||
onCheckedChanged: { Render.getConfig("DebugScattering").showSpecularTable = checked }
|
onCheckedChanged: { mainViewTask.getConfig("DebugScattering").showSpecularTable = checked }
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,12 +16,13 @@ Column {
|
||||||
Column {
|
Column {
|
||||||
id: surfaceGeometry
|
id: surfaceGeometry
|
||||||
spacing: 10
|
spacing: 10
|
||||||
|
property var mainViewTask: Render.getConfig("RenderMainView");
|
||||||
|
|
||||||
Column{
|
Column{
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr("Depth Threshold [cm]")
|
label: qsTr("Depth Threshold [cm]")
|
||||||
integral: false
|
integral: false
|
||||||
config: Render.getConfig("SurfaceGeometry")
|
config: mainViewTask.getConfig("SurfaceGeometry")
|
||||||
property: "depthThreshold"
|
property: "depthThreshold"
|
||||||
max: 5.0
|
max: 5.0
|
||||||
min: 0.0
|
min: 0.0
|
||||||
|
@ -34,7 +35,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr(modelData.split(":")[0])
|
label: qsTr(modelData.split(":")[0])
|
||||||
integral: (modelData.split(":")[3] == 'true')
|
integral: (modelData.split(":")[3] == 'true')
|
||||||
config: Render.getConfig("SurfaceGeometry")
|
config: mainViewTask.getConfig("SurfaceGeometry")
|
||||||
property: modelData.split(":")[1]
|
property: modelData.split(":")[1]
|
||||||
max: modelData.split(":")[2]
|
max: modelData.split(":")[2]
|
||||||
min: 0.0
|
min: 0.0
|
||||||
|
@ -42,8 +43,8 @@ Column {
|
||||||
}
|
}
|
||||||
CheckBox {
|
CheckBox {
|
||||||
text: "Half Resolution"
|
text: "Half Resolution"
|
||||||
checked: Render.getConfig("SurfaceGeometry")["resolutionLevel"]
|
checked: mainViewTask.getConfig("SurfaceGeometry")["resolutionLevel"]
|
||||||
onCheckedChanged: { Render.getConfig("SurfaceGeometry")["resolutionLevel"] = checked }
|
onCheckedChanged: { mainViewTask.getConfig("SurfaceGeometry")["resolutionLevel"] = checked }
|
||||||
}
|
}
|
||||||
|
|
||||||
Repeater {
|
Repeater {
|
||||||
|
@ -53,7 +54,7 @@ Column {
|
||||||
ConfigSlider {
|
ConfigSlider {
|
||||||
label: qsTr(modelData.split(":")[0])
|
label: qsTr(modelData.split(":")[0])
|
||||||
integral: false
|
integral: false
|
||||||
config: Render.getConfig(modelData.split(":")[1])
|
config: mainViewTask.getConfig(modelData.split(":")[1])
|
||||||
property: modelData.split(":")[2]
|
property: modelData.split(":")[2]
|
||||||
max: modelData.split(":")[3]
|
max: modelData.split(":")[3]
|
||||||
min: 0.0
|
min: 0.0
|
||||||
|
|
|
@ -22,7 +22,8 @@ Item {
|
||||||
spacing: 8
|
spacing: 8
|
||||||
anchors.fill:parent
|
anchors.fill:parent
|
||||||
|
|
||||||
property var config: Render.getConfig("Stats")
|
property var mainViewTask: Render.getConfig("RenderMainView");
|
||||||
|
property var config: mainViewTask.getConfig("Stats")
|
||||||
|
|
||||||
function evalEvenHeight() {
|
function evalEvenHeight() {
|
||||||
// Why do we have to do that manually ? cannot seem to find a qml / anchor / layout mode that does that ?
|
// Why do we have to do that manually ? cannot seem to find a qml / anchor / layout mode that does that ?
|
||||||
|
|
Loading…
Reference in a new issue