From 21104baa536c6b3d3d0f9ecb7231222ed706f0e8 Mon Sep 17 00:00:00 2001 From: Normand Briere <nbriere@noware.ca> Date: Tue, 25 Jun 2019 18:27:08 -0400 Subject: [PATCH] Fix camera values --- CameraPane.java | 34 ++++++++++++++++++++++++++++++++-- 1 files changed, 32 insertions(+), 2 deletions(-) diff --git a/CameraPane.java b/CameraPane.java index 3697e29..1175edb 100644 --- a/CameraPane.java +++ b/CameraPane.java @@ -9366,11 +9366,35 @@ jy8[3] = 0.5f; } - float[] options1 = new float[]{1000, 0.00001f, 20, 0, 0}; // focus, aperture, Shadow blur, aniso, anisoV + float[] options1 = new float[]{100, 0.00001f, 20, 0, 0}; // focus, aperture, Shadow blur, aniso, anisoV float[] options2 = new float[]{0, 1, 0, 0}; // fog density, intensity, elevation float[] options3 = new float[]{1, 1, 1, 0}; // fog color float[] options4 = new float[]{1, 0, 1, 0}; // image intensity, subsurface, lightsheen + void ResetOptions() + { + options1[0] = 100; + options1[1] = 0.00001f; + options1[2] = 20; + options1[3] = 0; + options1[4] = 0; + + options2[0] = 0; + options2[1] = 1; + options2[2] = 0; + options2[3] = 0; + + options3[0] = 1; + options3[1] = 1; + options3[2] = 1; + options3[3] = 0; + + options4[0] = 1; + options4[1] = 0; + options4[2] = 1; + options4[3] = 0; + } + static int imagecount = 0; // movie generation static int jitter = 0; @@ -10481,6 +10505,7 @@ ANTIALIAS = 0; //System.out.println("RESTART"); AAtimer.restart(); + Globals.TIMERRUNNING = true; } } } @@ -11479,6 +11504,9 @@ void DrawObject(GL gl, boolean draw) { + // To clear camera values + ResetOptions(); + //System.out.println("DRAW OBJECT " + mouseDown); // DrawMode() = SELECTION; //GL gl = getGL(); @@ -12046,7 +12074,7 @@ for (int i = tp.size(); --i >= 0;) { //for (int count = tp.get(i).GetTransformCount(); --count>=0;) - LA.xformPos(light, tp.get(i).GlobalTransform(), light); + LA.xformPos(light, tp.get(i).GlobalTransformInv(), light); } @@ -13840,6 +13868,7 @@ else if (evt.getSource() == AAtimer) { + Globals.TIMERRUNNING = false; if (mouseDown) { //new Exception().printStackTrace(); @@ -13914,6 +13943,7 @@ return; AAtimer.restart(); // + Globals.TIMERRUNNING = true; // waslive = LIVE; // LIVE = false; -- Gitblit v1.6.2