Normand Briere
2019-06-11 d0dc7ff35d71919d503ae35592478b173cf3cfd3
CameraPane.java
....@@ -1628,7 +1628,7 @@
16281628
16291629 cColor.HSBtoRGB(display.color, display.saturation, 1, display.modelParams0);
16301630
1631
- float[] colorV = GrafreeD.colorV;
1631
+ float[] colorV = Grafreed.colorV;
16321632
16331633 /**/
16341634 if (display.DrawMode() == display.DEFAULT) // && display.RENDERPROGRAM == 0)
....@@ -2140,7 +2140,7 @@
21402140 System.err.println("LIVE = " + Globals.isLIVE());
21412141
21422142 if (!Globals.isLIVE()) // save sound
2143
- GrafreeD.savesound = true; // wav.save();
2143
+ Grafreed.savesound = true; // wav.save();
21442144 // else
21452145 repaint(); // start loop // may 2013
21462146 }
....@@ -8022,7 +8022,7 @@
80228022 }
80238023 }
80248024
8025
- /*boolean*/ public void BindTextures(cTexture tex, int resolution) // INTERFACE
8025
+ /*boolean*/ public void BindTextures(cTexture tex, int resolution) throws Exception // INTERFACE
80268026 {
80278027 if (// DrawMode() != 0 || /*tex == null ||*/
80288028 ambientOcclusion ) // || !textureon)
....@@ -8067,7 +8067,7 @@
80678067 return; // true;
80688068 }
80698069
8070
- CacheTexture GetCacheTexture(String tex, boolean bump, int resolution)
8070
+ CacheTexture GetCacheTexture(String tex, boolean bump, int resolution) throws Exception
80718071 {
80728072 CacheTexture/*com.sun.opengl.util.texture.Texture*/ texture = null;
80738073
....@@ -8184,7 +8184,9 @@
81848184 texturedata = GetFileTexture(cachename, processbump, resolution);
81858185
81868186
8187
- if (texturedata != null)
8187
+ if (texturedata == null)
8188
+ throw new Exception();
8189
+
81888190 texture = new CacheTexture(com.sun.opengl.util.texture.TextureIO.newTexture(texturedata),resolution);
81898191 //texture = GetTexture(tex, bump);
81908192 }
....@@ -8306,7 +8308,7 @@
83068308 return texture;
83078309 }
83088310
8309
- 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
83108312 {
83118313 CacheTexture texture = GetCacheTexture(tex, bump, resolution);
83128314
....@@ -8324,14 +8326,14 @@
83248326 return texture!=null?texture.texture:null;
83258327 }
83268328
8327
- 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
83288330 {
83298331 CacheTexture texture = GetCacheTexture(tex, bump, resolution);
83308332
83318333 return texture!=null?texture.texturedata:null;
83328334 }
83338335
8334
- boolean BindTexture(String tex, boolean bump, int resolution)
8336
+ boolean BindTexture(String tex, boolean bump, int resolution) throws Exception
83358337 {
83368338 if (/*tex == null ||*/ ambientOcclusion ) // || !textureon)
83378339 {
....@@ -9542,7 +9544,7 @@
95429544
95439545 if (!BOXMODE)
95449546 {
9545
- 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) + ")");
95469548 }
95479549
95489550 if (!BOXMODE)
....@@ -9580,7 +9582,7 @@
95809582 ABORTED = false;
95819583 }
95829584 else
9583
- GrafreeD.wav.cursor += 735 * ACSIZE;
9585
+ Grafreed.wav.cursor += 735 * ACSIZE;
95849586
95859587 if (false)
95869588 {
....@@ -10243,11 +10245,11 @@
1024310245
1024410246 public void display(GLAutoDrawable drawable)
1024510247 {
10246
- if (GrafreeD.savesound && GrafreeD.hassound)
10248
+ if (Grafreed.savesound && Grafreed.hassound)
1024710249 {
10248
- GrafreeD.wav.save();
10249
- GrafreeD.savesound = false;
10250
- GrafreeD.hassound = false;
10250
+ Grafreed.wav.save();
10251
+ Grafreed.savesound = false;
10252
+ Grafreed.hassound = false;
1025110253 }
1025210254 // if (DEBUG_SELECTION)
1025310255 // {
....@@ -10377,7 +10379,7 @@
1037710379 Object3D theobject = object;
1037810380 Object3D theparent = object.parent;
1037910381 object.parent = null;
10380
- object = (Object3D)GrafreeD.clone(object);
10382
+ object = (Object3D)Grafreed.clone(object);
1038110383 object.Stripify();
1038210384 if (theobject.selection == null || theobject.selection.Size() == 0)
1038310385 theobject.PreprocessOcclusion(this);
....@@ -10390,13 +10392,13 @@
1039010392 ambientOcclusion = false;
1039110393 }
1039210394
10393
- if (Globals.lighttouched && DrawMode() == DEFAULT && !lightMode) // && !FROZEN)
10395
+ if (Globals.lighttouched && DrawMode() == DEFAULT) // && !lightMode) // && !FROZEN)
1039410396 {
1039510397 //if (RENDERSHADOW) // ?
1039610398 if (!IsFrozen())
1039710399 {
1039810400 // dec 2012
10399
- if (!ambientOcclusion && !(!flash && !lightMode && DrawMode() == DEFAULT && ANTIALIAS > 0))
10401
+ if (!ambientOcclusion && !(!flash && DrawMode() == DEFAULT && ANTIALIAS > 0))
1040010402 {
1040110403 Globals.framecount++;
1040210404 shadowbuffer.display();
....@@ -10798,7 +10800,16 @@
1079810800 // Bump noise
1079910801 gl.glActiveTexture(GL.GL_TEXTURE6);
1080010802 //gl.glBindTexture(GL.GL_TEXTURE_2D, bump_noise);
10801
- 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
+
1080210813
1080310814 gl.glActiveTexture(GL.GL_TEXTURE0);
1080410815 gl.glEnable(GL.GL_TEXTURE_2D);
....@@ -11283,8 +11294,8 @@
1128311294 e.printStackTrace();
1128411295 }
1128511296
11286
- if (GrafreeD.RENDERME > 0)
11287
- GrafreeD.RENDERME--; // mechante magouille
11297
+ if (Grafreed.RENDERME > 0)
11298
+ Grafreed.RENDERME--; // mechante magouille
1128811299
1128911300 Globals.ONESTEP = false;
1129011301 }
....@@ -11354,7 +11365,14 @@
1135411365
1135511366 usedtextures.clear();
1135611367
11357
- 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
+ }
1135811376 }
1135911377 //System.out.println("--> " + stackdepth);
1136011378 // GrafreeD.traceon();
....@@ -11445,7 +11463,14 @@
1144511463 if (checker != null && DrawMode() == DEFAULT)
1144611464 {
1144711465 //BindTexture(IMMORTAL_TEXTURE);
11448
- 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
+ }
1144911474 // NEAREST
1145011475 GetGL().glTexParameteri(GL.GL_TEXTURE_2D, GL.GL_TEXTURE_MAG_FILTER, GL.GL_NEAREST); // GL.GL_LINEAR);
1145111476 DrawChecker(gl);
....@@ -11527,7 +11552,7 @@
1152711552 return;
1152811553 }
1152911554
11530
- String string = obj.GetToolTip();
11555
+ String string = obj.toString(); //.GetToolTip();
1153111556
1153211557 GL gl = GetGL();
1153311558
....@@ -12477,8 +12502,8 @@
1247712502
1247812503 // display shadow only (bump == 0)
1247912504 "SUB temp.x, half.x, shadow.x;" +
12480
- "MOV temp.y, -params6.x;" +
12481
- "SLT temp.z, temp.y, zero.x;" +
12505
+ "MOV temp.y, -params5.z;" + // params6.x;" +
12506
+ "SLT temp.z, temp.y, -one2048th.x;" +
1248212507 "SUB temp.y, one.x, temp.z;" +
1248312508 "MUL temp.x, temp.x, temp.y;" +
1248412509 "KIL temp.x;" +
....@@ -12758,7 +12783,7 @@
1275812783 "MUL final.y, fragment.texcoord[0].x, c256;" +
1275912784 "FLR final.x, final.y;" +
1276012785 "SUB final.y, final.y, final.x;" +
12761
- //"MUL final.x, final.x, c256i;" +
12786
+ "MUL final.x, final.x, c256i;" +
1276212787 "MOV final.z, zero.x;" +
1276312788 "MOV final.a, one.w;":""
1276412789 ) +
....@@ -12766,7 +12791,7 @@
1276612791 "MUL final.y, fragment.texcoord[0].y, c256;" +
1276712792 "FLR final.x, final.y;" +
1276812793 "SUB final.y, final.y, final.x;" +
12769
- //"MUL final.x, final.x, c256i;" +
12794
+ "MUL final.x, final.x, c256i;" +
1277012795 "MOV final.z, zero.x;" +
1277112796 "MOV final.a, one.w;":""
1277212797 ) +
....@@ -12809,7 +12834,7 @@
1280912834 //once = true;
1281012835 }
1281112836
12812
- System.out.print("Program #" + mode + "; length = " + program.length());
12837
+ System.out.print("Program #" + mode + "; instructions = " + program.split(";").length + "; length = " + program.length());
1281312838 System.out.println(" - " + (mode >> 3) + " lights; " + ((mode & 2) == 2 ? "anisoUV " : "") + ((mode & 4) == 4 ? "SoftShadow " : ""));
1281412839 loadProgram(gl, GL.GL_FRAGMENT_PROGRAM_ARB, program);
1281512840
....@@ -12942,12 +12967,16 @@
1294212967
1294312968 "ADD " + depth + ".z, " + depth + ".z, temp.x;" +
1294412969 //"SUB " + depth + ".z, " + depth + ".z, temp.x;" + // back face shadowing!
12970
+
12971
+ // Compare fragment depth in light space with shadowmap.
1294512972 "SUB temp.x, fragment.texcoord[1].z, " + depth + ".z;" +
1294612973 "SGE temp.y, temp.x, zero.x;" +
12947
- "SUB " + shadow + ".y, one.x, temp.y;" +
12974
+ "SUB " + shadow + ".y, one.x, temp.y;" + // Specular is fully occluded
12975
+
12976
+ // Reverse comparison
1294812977 "SUB temp.x, one.x, temp.x;" +
1294912978 "MUL " + shadow + ".x, temp.x, temp.y;" +
12950
- "SUB " + shadow + ".x, one.x, " + shadow + ".x;" + // specular is fully occluded
12979
+ "SUB " + shadow + ".x, one.x, " + shadow + ".x;" + // diffuse
1295112980 "POW " + shadow + ".x, " + shadow + ".x, params5.z;" + // fake depth
1295212981
1295312982 "SLT " + shadow + ".z, fragment.texcoord[1].z, " + depth + ".z;" +
....@@ -12961,6 +12990,10 @@
1296112990 // No shadow for backface
1296212991 "DP3 temp.x, normal, lightd;" +
1296312992 "SLT temp.x, temp.x, zero.x;" + // shadoweps
12993
+ "LRP " + shadow + ", temp.x, one, " + shadow + ";" +
12994
+
12995
+ // No shadow when out of frustrum
12996
+ "SGE temp.x, " + depth + ".z, one.z;" +
1296412997 "LRP " + shadow + ", temp.x, one, " + shadow + ";" +
1296512998 "";
1296612999 }
....@@ -13519,7 +13552,7 @@
1351913552 public void mousePressed(MouseEvent e)
1352013553 {
1352113554 //System.out.println("mousePressed: " + e);
13522
- clickStart(e.getX(), e.getY(), e.getModifiersEx());
13555
+ clickStart(e.getX(), e.getY(), e.getModifiers(), e.getModifiersEx());
1352313556 }
1352413557
1352513558 static long prevtime = 0;
....@@ -13595,8 +13628,8 @@
1359513628 // mode |= META;
1359613629 //}
1359713630
13598
- SetMouseMode(WHEEL | e.getModifiersEx());
13599
- drag(anchorX, anchorY + e.getUnitsToScroll()*8, 0);
13631
+ SetMouseMode(e.getModifiers(), WHEEL | e.getModifiersEx());
13632
+ drag(anchorX, anchorY + e.getUnitsToScroll()*8, 0, 0);
1360013633 anchorX = ax;
1360113634 anchorY = ay;
1360213635 prevX = px;
....@@ -13656,6 +13689,10 @@
1365613689 // wasliveok = true;
1365713690 // waslive = false;
1365813691
13692
+ // May 2019 Forget it:
13693
+ if (true)
13694
+ return;
13695
+
1365913696 // source == timer
1366013697 if (mouseDown)
1366113698 {
....@@ -13694,7 +13731,7 @@
1369413731
1369513732 javax.swing.Timer timer = new javax.swing.Timer(350, this);
1369613733
13697
- void clickStart(int x, int y, int modifiers)
13734
+ void clickStart(int x, int y, int modifiers, int modifiersex)
1369813735 {
1369913736 if (!wasliveok)
1370013737 return;
....@@ -13711,7 +13748,7 @@
1371113748 // touched = true; // main DL
1371213749 if (isRenderer)
1371313750 {
13714
- SetMouseMode(modifiers);
13751
+ SetMouseMode(modifiers, modifiersex);
1371513752 }
1371613753
1371713754 selectX = anchorX = x;
....@@ -13724,7 +13761,7 @@
1372413761 clicked = true;
1372513762 hold = false;
1372613763
13727
- if (((modifiers & ~1024) & ~0) == 0) // Single or multiple selection
13764
+ if (((modifiersex & ~1024) & ~0) == 0) // Single or multiple selection
1372813765 // june 2013 means CTRL_CLICK: if (((modifiers & ~1024) & ~128) == 0) // Single or multiple selection
1372913766 {
1373013767 // System.out.println("RESTART II " + modifiers);
....@@ -13755,7 +13792,7 @@
1375513792 info.camera = renderCamera;
1375613793 info.x = x;
1375713794 info.y = y;
13758
- info.modifiers = modifiers;
13795
+ info.modifiers = modifiersex;
1375913796 editObj = object.doEditClick(info, 0);
1376013797 if (!editObj)
1376113798 {
....@@ -13784,7 +13821,7 @@
1378413821 clickEnd(e.getX(), e.getY(), e.getModifiersEx());
1378513822 }
1378613823 else
13787
- drag(e.getX(), e.getY(), e.getModifiersEx());
13824
+ drag(e.getX(), e.getY(), e.getModifiers(), e.getModifiersEx());
1378813825
1378913826 //try { Thread.sleep(1); } catch (Exception ex) {}
1379013827 }
....@@ -14021,7 +14058,7 @@
1402114058 {
1402214059 Globals.lighttouched = true;
1402314060 }
14024
- drag(X, (mouseMode != 0) ? Y : anchorY, MODIFIERS);
14061
+ drag(X, (mouseMode != 0) ? Y : anchorY, 0, MODIFIERS);
1402514062 }
1402614063 //else
1402714064 }
....@@ -14121,7 +14158,7 @@
1412114158 int X, Y;
1412214159 boolean SX, SY;
1412314160
14124
- void drag(int x, int y, int modifiers)
14161
+ void drag(int x, int y, int modifiers, int modifiersex)
1412514162 {
1412614163 if (IsFrozen())
1412714164 {
....@@ -14130,17 +14167,17 @@
1413014167
1413114168 drag = true; // NEW
1413214169
14133
- boolean continuous = (modifiers & COMMAND) == COMMAND;
14170
+ boolean continuous = (modifiersex & COMMAND) == COMMAND;
1413414171
1413514172 X = x;
1413614173 Y = y;
1413714174 // floating state for animation
14138
- MODIFIERS = modifiers;
14139
- modifiers &= ~1024;
14175
+ MODIFIERS = modifiersex;
14176
+ modifiersex &= ~1024;
1414014177 if (false) // modifiers != 0)
1414114178 {
1414214179 //new Exception().printStackTrace();
14143
- System.out.println("mouseDragged: " + modifiers);
14180
+ System.out.println("mouseDragged: " + modifiersex);
1414414181 System.out.println("SHIFT = " + SHIFT);
1414514182 System.out.println("CONTROL = " + COMMAND);
1414614183 System.out.println("META = " + META);
....@@ -14160,7 +14197,7 @@
1416014197 info.camera = renderCamera;
1416114198 info.x = x;
1416214199 info.y = y;
14163
- object.editWindow.copy.doEditDrag(info);
14200
+ object.editWindow.copy.doEditDrag(info, (modifiers & MouseEvent.BUTTON3_MASK) != 0);
1416414201 } else
1416514202 {
1416614203 if (x < startX)
....@@ -14337,6 +14374,7 @@
1433714374 public void mouseReleased(MouseEvent e)
1433814375 {
1433914376 movingcamera = false;
14377
+ X = Y = 0;
1434014378 //System.out.println("mouseReleased: " + e);
1434114379 clickEnd(e.getX(), e.getY(), e.getModifiersEx());
1434214380 }
....@@ -14359,9 +14397,9 @@
1435914397 boolean control = ((modifiers & CTRL) != 0); // june 2013: for point selection
1436014398 boolean command = ((modifiers & COMMAND) != 0); // june 2013: for multiple selection
1436114399
14362
- if (control || command || IsFrozen())
14400
+// No delay if (control || command || IsFrozen())
1436314401 timeout = true;
14364
- else
14402
+// ?? May 2019 else
1436514403 // timer.setDelay((modifiers & 128) != 0?0:350);
1436614404 mouseDown = false;
1436714405 if (!control && !command) // june 2013
....@@ -14471,7 +14509,7 @@
1447114509 System.out.println("keyReleased: " + e);
1447214510 }
1447314511
14474
- void SetMouseMode(int modifiers)
14512
+ void SetMouseMode(int modifiers, int modifiersex)
1447514513 {
1447614514 //System.out.println("SetMouseMode = " + modifiers);
1447714515 //modifiers &= ~1024;
....@@ -14483,25 +14521,25 @@
1448314521 //if (modifiers == 0) // || (modifiers == (1024 | CONTROL)))
1448414522 // return;
1448514523 //System.out.println("SetMode = " + modifiers);
14486
- if ((modifiers & WHEEL) == WHEEL)
14524
+ if ((modifiersex & WHEEL) == WHEEL)
1448714525 {
1448814526 mouseMode |= ZOOM;
1448914527 }
1449014528
1449114529 boolean capsLocked = Toolkit.getDefaultToolkit().getLockingKeyState(KeyEvent.VK_CAPS_LOCK);
14492
- if (capsLocked || (modifiers & META) == META)
14530
+ if (capsLocked) // || (modifiers & META) == META)
1449314531 {
1449414532 mouseMode |= VR; // BACKFORTH;
1449514533 }
14496
- if ((modifiers & CTRLCLICK) == CTRLCLICK)
14534
+ if ((modifiersex & CTRLCLICK) == CTRLCLICK)
1449714535 {
1449814536 mouseMode |= SELECT;
1449914537 }
14500
- if ((modifiers & COMMAND) == COMMAND)
14538
+ if ((modifiersex & COMMAND) == COMMAND)
1450114539 {
1450214540 mouseMode |= SELECT;
1450314541 }
14504
- if ((modifiers & SHIFT) == SHIFT || forcetranslate)
14542
+ if ((modifiersex & SHIFT) == SHIFT || forcetranslate || (modifiers & MouseEvent.BUTTON3_MASK) != 0)
1450514543 {
1450614544 mouseMode &= ~VR;
1450714545 mouseMode |= TRANSLATE;
....@@ -14530,7 +14568,7 @@
1453014568
1453114569 if (isRenderer) //
1453214570 {
14533
- SetMouseMode(modifiers);
14571
+ SetMouseMode(0, modifiers);
1453414572 }
1453514573
1453614574 Globals.theRenderer.keyPressed(key);
....@@ -14866,7 +14904,7 @@
1486614904 //RESIZETEXTURE ^= true;
1486714905 //break;
1486814906 case 'z':
14869
- RENDERSHADOW ^= true;
14907
+ Globals.RENDERSHADOW ^= true;
1487014908 Globals.lighttouched = true;
1487114909 repaint();
1487214910 break;
....@@ -14990,7 +15028,7 @@
1499015028 //mode = ROTATE;
1499115029 if ((MODIFIERS & COMMAND) == 0) // VR??
1499215030 {
14993
- SetMouseMode(modifiers);
15031
+ SetMouseMode(0, modifiers);
1499415032 }
1499515033 }
1499615034
....@@ -15126,7 +15164,7 @@
1512615164 {
1512715165 //System.out.println("processMouseMotionEvent: " + mouseMode + " " + e.getModifiers() + " " + e.getModifiersEx() + " " + e.getButton());
1512815166 //if (e.getButton() == MouseEvent.NOBUTTON && (mouseMode & SELECT) == 0)
15129
- if ((e.getModifiers() & MouseEvent.BUTTON1_MASK) == 0 && (mouseMode & SELECT) == 0)
15167
+ if ((e.getModifiers() & MouseEvent.BUTTON1_MASK) == 0 && (e.getModifiers() & MouseEvent.BUTTON3_MASK) == 0 && (mouseMode & SELECT) == 0)
1513015168 {
1513115169 mouseMoved(e);
1513215170 } else
....@@ -15345,7 +15383,9 @@
1534515383 info.bounds.setBounds(0, 0, (int) (width * zoom), (int) (height * zoom));
1534615384 //Image img = CreateImage(width, height);
1534715385 //System.out.println("width = " + width + "; height = " + height + "\n");
15386
+
1534815387 Graphics gr = g; // img.getGraphics();
15388
+
1534915389 if (!hasMarquee)
1535015390 {
1535115391 if (Xmin < Xmax) // !locked)
....@@ -15443,14 +15483,28 @@
1544315483 if (!isRenderer)
1544415484 {
1544515485 object.drawEditHandles(info, 0);
15486
+
15487
+ if (drag && (X != 0 || Y != 0) && object.selection.Size() > 0)
15488
+ {
15489
+ switch (object.selection.get(0).hitSomething)
15490
+ {
15491
+ case Object3D.hitCenter: gr.setColor(Color.pink); break;
15492
+ case Object3D.hitRotate: gr.setColor(Color.green); break;
15493
+ case Object3D.hitScale: gr.setColor(Color.cyan); break;
15494
+ }
15495
+
15496
+ gr.drawLine(X, Y, info.bounds.width/2, info.bounds.height/2);
15497
+ }
1544615498 }
1544715499 }
15500
+
1544815501 if (isRenderer)
1544915502 {
1545015503 //gr.setColor(Color.black);
1545115504 //gr.drawRect(info.bounds.x - 1, info.bounds.y - 1, info.bounds.width + 1, info.bounds.height + 1);
1545215505 //gr.drawRect(info.bounds.x - 2, info.bounds.y - 2, info.bounds.width + 3, info.bounds.height + 3);
1545315506 }
15507
+
1545415508 if (hasMarquee)
1545515509 {
1545615510 gr.setXORMode(Color.white);
....@@ -15563,6 +15617,7 @@
1556315617 public boolean mouseDown(Event evt, int x, int y)
1556415618 {
1556515619 System.out.println("mouseDown: " + evt);
15620
+ System.exit(0);
1556615621 /*
1556715622 locked = true;
1556815623 drag = false;
....@@ -15606,7 +15661,7 @@
1560615661 {
1560715662 keyPressed(0, modifiers);
1560815663 }
15609
- clickStart(x, y, modifiers);
15664
+ // clickStart(x, y, modifiers);
1561015665 return true;
1561115666 }
1561215667
....@@ -15724,7 +15779,7 @@
1572415779 {
1572515780 keyReleased(0, 0);
1572615781 }
15727
- drag(x, y, modifiers);
15782
+ drag(x, y, 0, modifiers);
1572815783 return true;
1572915784 }
1573015785
....@@ -16422,16 +16477,16 @@
1642216477 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]));
1642316478 }
1642416479
16425
- previousselectedpoint = (Sphere) GrafreeD.clone(selectedpoint);
16480
+ previousselectedpoint = (Sphere) Grafreed.clone(selectedpoint);
1642616481 }
1642716482 }
1642816483
1642916484 if (!movingcamera && !PAINTMODE)
1643016485 object.editWindow.ScreenFitPoint(); // fev 2014
1643116486
16432
- if (PAINTMODE && GrafreeD.clipboard.size() == 1) // object.editWindow.copy.selection.Size() > 0)
16487
+ if (PAINTMODE && Grafreed.clipboard.size() == 1) // object.editWindow.copy.selection.Size() > 0)
1643316488 {
16434
- Object3D paintobj = GrafreeD.clipboard.get(0); // object.editWindow.copy.selection.elementAt(0);
16489
+ Object3D paintobj = Grafreed.clipboard.get(0); // object.editWindow.copy.selection.elementAt(0);
1643516490
1643616491 Object3D group = new Object3D("inst" + paintcount++);
1643716492
....@@ -16587,7 +16642,7 @@
1658716642 gl.glDisable(gl.GL_CULL_FACE);
1658816643 }
1658916644
16590
- if (!RENDERSHADOW)
16645
+ if (!Globals.RENDERSHADOW)
1659116646 gl.glClear(GL.GL_COLOR_BUFFER_BIT | GL.GL_DEPTH_BUFFER_BIT);
1659216647
1659316648 // SB gl.glPolygonOffset(2.5f, 10);
....@@ -16597,7 +16652,7 @@
1659716652 //gl.glColorMask(false, false, false, false);
1659816653
1659916654 //render_scene_from_light_view(gl, drawable, 0, 0);
16600
- if (RENDERSHADOW && Globals.lighttouched && !movingcamera) // && !parent.IsFreezed())
16655
+ if (Globals.RENDERSHADOW && Globals.lighttouched && (!movingcamera || !Globals.FREEZEONMOVE)) // && !parent.IsFreezed())
1660116656 {
1660216657 gl.glClear(GL.GL_COLOR_BUFFER_BIT | GL.GL_DEPTH_BUFFER_BIT);
1660316658