Normand Briere
2019-05-13 f924d3e00db476c06f55f3d5aaef307e17575340
ObjEditor.java
....@@ -501,13 +501,13 @@
501501 //SendInfo("Name:", "bold");
502502 if (sel.GetTextures() != null || debug)
503503 {
504
- si.SendInfo(sel.toString(), "bold");
504
+ si.SendInfo(sel.toString() + (Globals.ADVANCED?"":" " + System.identityHashCode(sel)), "bold");
505505 //SendInfo("#children virtual = " + sel.size() + "; real = " + sel.Size() + newline, "regular");
506506 if (sel.Size() > 0)
507507 {
508508 si.SendInfo("#children = " + sel.Size(), "regular");
509509 }
510
- si.SendInfo((debug ? " Parent: " : " ") + sel.parent, "regular");
510
+ si.SendInfo((debug ? " Parent: " : " ") + sel.parent + (Globals.ADVANCED?"":" " + System.identityHashCode(sel.parent)), "regular");
511511 if (debug)
512512 {
513513 try
....@@ -549,7 +549,7 @@
549549 }
550550 if (sel.support != null)
551551 {
552
- si.SendInfo(" support: " + sel.support, "regular");
552
+ si.SendInfo(" support: " + sel.support + (Globals.ADVANCED?"":" " + System.identityHashCode(sel.support)), "regular");
553553 }
554554 if (sel.scriptnode != null)
555555 {
....@@ -752,7 +752,7 @@
752752 protected static ImageIcon createImageIcon(String path,
753753 String description)
754754 {
755
- java.net.URL imgURL = GrafreeD.class.getResource(path);
755
+ java.net.URL imgURL = Grafreed.class.getResource(path);
756756 if (imgURL != null)
757757 {
758758 return new ImageIcon(imgURL, description);
....@@ -1476,19 +1476,19 @@
14761476
14771477 cGridBag editBar = new cGridBag().setVertical(false);
14781478
1479
- editBar.add(createMaterialButton = new cButton("Create", !GrafreeD.NIMBUSLAF)); // , aConstraints);
1479
+ editBar.add(createMaterialButton = new cButton("Create", !Grafreed.NIMBUSLAF)); // , aConstraints);
14801480 createMaterialButton.setToolTipText("Create material");
14811481
14821482 /*
14831483 ctrlPanel.add(resetSlidersButton = new cButton("Reset All"), aConstraints);
14841484 */
14851485
1486
- editBar.add(clearMaterialButton = new cButton("Clear", !GrafreeD.NIMBUSLAF)); // , aConstraints);
1486
+ editBar.add(clearMaterialButton = new cButton("Clear", !Grafreed.NIMBUSLAF)); // , aConstraints);
14871487 clearMaterialButton.setToolTipText("Clear material");
14881488
14891489 if (Globals.ADVANCED)
14901490 {
1491
- editBar.add(resetSlidersButton = new cButton("Reset", !GrafreeD.NIMBUSLAF)); // , aConstraints);
1491
+ editBar.add(resetSlidersButton = new cButton("Reset", !Grafreed.NIMBUSLAF)); // , aConstraints);
14921492 editBar.add(propagateToggle = new cCheckBox("Prop", propagate)); // , aConstraints);
14931493 editBar.add(multiplyToggle = new cCheckBox("Mult", false)); // , aConstraints);
14941494 }
....@@ -2396,7 +2396,7 @@
23962396
23972397 void ImportJME(com.jmex.model.converters.FormatConverter converter, String ext, String dialogName)
23982398 {
2399
- if (GrafreeD.standAlone)
2399
+ if (Grafreed.standAlone)
24002400 {
24012401 /**/
24022402 FileDialog browser = new FileDialog(frame, dialogName, FileDialog.LOAD);
....@@ -3255,8 +3255,8 @@
32553255
32563256 Globals.ANIMATION ^= true;
32573257
3258
- GrafreeD.wav.cursor = 0;
3259
- GrafreeD.wav.loop = 0;
3258
+ Grafreed.wav.cursor = 0;
3259
+ Grafreed.wav.loop = 0;
32603260 }
32613261 } else
32623262 {
....@@ -3443,6 +3443,36 @@
34433443 {
34443444 //System.out.println("Propagate = " + propagate);
34453445 copy.UpdateMaterial(anchor, current, propagate);
3446
+
3447
+ if (copy.material != null)
3448
+ {
3449
+ cMaterial mat = copy.material;
3450
+
3451
+ colorField.SetToolTipValue((mat.color));
3452
+ modulationField.SetToolTipValue((mat.modulation));
3453
+ metalnessField.SetToolTipValue((mat.metalness));
3454
+ diffuseField.SetToolTipValue((mat.diffuse));
3455
+ specularField.SetToolTipValue((mat.specular));
3456
+ shininessField.SetToolTipValue((mat.shininess));
3457
+ shiftField.SetToolTipValue((mat.shift));
3458
+ ambientField.SetToolTipValue((mat.ambient));
3459
+ lightareaField.SetToolTipValue((mat.lightarea));
3460
+ diffusenessField.SetToolTipValue((mat.factor));
3461
+ velvetField.SetToolTipValue((mat.velvet));
3462
+ sheenField.SetToolTipValue((mat.sheen));
3463
+ subsurfaceField.SetToolTipValue((mat.subsurface));
3464
+ backlitField.SetToolTipValue((mat.bump));
3465
+ anisoField.SetToolTipValue((mat.aniso));
3466
+ anisoVField.SetToolTipValue((mat.anisoV));
3467
+ cameraField.SetToolTipValue((mat.cameralight));
3468
+ selfshadowField.SetToolTipValue((mat.diffuseness));
3469
+ shadowField.SetToolTipValue((mat.shadow));
3470
+ textureField.SetToolTipValue((mat.texture));
3471
+ opacityField.SetToolTipValue((mat.opacity));
3472
+ fakedepthField.SetToolTipValue((mat.fakedepth));
3473
+ shadowbiasField.SetToolTipValue((mat.shadowbias));
3474
+ }
3475
+
34463476 if (copy.material != null && copy.projectedVertices.length > 0 && copy.projectedVertices[0] != null)
34473477 {
34483478 copy.projectedVertices[0].x = (int) (bumpField.getFloat() * 1000);
....@@ -4170,7 +4200,7 @@
41704200
41714201 void load() // throws ClassNotFoundException
41724202 {
4173
- if (GrafreeD.standAlone)
4203
+ if (Grafreed.standAlone)
41744204 {
41754205 FileDialog browser = new FileDialog(frame, "Load", FileDialog.LOAD);
41764206 browser.show();
....@@ -4275,7 +4305,7 @@
42754305
42764306 void saveAs()
42774307 {
4278
- if (GrafreeD.standAlone)
4308
+ if (Grafreed.standAlone)
42794309 {
42804310 FileDialog browser = new FileDialog(frame, "Save As", FileDialog.SAVE);
42814311 browser.setVisible(true);
....@@ -4386,7 +4416,7 @@
43864416 Object3D objectparent = obj.parent;
43874417 obj.parent = null;
43884418
4389
- Object3D object = (Object3D) GrafreeD.clone(obj);
4419
+ Object3D object = (Object3D) Grafreed.clone(obj);
43904420
43914421 obj.parent = objectparent;
43924422
....@@ -4420,7 +4450,7 @@
44204450 buffer.append("background { color rgb <0.8,0.8,0.8> }\n\n");
44214451 cameraView.renderCamera.generatePOV(buffer, bnds.width, bnds.height);
44224452 copy.generatePOV(buffer);
4423
- if (GrafreeD.standAlone)
4453
+ if (Grafreed.standAlone)
44244454 {
44254455 FileDialog browser = new FileDialog(frame, "Export POV", 1);
44264456 browser.show();