Add a profiler section for debug wireframe rendering
This commit is contained in:
@@ -329,8 +329,6 @@ public class DebugRenderer
|
||||
|
||||
public void render(Mat4f transform)
|
||||
{
|
||||
if (!Config.Client.Advanced.Debugging.debugWireframeRendering.get()) return;
|
||||
|
||||
transform_this_frame = transform;
|
||||
Vec3d cam = MC_RENDER.getCameraExactPosition();
|
||||
camf = new Vec3f((float) cam.x, (float) cam.y, (float) cam.z);
|
||||
|
||||
@@ -301,7 +301,15 @@ public class LodRenderer
|
||||
GL32.glBindBuffer(GL32.GL_ARRAY_BUFFER, 0);
|
||||
|
||||
this.shaderProgram.unbind();
|
||||
DebugRenderer.INSTANCE.render(modelViewProjectionMatrix);
|
||||
|
||||
if (Config.Client.Advanced.Debugging.debugWireframeRendering.get())
|
||||
{
|
||||
profiler.popPush("Debug wireframes");
|
||||
// Note: this can be very slow if a lot of boxes are being rendered
|
||||
DebugRenderer.INSTANCE.render(modelViewProjectionMatrix);
|
||||
profiler.popPush("LOD cleanup");
|
||||
}
|
||||
|
||||
GL32.glClear(GL32.GL_DEPTH_BUFFER_BIT);
|
||||
|
||||
minecraftGlState.restore();
|
||||
|
||||
Reference in New Issue
Block a user