Add debug wireframe toggle for render section rendering toggle
This commit is contained in:
@@ -962,6 +962,15 @@ public class Config
|
||||
.set(false)
|
||||
.comment("Render LOD section status?")
|
||||
.build();
|
||||
public static ConfigEntry<Boolean> showRenderSectionToggling = new ConfigEntry.Builder<Boolean>()
|
||||
.set(false)
|
||||
.comment("" +
|
||||
"A white box will be drawn when an LOD starts rendering \n" +
|
||||
"and a purple box when an LOD stops rendering. \n" +
|
||||
"\n" +
|
||||
"This can be used to debug Quad Tree holes.\n" +
|
||||
"")
|
||||
.build();
|
||||
|
||||
public static ConfigEntry<Boolean> showQuadTreeRenderStatus = new ConfigEntry.Builder<Boolean>()
|
||||
.set(false)
|
||||
|
||||
@@ -315,7 +315,10 @@ public class LodQuadTree extends QuadTree<LodRenderSection> implements IDebugRen
|
||||
}
|
||||
|
||||
// this position's rendering has been disabled due to children being rendered
|
||||
DebugRenderer.makeParticle(new DebugRenderer.BoxParticle(new DebugRenderer.Box(renderSection.pos, 128f, 156f, 0.09f, Color.WHITE), 0.2, 32f));
|
||||
if (Config.Client.Advanced.Debugging.DebugWireframe.showRenderSectionToggling.get())
|
||||
{
|
||||
DebugRenderer.makeParticle(new DebugRenderer.BoxParticle(new DebugRenderer.Box(renderSection.pos, 128f, 156f, 0.09f, Color.WHITE), 0.2, 32f));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -389,7 +392,10 @@ public class LodQuadTree extends QuadTree<LodRenderSection> implements IDebugRen
|
||||
if (childRenderSection.getRenderingEnabled())
|
||||
{
|
||||
// this position's rendering has been disabled due to a parent rendering
|
||||
DebugRenderer.makeParticle(new DebugRenderer.BoxParticle(new DebugRenderer.Box(childRenderSection.pos, 128f, 156f, 0.09f, Color.MAGENTA),0.2, 32f));
|
||||
if (Config.Client.Advanced.Debugging.DebugWireframe.showRenderSectionToggling.get())
|
||||
{
|
||||
DebugRenderer.makeParticle(new DebugRenderer.BoxParticle(new DebugRenderer.Box(childRenderSection.pos, 128f, 156f, 0.09f, Color.MAGENTA), 0.2, 32f));
|
||||
}
|
||||
}
|
||||
|
||||
childRenderSection.setRenderingEnabled(false);
|
||||
|
||||
@@ -452,6 +452,8 @@
|
||||
"Show World Gen Queue",
|
||||
"distanthorizons.config.client.advanced.debugging.debugWireframe.showRenderSectionStatus":
|
||||
"Show Render Section Status",
|
||||
"distanthorizons.config.client.advanced.debugging.debugWireframe.showRenderSectionToggling":
|
||||
"Show Render Section Toggling",
|
||||
"distanthorizons.config.client.advanced.debugging.debugWireframe.showQuadTreeRenderStatus":
|
||||
"Show Quad Tree Render Status",
|
||||
"distanthorizons.config.client.advanced.debugging.debugWireframe.showFullDataUpdateStatus":
|
||||
|
||||
Reference in New Issue
Block a user