.. | .. |
---|
160 | 160 | objEditor.ctrlPanel.remove(slowerButton); |
---|
161 | 161 | objEditor.ctrlPanel.remove(fasterButton); |
---|
162 | 162 | objEditor.ctrlPanel.remove(remarkButton); |
---|
| 163 | + |
---|
| 164 | + Remove(normalpushField); |
---|
163 | 165 | } |
---|
164 | 166 | |
---|
165 | 167 | public ObjEditor GetEditor() |
---|
166 | 168 | { |
---|
167 | 169 | return objEditor; //.GetEditor(); |
---|
168 | 170 | } |
---|
| 171 | + |
---|
| 172 | + // Sometimes myself, sometimes my callee's. |
---|
169 | 173 | ObjEditor objEditor; |
---|
170 | 174 | |
---|
171 | 175 | /* |
---|
.. | .. |
---|
814 | 818 | |
---|
815 | 819 | aConstraints.fill = GridBagConstraints.VERTICAL; |
---|
816 | 820 | jlabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
817 | | - aConstraints.gridwidth = 2; |
---|
| 821 | + aConstraints.gridwidth = 1; |
---|
818 | 822 | ctrlPanel.add(jlabel, aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
819 | 823 | aConstraints.gridx += 1; |
---|
820 | 824 | aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
.. | .. |
---|
983 | 987 | |
---|
984 | 988 | Return(); |
---|
985 | 989 | |
---|
| 990 | + normalpushField = AddSlider(oe.ctrlPanel, "Push", -10, 10, 0, -1); |
---|
| 991 | + Return(); |
---|
| 992 | + |
---|
986 | 993 | // oe.ctrlPanel.add(stepButton = new cButton("Step"), ObjEditor.aConstraints, oe.ctrlPanel.getComponentCount() - 2); |
---|
987 | 994 | // ObjEditor.aConstraints.gridx += 1; |
---|
988 | 995 | |
---|
.. | .. |
---|
1446 | 1453 | aConstraints.gridx += 1; |
---|
1447 | 1454 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1448 | 1455 | //aConstraints.weightx = 0; |
---|
1449 | | - ctrlPanel.add(colorField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
| 1456 | + ctrlPanel.add(colorField = new NumberSlider(0.001, 1, -0.5), aConstraints); |
---|
1450 | 1457 | aConstraints.gridx = 0; |
---|
1451 | 1458 | aConstraints.gridy += 1; |
---|
1452 | 1459 | aConstraints.gridwidth = 1; |
---|
.. | .. |
---|
1456 | 1463 | aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1457 | 1464 | aConstraints.gridx += 1; |
---|
1458 | 1465 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1459 | | - ctrlPanel.add(modulationField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
| 1466 | + ctrlPanel.add(modulationField = new NumberSlider(0.001, 1, -0.5), aConstraints); |
---|
1460 | 1467 | aConstraints.gridx = 0; |
---|
1461 | 1468 | aConstraints.gridy += 1; |
---|
1462 | 1469 | aConstraints.gridwidth = 1; |
---|
.. | .. |
---|
1466 | 1473 | aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1467 | 1474 | aConstraints.gridx += 1; |
---|
1468 | 1475 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1469 | | - ctrlPanel.add(textureField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
| 1476 | + ctrlPanel.add(textureField = new NumberSlider(0.001, 1, -0.5), aConstraints); |
---|
1470 | 1477 | aConstraints.gridx = 0; |
---|
1471 | 1478 | aConstraints.gridy += 1; |
---|
1472 | 1479 | aConstraints.gridwidth = 1; |
---|
.. | .. |
---|
1476 | 1483 | aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1477 | 1484 | aConstraints.gridx += 1; |
---|
1478 | 1485 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1479 | | - ctrlPanel.add(anisoField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
| 1486 | + ctrlPanel.add(anisoField = new NumberSlider(0.001, 1, -0.5), aConstraints); |
---|
1480 | 1487 | aConstraints.gridx = 0; |
---|
1481 | 1488 | aConstraints.gridy += 1; |
---|
1482 | 1489 | aConstraints.gridwidth = 1; |
---|
.. | .. |
---|
1486 | 1493 | aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1487 | 1494 | aConstraints.gridx += 1; |
---|
1488 | 1495 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1489 | | - ctrlPanel.add(anisoVField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
| 1496 | + ctrlPanel.add(anisoVField = new NumberSlider(0.001, 1, -0.5), aConstraints); |
---|
1490 | 1497 | aConstraints.gridx = 0; |
---|
1491 | 1498 | aConstraints.gridy += 1; |
---|
1492 | 1499 | aConstraints.gridwidth = 1; |
---|
.. | .. |
---|
1555 | 1562 | aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1556 | 1563 | aConstraints.gridx += 1; |
---|
1557 | 1564 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1558 | | - ctrlPanel.add(subsurfaceField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
| 1565 | + ctrlPanel.add(subsurfaceField = new NumberSlider(0.001, 1, -0.5), aConstraints); |
---|
1559 | 1566 | aConstraints.gridx = 0; |
---|
1560 | 1567 | aConstraints.gridy += 1; |
---|
1561 | 1568 | aConstraints.gridwidth = 1; |
---|
.. | .. |
---|
1624 | 1631 | aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1625 | 1632 | aConstraints.gridx += 1; |
---|
1626 | 1633 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1627 | | - ctrlPanel.add(metalnessField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
| 1634 | + ctrlPanel.add(metalnessField = new NumberSlider(0.001, 1, -0.5), aConstraints); |
---|
1628 | 1635 | aConstraints.gridx = 0; |
---|
1629 | 1636 | aConstraints.gridy += 1; |
---|
1630 | 1637 | aConstraints.gridwidth = 1; |
---|
.. | .. |
---|
1695 | 1702 | aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1696 | 1703 | aConstraints.gridx += 1; |
---|
1697 | 1704 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1698 | | - ctrlPanel.add(opacityField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
| 1705 | + ctrlPanel.add(opacityField = new NumberSlider(0.001, 1, -0.5), aConstraints); |
---|
1699 | 1706 | aConstraints.gridx = 0; |
---|
1700 | 1707 | aConstraints.gridy += 1; |
---|
1701 | 1708 | aConstraints.gridwidth = 1; |
---|
.. | .. |
---|
3549 | 3556 | //System.out.println("PARENT = " + parent); |
---|
3550 | 3557 | //if (parent != null) |
---|
3551 | 3558 | // parent.applySelf(); |
---|
3552 | | - refreshContents(); |
---|
| 3559 | + if (e.getSource() == normalpushField) |
---|
| 3560 | + { |
---|
| 3561 | + objEditor.refreshContents(); |
---|
| 3562 | + //Refresh(); |
---|
| 3563 | + } |
---|
| 3564 | + else |
---|
| 3565 | + refreshContents(); |
---|
3553 | 3566 | // ??? client.refreshEditWindow(); |
---|
3554 | 3567 | } |
---|
3555 | 3568 | //else |
---|
.. | .. |
---|
3561 | 3574 | //group.name = nameField.getText(); |
---|
3562 | 3575 | //objEditor.applySelf(); |
---|
3563 | 3576 | |
---|
3564 | | - assert (objEditor == this); |
---|
| 3577 | + // OCT2018: assert (objEditor == this); |
---|
3565 | 3578 | if (copy.selection == null || copy.selection.size() == 0) |
---|
3566 | 3579 | //super.applySelf() |
---|
3567 | 3580 | ; else |
---|
.. | .. |
---|
3585 | 3598 | objEditor.copy = keep; |
---|
3586 | 3599 | } |
---|
3587 | 3600 | } |
---|
| 3601 | + |
---|
| 3602 | + if (normalpushField != null) |
---|
| 3603 | + copy.NORMALPUSH = (float)normalpushField.getFloat()/1000; |
---|
3588 | 3604 | } |
---|
3589 | 3605 | |
---|
3590 | 3606 | void SnapObject() |
---|
.. | .. |
---|
4629 | 4645 | NumberSlider opacityPowerField; |
---|
4630 | 4646 | JTree jTree; |
---|
4631 | 4647 | //ObjectUI parent; |
---|
| 4648 | + |
---|
| 4649 | + NumberSlider normalpushField; |
---|
4632 | 4650 | } |
---|