Normand Briere
2019-08-17 ecc1309a04b527c62ffe97e814daf050dbd025cd
ObjEditor.java
....@@ -426,6 +426,9 @@
426426
427427 static java.util.Vector<Object3D> listUI = new java.util.Vector<Object3D>();
428428
429
+ // This is to refresh the UI of the material panel.
430
+ boolean patchMaterial;
431
+
429432 void SetupMenu()
430433 {
431434 frame.setMenuBar(menuBar = new MenuBar());
....@@ -1689,6 +1692,10 @@
16891692 objectPanel.setIconAt(4, GetIcon("icons/XYZ.png"));
16901693 objectPanel.setToolTipTextAt(4, "XYZ/RGB transform");
16911694
1695
+ patchMaterial = true;
1696
+ cameraView.patchMaterial = this;
1697
+ objectPanel.setSelectedIndex(1);
1698
+
16921699 /*
16931700 aConstraints.gridx = 0;
16941701 aConstraints.gridwidth = 1;
....@@ -1886,7 +1893,15 @@
18861893
18871894 // Skin
18881895 colorField.setFloat(material.color);
1889
- saturationField.setFloat(material.modulation);
1896
+ float saturation = material.modulation;
1897
+
1898
+ if (!cameraView.Skinshader)
1899
+ {
1900
+ saturation /= 1.5;
1901
+ }
1902
+
1903
+ saturationField.setFloat(saturation);
1904
+
18901905 subsurfaceField.setFloat(material.subsurface);
18911906 selfshadowField.setFloat(material.diffuseness);
18921907 diffusenessField.setFloat(material.factor);