Normand Briere
2019-06-03 e24558ddeacfc945b9e9ba0a32b552d04e2ed4dd
CameraPane.java
....@@ -56,8 +56,6 @@
5656 static int CURRENTANTIALIAS = 0; // 1;
5757 /*static*/ boolean RENDERSHADOW = true;
5858 /*static*/ int RENDERPROGRAM = 2; // 0 == none, 1 == fast, 2 == normal
59
- static boolean ANIMATION = false;
60
- static String filename;
6159
6260 boolean DISPLAYTEXT = false;
6361 //boolean REDUCETEXTURE = true;
....@@ -86,7 +84,7 @@
8684 static boolean FULLSCREEN = false;
8785 static boolean SUPPORT = true;
8886 static boolean INERTIA = true;
89
-static boolean FAST = true; // false;
87
+static boolean FAST = false;
9088 static boolean SLOWPOSE = false;
9189 static boolean FOOTCONTACT = true;
9290
....@@ -108,7 +106,7 @@
108106 static boolean OEIL = true;
109107 static boolean OEILONCE = false; // do oeilon then oeiloff
110108 static boolean LOOKAT = true;
111
-static boolean RANDOM = true; // false;
109
+static boolean SWITCH = true; // false;
112110 static boolean HANDLES = false; // selection doesn't work!!
113111 static boolean PAINTMODE = false;
114112
....@@ -1630,7 +1628,7 @@
16301628
16311629 cColor.HSBtoRGB(display.color, display.saturation, 1, display.modelParams0);
16321630
1633
- float[] colorV = GrafreeD.colorV;
1631
+ float[] colorV = Grafreed.colorV;
16341632
16351633 /**/
16361634 if (display.DrawMode() == display.DEFAULT) // && display.RENDERPROGRAM == 0)
....@@ -2142,7 +2140,7 @@
21422140 System.err.println("LIVE = " + Globals.isLIVE());
21432141
21442142 if (!Globals.isLIVE()) // save sound
2145
- GrafreeD.savesound = true; // wav.save();
2143
+ Grafreed.savesound = true; // wav.save();
21462144 // else
21472145 repaint(); // start loop // may 2013
21482146 }
....@@ -2269,7 +2267,7 @@
22692267
22702268 void ToggleRandom()
22712269 {
2272
- RANDOM ^= true;
2270
+ SWITCH ^= true;
22732271 }
22742272
22752273 void ToggleHandles()
....@@ -4208,6 +4206,7 @@
42084206
42094207 com.sun.opengl.util.texture.Texture CompressTexture2(String name)
42104208 {
4209
+ new Exception().printStackTrace();
42114210 System.exit(0);
42124211 com.sun.opengl.util.texture.Texture texture = null;
42134212
....@@ -8023,7 +8022,7 @@
80238022 }
80248023 }
80258024
8026
- /*boolean*/ public void BindTextures(cTexture tex, int resolution) // INTERFACE
8025
+ /*boolean*/ public void BindTextures(cTexture tex, int resolution) throws Exception // INTERFACE
80278026 {
80288027 if (// DrawMode() != 0 || /*tex == null ||*/
80298028 ambientOcclusion ) // || !textureon)
....@@ -8068,7 +8067,7 @@
80688067 return; // true;
80698068 }
80708069
8071
- CacheTexture GetCacheTexture(String tex, boolean bump, int resolution)
8070
+ CacheTexture GetCacheTexture(String tex, boolean bump, int resolution) throws Exception
80728071 {
80738072 CacheTexture/*com.sun.opengl.util.texture.Texture*/ texture = null;
80748073
....@@ -8076,12 +8075,16 @@
80768075 {
80778076 String texname = tex;
80788077
8079
- String[] split = tex.split("Textures");
8080
- if (split.length > 1)
8081
- texname = "/Users/nbriere/Textures" + split[split.length-1];
8082
- else
8083
- if (!texname.startsWith("/"))
8084
- texname = "/Users/nbriere/Textures/" + texname;
8078
+// String[] split = tex.split("Textures");
8079
+// if (split.length > 1)
8080
+// texname = "/Users/nbriere/Textures" + split[split.length-1];
8081
+// else
8082
+// if (!texname.startsWith("/"))
8083
+// texname = "/Users/nbriere/Textures/" + texname;
8084
+ if (!new File(tex).exists())
8085
+ {
8086
+ texname = javax.swing.filechooser.FileSystemView.getFileSystemView().getDefaultDirectory() + "/Textures/" + texname;
8087
+ }
80858088
80868089 if (CACHETEXTURE)
80878090 texture = textures.get(texname); // TEXTURE CACHE
....@@ -8181,7 +8184,9 @@
81818184 texturedata = GetFileTexture(cachename, processbump, resolution);
81828185
81838186
8184
- if (texturedata != null)
8187
+ if (texturedata == null)
8188
+ throw new Exception();
8189
+
81858190 texture = new CacheTexture(com.sun.opengl.util.texture.TextureIO.newTexture(texturedata),resolution);
81868191 //texture = GetTexture(tex, bump);
81878192 }
....@@ -8303,7 +8308,7 @@
83038308 return texture;
83048309 }
83058310
8306
- com.sun.opengl.util.texture.Texture GetTexture(String tex, boolean bump, int resolution)
8311
+ com.sun.opengl.util.texture.Texture GetTexture(String tex, boolean bump, int resolution) throws Exception
83078312 {
83088313 CacheTexture texture = GetCacheTexture(tex, bump, resolution);
83098314
....@@ -8321,14 +8326,14 @@
83218326 return texture!=null?texture.texture:null;
83228327 }
83238328
8324
- public com.sun.opengl.util.texture.TextureData GetTextureData(String tex, boolean bump, int resolution)
8329
+ public com.sun.opengl.util.texture.TextureData GetTextureData(String tex, boolean bump, int resolution) throws Exception
83258330 {
83268331 CacheTexture texture = GetCacheTexture(tex, bump, resolution);
83278332
83288333 return texture!=null?texture.texturedata:null;
83298334 }
83308335
8331
- boolean BindTexture(String tex, boolean bump, int resolution)
8336
+ boolean BindTexture(String tex, boolean bump, int resolution) throws Exception
83328337 {
83338338 if (/*tex == null ||*/ ambientOcclusion ) // || !textureon)
83348339 {
....@@ -9394,7 +9399,7 @@
93949399 //gl.glFlush();
93959400 gl.glAccum(gl.GL_ACCUM, 1.0f / ACSIZE);
93969401
9397
- if (ANIMATION && ABORTED)
9402
+ if (Globals.ANIMATION && ABORTED)
93989403 {
93999404 System.err.println(" ABORTED FRAME");
94009405 break;
....@@ -9424,7 +9429,7 @@
94249429 setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
94259430
94269431 // save image
9427
- if (ANIMATION && !ABORTED)
9432
+ if (Globals.ANIMATION && !ABORTED)
94289433 {
94299434 VPwidth = viewport[2];
94309435 VPheight = viewport[3];
....@@ -9535,11 +9540,11 @@
95359540
95369541 // imagecount++;
95379542
9538
- String fullname = filename + (i%100000)/10000 + "" + (i%10000)/1000 + "" + (i%1000)/100 + "" + (i%100)/10 + "" + (i%10) + "." + ext;
9543
+ String fullname = Globals.filename + (i%100000)/10000 + "" + (i%10000)/1000 + "" + (i%1000)/100 + "" + (i%100)/10 + "" + (i%10) + "." + ext;
95399544
95409545 if (!BOXMODE)
95419546 {
9542
- System.out.println("image: " + fullname + " (wav cursor=" + (GrafreeD.wav.cursor / 735 / 4) + ")");
9547
+ System.out.println("image: " + fullname + " (wav cursor=" + (Grafreed.wav.cursor / 735 / 4) + ")");
95439548 }
95449549
95459550 if (!BOXMODE)
....@@ -9577,7 +9582,7 @@
95779582 ABORTED = false;
95789583 }
95799584 else
9580
- GrafreeD.wav.cursor += 735 * ACSIZE;
9585
+ Grafreed.wav.cursor += 735 * ACSIZE;
95819586
95829587 if (false)
95839588 {
....@@ -10240,11 +10245,11 @@
1024010245
1024110246 public void display(GLAutoDrawable drawable)
1024210247 {
10243
- if (GrafreeD.savesound && GrafreeD.hassound)
10248
+ if (Grafreed.savesound && Grafreed.hassound)
1024410249 {
10245
- GrafreeD.wav.save();
10246
- GrafreeD.savesound = false;
10247
- GrafreeD.hassound = false;
10250
+ Grafreed.wav.save();
10251
+ Grafreed.savesound = false;
10252
+ Grafreed.hassound = false;
1024810253 }
1024910254 // if (DEBUG_SELECTION)
1025010255 // {
....@@ -10374,7 +10379,7 @@
1037410379 Object3D theobject = object;
1037510380 Object3D theparent = object.parent;
1037610381 object.parent = null;
10377
- object = (Object3D)GrafreeD.clone(object);
10382
+ object = (Object3D)Grafreed.clone(object);
1037810383 object.Stripify();
1037910384 if (theobject.selection == null || theobject.selection.Size() == 0)
1038010385 theobject.PreprocessOcclusion(this);
....@@ -10795,7 +10800,16 @@
1079510800 // Bump noise
1079610801 gl.glActiveTexture(GL.GL_TEXTURE6);
1079710802 //gl.glBindTexture(GL.GL_TEXTURE_2D, bump_noise);
10798
- BindTexture(NOISE_TEXTURE, false, 2);
10803
+
10804
+ try
10805
+ {
10806
+ BindTexture(NOISE_TEXTURE, false, 2);
10807
+ }
10808
+ catch (Exception e)
10809
+ {
10810
+ System.err.println("FAILED: " + NOISE_TEXTURE);
10811
+ }
10812
+
1079910813
1080010814 gl.glActiveTexture(GL.GL_TEXTURE0);
1080110815 gl.glEnable(GL.GL_TEXTURE_2D);
....@@ -11259,8 +11273,14 @@
1125911273 {
1126011274 renderpass++;
1126111275 // System.out.println("Draw object... ");
11276
+ STEP = 1;
1126211277 if (FAST) // in case there is no script
11263
- STEP = 16;
11278
+ STEP = 8;
11279
+
11280
+ if (CURRENTANTIALIAS == 0 || ACSIZE == 1)
11281
+ {
11282
+ STEP *= 4;
11283
+ }
1126411284
1126511285 //object.FullInvariants();
1126611286
....@@ -11274,8 +11294,8 @@
1127411294 e.printStackTrace();
1127511295 }
1127611296
11277
- if (GrafreeD.RENDERME > 0)
11278
- GrafreeD.RENDERME--; // mechante magouille
11297
+ if (Grafreed.RENDERME > 0)
11298
+ Grafreed.RENDERME--; // mechante magouille
1127911299
1128011300 Globals.ONESTEP = false;
1128111301 }
....@@ -11345,7 +11365,14 @@
1134511365
1134611366 usedtextures.clear();
1134711367
11348
- BindTextures(DEFAULT_TEXTURES, 2);
11368
+ try
11369
+ {
11370
+ BindTextures(DEFAULT_TEXTURES, 2);
11371
+ }
11372
+ catch (Exception e)
11373
+ {
11374
+ System.err.println("FAILED: " + DEFAULT_TEXTURES);
11375
+ }
1134911376 }
1135011377 //System.out.println("--> " + stackdepth);
1135111378 // GrafreeD.traceon();
....@@ -11436,7 +11463,14 @@
1143611463 if (checker != null && DrawMode() == DEFAULT)
1143711464 {
1143811465 //BindTexture(IMMORTAL_TEXTURE);
11439
- BindTextures(checker.GetTextures(), checker.texres);
11466
+ try
11467
+ {
11468
+ BindTextures(checker.GetTextures(), checker.texres);
11469
+ }
11470
+ catch (Exception e)
11471
+ {
11472
+ System.err.println("FAILED: " + checker.GetTextures());
11473
+ }
1144011474 // NEAREST
1144111475 GetGL().glTexParameteri(GL.GL_TEXTURE_2D, GL.GL_TEXTURE_MAG_FILTER, GL.GL_NEAREST); // GL.GL_LINEAR);
1144211476 DrawChecker(gl);
....@@ -12598,8 +12632,10 @@
1259812632 "MAX ndotl.x, ndotl.x, -ndotl.x;" +
1259912633
1260012634 "SUB temp.x, one.x, ndotl.x;" +
12601
- "ADD temp.x, temp.x, options2.z;" + // lightsheen
12602
- "ADD temp.y, one.y, options2.y;" + // sursurface
12635
+ // Tuning for default skin
12636
+ //"ADD temp.x, temp.x, options2.z;" + // lightsheen
12637
+ "MAD temp.x, options2.z, half.y, temp.x;" + // lightsheen
12638
+ "ADD temp.y, one.y, options2.y;" + // subsurface
1260312639 "MUL temp.x, temp.x, temp.y;" +
1260412640
1260512641 "MUL saturation, saturation, temp.xxxx;" +
....@@ -12747,7 +12783,7 @@
1274712783 "MUL final.y, fragment.texcoord[0].x, c256;" +
1274812784 "FLR final.x, final.y;" +
1274912785 "SUB final.y, final.y, final.x;" +
12750
- //"MUL final.x, final.x, c256i;" +
12786
+ "MUL final.x, final.x, c256i;" +
1275112787 "MOV final.z, zero.x;" +
1275212788 "MOV final.a, one.w;":""
1275312789 ) +
....@@ -12755,7 +12791,7 @@
1275512791 "MUL final.y, fragment.texcoord[0].y, c256;" +
1275612792 "FLR final.x, final.y;" +
1275712793 "SUB final.y, final.y, final.x;" +
12758
- //"MUL final.x, final.x, c256i;" +
12794
+ "MUL final.x, final.x, c256i;" +
1275912795 "MOV final.z, zero.x;" +
1276012796 "MOV final.a, one.w;":""
1276112797 ) +
....@@ -13508,7 +13544,7 @@
1350813544 public void mousePressed(MouseEvent e)
1350913545 {
1351013546 //System.out.println("mousePressed: " + e);
13511
- clickStart(e.getX(), e.getY(), e.getModifiersEx());
13547
+ clickStart(e.getX(), e.getY(), e.getModifiers(), e.getModifiersEx());
1351213548 }
1351313549
1351413550 static long prevtime = 0;
....@@ -13584,8 +13620,8 @@
1358413620 // mode |= META;
1358513621 //}
1358613622
13587
- SetMouseMode(WHEEL | e.getModifiersEx());
13588
- drag(anchorX, anchorY + e.getUnitsToScroll()*8, 0);
13623
+ SetMouseMode(e.getModifiers(), WHEEL | e.getModifiersEx());
13624
+ drag(anchorX, anchorY + e.getUnitsToScroll()*8, 0, 0);
1358913625 anchorX = ax;
1359013626 anchorY = ay;
1359113627 prevX = px;
....@@ -13645,6 +13681,10 @@
1364513681 // wasliveok = true;
1364613682 // waslive = false;
1364713683
13684
+ // May 2019 Forget it:
13685
+ if (true)
13686
+ return;
13687
+
1364813688 // source == timer
1364913689 if (mouseDown)
1365013690 {
....@@ -13683,7 +13723,7 @@
1368313723
1368413724 javax.swing.Timer timer = new javax.swing.Timer(350, this);
1368513725
13686
- void clickStart(int x, int y, int modifiers)
13726
+ void clickStart(int x, int y, int modifiers, int modifiersex)
1368713727 {
1368813728 if (!wasliveok)
1368913729 return;
....@@ -13700,7 +13740,7 @@
1370013740 // touched = true; // main DL
1370113741 if (isRenderer)
1370213742 {
13703
- SetMouseMode(modifiers);
13743
+ SetMouseMode(modifiers, modifiersex);
1370413744 }
1370513745
1370613746 selectX = anchorX = x;
....@@ -13713,7 +13753,7 @@
1371313753 clicked = true;
1371413754 hold = false;
1371513755
13716
- if (((modifiers & ~1024) & ~0) == 0) // Single or multiple selection
13756
+ if (((modifiersex & ~1024) & ~0) == 0) // Single or multiple selection
1371713757 // june 2013 means CTRL_CLICK: if (((modifiers & ~1024) & ~128) == 0) // Single or multiple selection
1371813758 {
1371913759 // System.out.println("RESTART II " + modifiers);
....@@ -13744,7 +13784,7 @@
1374413784 info.camera = renderCamera;
1374513785 info.x = x;
1374613786 info.y = y;
13747
- info.modifiers = modifiers;
13787
+ info.modifiers = modifiersex;
1374813788 editObj = object.doEditClick(info, 0);
1374913789 if (!editObj)
1375013790 {
....@@ -13773,7 +13813,7 @@
1377313813 clickEnd(e.getX(), e.getY(), e.getModifiersEx());
1377413814 }
1377513815 else
13776
- drag(e.getX(), e.getY(), e.getModifiersEx());
13816
+ drag(e.getX(), e.getY(), e.getModifiers(), e.getModifiersEx());
1377713817
1377813818 //try { Thread.sleep(1); } catch (Exception ex) {}
1377913819 }
....@@ -13946,6 +13986,7 @@
1394613986
1394713987 public void run()
1394813988 {
13989
+ new Exception().printStackTrace();
1394913990 System.exit(0);
1395013991 for (;;)
1395113992 {
....@@ -14009,7 +14050,7 @@
1400914050 {
1401014051 Globals.lighttouched = true;
1401114052 }
14012
- drag(X, (mouseMode != 0) ? Y : anchorY, MODIFIERS);
14053
+ drag(X, (mouseMode != 0) ? Y : anchorY, 0, MODIFIERS);
1401314054 }
1401414055 //else
1401514056 }
....@@ -14109,7 +14150,7 @@
1410914150 int X, Y;
1411014151 boolean SX, SY;
1411114152
14112
- void drag(int x, int y, int modifiers)
14153
+ void drag(int x, int y, int modifiers, int modifiersex)
1411314154 {
1411414155 if (IsFrozen())
1411514156 {
....@@ -14118,17 +14159,17 @@
1411814159
1411914160 drag = true; // NEW
1412014161
14121
- boolean continuous = (modifiers & COMMAND) == COMMAND;
14162
+ boolean continuous = (modifiersex & COMMAND) == COMMAND;
1412214163
1412314164 X = x;
1412414165 Y = y;
1412514166 // floating state for animation
14126
- MODIFIERS = modifiers;
14127
- modifiers &= ~1024;
14167
+ MODIFIERS = modifiersex;
14168
+ modifiersex &= ~1024;
1412814169 if (false) // modifiers != 0)
1412914170 {
1413014171 //new Exception().printStackTrace();
14131
- System.out.println("mouseDragged: " + modifiers);
14172
+ System.out.println("mouseDragged: " + modifiersex);
1413214173 System.out.println("SHIFT = " + SHIFT);
1413314174 System.out.println("CONTROL = " + COMMAND);
1413414175 System.out.println("META = " + META);
....@@ -14148,7 +14189,7 @@
1414814189 info.camera = renderCamera;
1414914190 info.x = x;
1415014191 info.y = y;
14151
- object.editWindow.copy.doEditDrag(info);
14192
+ object.editWindow.copy.doEditDrag(info, (modifiers & MouseEvent.BUTTON3_MASK) != 0);
1415214193 } else
1415314194 {
1415414195 if (x < startX)
....@@ -14347,9 +14388,9 @@
1434714388 boolean control = ((modifiers & CTRL) != 0); // june 2013: for point selection
1434814389 boolean command = ((modifiers & COMMAND) != 0); // june 2013: for multiple selection
1434914390
14350
- if (control || command || IsFrozen())
14391
+// No delay if (control || command || IsFrozen())
1435114392 timeout = true;
14352
- else
14393
+// ?? May 2019 else
1435314394 // timer.setDelay((modifiers & 128) != 0?0:350);
1435414395 mouseDown = false;
1435514396 if (!control && !command) // june 2013
....@@ -14459,7 +14500,7 @@
1445914500 System.out.println("keyReleased: " + e);
1446014501 }
1446114502
14462
- void SetMouseMode(int modifiers)
14503
+ void SetMouseMode(int modifiers, int modifiersex)
1446314504 {
1446414505 //System.out.println("SetMouseMode = " + modifiers);
1446514506 //modifiers &= ~1024;
....@@ -14471,25 +14512,25 @@
1447114512 //if (modifiers == 0) // || (modifiers == (1024 | CONTROL)))
1447214513 // return;
1447314514 //System.out.println("SetMode = " + modifiers);
14474
- if ((modifiers & WHEEL) == WHEEL)
14515
+ if ((modifiersex & WHEEL) == WHEEL)
1447514516 {
1447614517 mouseMode |= ZOOM;
1447714518 }
1447814519
1447914520 boolean capsLocked = Toolkit.getDefaultToolkit().getLockingKeyState(KeyEvent.VK_CAPS_LOCK);
14480
- if (capsLocked || (modifiers & META) == META)
14521
+ if (capsLocked) // || (modifiers & META) == META)
1448114522 {
1448214523 mouseMode |= VR; // BACKFORTH;
1448314524 }
14484
- if ((modifiers & CTRLCLICK) == CTRLCLICK)
14525
+ if ((modifiersex & CTRLCLICK) == CTRLCLICK)
1448514526 {
1448614527 mouseMode |= SELECT;
1448714528 }
14488
- if ((modifiers & COMMAND) == COMMAND)
14529
+ if ((modifiersex & COMMAND) == COMMAND)
1448914530 {
1449014531 mouseMode |= SELECT;
1449114532 }
14492
- if ((modifiers & SHIFT) == SHIFT || forcetranslate)
14533
+ if ((modifiersex & SHIFT) == SHIFT || forcetranslate || (modifiers & MouseEvent.BUTTON3_MASK) != 0)
1449314534 {
1449414535 mouseMode &= ~VR;
1449514536 mouseMode |= TRANSLATE;
....@@ -14518,7 +14559,7 @@
1451814559
1451914560 if (isRenderer) //
1452014561 {
14521
- SetMouseMode(modifiers);
14562
+ SetMouseMode(0, modifiers);
1452214563 }
1452314564
1452414565 Globals.theRenderer.keyPressed(key);
....@@ -14854,7 +14895,7 @@
1485414895 //RESIZETEXTURE ^= true;
1485514896 //break;
1485614897 case 'z':
14857
- RENDERSHADOW ^= true;
14898
+ Globals.RENDERSHADOW ^= true;
1485814899 Globals.lighttouched = true;
1485914900 repaint();
1486014901 break;
....@@ -14978,7 +15019,7 @@
1497815019 //mode = ROTATE;
1497915020 if ((MODIFIERS & COMMAND) == 0) // VR??
1498015021 {
14981
- SetMouseMode(modifiers);
15022
+ SetMouseMode(0, modifiers);
1498215023 }
1498315024 }
1498415025
....@@ -15114,7 +15155,7 @@
1511415155 {
1511515156 //System.out.println("processMouseMotionEvent: " + mouseMode + " " + e.getModifiers() + " " + e.getModifiersEx() + " " + e.getButton());
1511615157 //if (e.getButton() == MouseEvent.NOBUTTON && (mouseMode & SELECT) == 0)
15117
- if ((e.getModifiers() & MouseEvent.BUTTON1_MASK) == 0 && (mouseMode & SELECT) == 0)
15158
+ if ((e.getModifiers() & MouseEvent.BUTTON1_MASK) == 0 && (e.getModifiers() & MouseEvent.BUTTON3_MASK) == 0 && (mouseMode & SELECT) == 0)
1511815159 {
1511915160 mouseMoved(e);
1512015161 } else
....@@ -15144,6 +15185,7 @@
1514415185
1514515186 void SelectParent()
1514615187 {
15188
+ new Exception().printStackTrace();
1514715189 System.exit(0);
1514815190 Composite group = (Composite) object;
1514915191 java.util.Vector selectees = new java.util.Vector(group.selection);
....@@ -15167,6 +15209,7 @@
1516715209
1516815210 void SelectChildren()
1516915211 {
15212
+ new Exception().printStackTrace();
1517015213 System.exit(0);
1517115214 /*
1517215215 Composite group = (Composite) object;
....@@ -15549,6 +15592,7 @@
1554915592 public boolean mouseDown(Event evt, int x, int y)
1555015593 {
1555115594 System.out.println("mouseDown: " + evt);
15595
+ System.exit(0);
1555215596 /*
1555315597 locked = true;
1555415598 drag = false;
....@@ -15592,7 +15636,7 @@
1559215636 {
1559315637 keyPressed(0, modifiers);
1559415638 }
15595
- clickStart(x, y, modifiers);
15639
+ // clickStart(x, y, modifiers);
1559615640 return true;
1559715641 }
1559815642
....@@ -15710,7 +15754,7 @@
1571015754 {
1571115755 keyReleased(0, 0);
1571215756 }
15713
- drag(x, y, modifiers);
15757
+ drag(x, y, 0, modifiers);
1571415758 return true;
1571515759 }
1571615760
....@@ -16280,6 +16324,7 @@
1628016324 {
1628116325 if (!selection)
1628216326 {
16327
+ new Exception().printStackTrace();
1628316328 System.exit(0);
1628416329 return;
1628516330 }
....@@ -16407,16 +16452,16 @@
1640716452 System.out.println("; fromto " + sel + " " + Trunk(previousselectedpoint.toParent[3][0]) + " " + Trunk(previousselectedpoint.toParent[3][2]) + " " + Trunk(selectedpoint.toParent[3][0]) + " " + Trunk(selectedpoint.toParent[3][2]));
1640816453 }
1640916454
16410
- previousselectedpoint = (Sphere) GrafreeD.clone(selectedpoint);
16455
+ previousselectedpoint = (Sphere) Grafreed.clone(selectedpoint);
1641116456 }
1641216457 }
1641316458
1641416459 if (!movingcamera && !PAINTMODE)
1641516460 object.editWindow.ScreenFitPoint(); // fev 2014
1641616461
16417
- if (PAINTMODE && GrafreeD.clipboard.size() == 1) // object.editWindow.copy.selection.Size() > 0)
16462
+ if (PAINTMODE && Grafreed.clipboard.size() == 1) // object.editWindow.copy.selection.Size() > 0)
1641816463 {
16419
- Object3D paintobj = GrafreeD.clipboard.get(0); // object.editWindow.copy.selection.elementAt(0);
16464
+ Object3D paintobj = Grafreed.clipboard.get(0); // object.editWindow.copy.selection.elementAt(0);
1642016465
1642116466 Object3D group = new Object3D("inst" + paintcount++);
1642216467
....@@ -16572,7 +16617,7 @@
1657216617 gl.glDisable(gl.GL_CULL_FACE);
1657316618 }
1657416619
16575
- if (!RENDERSHADOW)
16620
+ if (!Globals.RENDERSHADOW)
1657616621 gl.glClear(GL.GL_COLOR_BUFFER_BIT | GL.GL_DEPTH_BUFFER_BIT);
1657716622
1657816623 // SB gl.glPolygonOffset(2.5f, 10);
....@@ -16582,7 +16627,7 @@
1658216627 //gl.glColorMask(false, false, false, false);
1658316628
1658416629 //render_scene_from_light_view(gl, drawable, 0, 0);
16585
- if (RENDERSHADOW && Globals.lighttouched && !movingcamera) // && !parent.IsFreezed())
16630
+ if (Globals.RENDERSHADOW && Globals.lighttouched && (!movingcamera || !Globals.FREEZEONMOVE)) // && !parent.IsFreezed())
1658616631 {
1658716632 gl.glClear(GL.GL_COLOR_BUFFER_BIT | GL.GL_DEPTH_BUFFER_BIT);
1658816633