Normand Briere
2019-05-02 a76491b66a2e304d9ae27a162f407b98c70fbafa
ObjEditor.java
....@@ -19,6 +19,8 @@
1919 import //weka.core.
2020 matrix.Matrix;
2121
22
+import grafeme.ui.*;
23
+
2224 class ObjEditor /*extends JFrame*/ implements iCallBack, ObjectUI,
2325 ActionListener, ChangeListener,
2426 InputMethodListener,
....@@ -31,6 +33,9 @@
3133 boolean timeline;
3234 boolean wasFullScreen;
3335
36
+ GroupEditor callee;
37
+ JFrame frame;
38
+
3439 // SCRIPT
3540
3641 transient JFrame textpanel = null;
....@@ -121,51 +126,61 @@
121126 void keyPressed(int key, int modifiers)
122127 {
123128 System.out.println("KEY PRESSED");
124
- CameraPane.theRenderer.keyPressed(key, modifiers);
129
+ Globals.theRenderer.keyPressed(key, modifiers);
125130 }
126131 */
127132
128133 static GridBagConstraints aConstraints;
129134 static GridBagConstraints aWindowConstraints;
130
- GroupEditor callee;
131
- JFrame frame;
135
+
132136 static int GRIDWIDTH = 100; // 4;
133137
134138 public void closeUI()
135139 {
136140 //new Exception().printStackTrace();
137
- System.out.println("this = " + this);
138
- System.out.println("objEditor = " + objEditor);
141
+// System.out.println("this = " + this);
142
+// System.out.println("objEditor = " + objEditor);
139143 //nameField.removeActionListener(this);
140
- objEditor.ctrlPanel.remove(nameField);
144
+// objEditor.ctrlPanel.remove(nameField);
145
+
146
+ objEditor.ctrlPanel.remove(namePanel);
141147
142148 if (!GroupEditor.allparams)
143149 return;
144150
145
- objEditor.ctrlPanel.remove(liveCB);
146
- objEditor.ctrlPanel.remove(hideCB);
147
- objEditor.ctrlPanel.remove(markCB);
148
-
149
- objEditor.ctrlPanel.remove(randomCB);
150
- objEditor.ctrlPanel.remove(speedupCB);
151
- objEditor.ctrlPanel.remove(rewindCB);
152
-
153
- objEditor.ctrlPanel.remove(resetButton);
154
- objEditor.ctrlPanel.remove(stepButton);
155
-// objEditor.ctrlPanel.remove(stepAllButton);
156
-// objEditor.ctrlPanel.remove(resetAllButton);
157
- objEditor.ctrlPanel.remove(link2masterCB);
158
- //objEditor.ctrlPanel.remove(flipVCB);
159
- //objEditor.ctrlPanel.remove(texresMenu);
160
- objEditor.ctrlPanel.remove(slowerButton);
161
- objEditor.ctrlPanel.remove(fasterButton);
162
- objEditor.ctrlPanel.remove(remarkButton);
151
+// objEditor.ctrlPanel.remove(liveCB);
152
+// objEditor.ctrlPanel.remove(hideCB);
153
+// objEditor.ctrlPanel.remove(markCB);
154
+//
155
+// objEditor.ctrlPanel.remove(randomCB);
156
+// objEditor.ctrlPanel.remove(speedupCB);
157
+// objEditor.ctrlPanel.remove(rewindCB);
158
+//
159
+// objEditor.ctrlPanel.remove(resetButton);
160
+// objEditor.ctrlPanel.remove(stepButton);
161
+//// objEditor.ctrlPanel.remove(stepAllButton);
162
+//// objEditor.ctrlPanel.remove(resetAllButton);
163
+// objEditor.ctrlPanel.remove(link2masterCB);
164
+// //objEditor.ctrlPanel.remove(flipVCB);
165
+// //objEditor.ctrlPanel.remove(texresMenu);
166
+// objEditor.ctrlPanel.remove(slowerButton);
167
+// objEditor.ctrlPanel.remove(fasterButton);
168
+// objEditor.ctrlPanel.remove(remarkButton);
169
+
170
+ objEditor.ctrlPanel.remove(setupPanel);
171
+ objEditor.ctrlPanel.remove(commandsPanel);
172
+ objEditor.ctrlPanel.remove(pushPanel);
173
+ //objEditor.ctrlPanel.remove(fillPanel);
174
+
175
+ //Remove(normalpushField);
163176 }
164177
165178 public ObjEditor GetEditor()
166179 {
167180 return objEditor; //.GetEditor();
168181 }
182
+
183
+ // Sometimes myself, sometimes my callee's.
169184 ObjEditor objEditor;
170185
171186 /*
....@@ -305,7 +320,7 @@
305320 toggleTextureItem.setState(CameraPane.textureon);
306321 cameraMenu.add(toggleLiveItem = new CheckboxMenuItem("Live"));
307322 toggleLiveItem.addItemListener(this);
308
- toggleLiveItem.setState(CameraPane.isLIVE());
323
+ toggleLiveItem.setState(Globals.isLIVE());
309324 cameraMenu.add(stepItem = new MenuItem("Step"));
310325 stepItem.addActionListener(this);
311326 // cameraMenu.add(toggleDLItem = new CheckboxMenuItem("Display List"));
....@@ -345,21 +360,23 @@
345360 objectPanel = new JTabbedPane();
346361 toolbarPanel = new JPanel();
347362 toolbarPanel.setName("Toolbar");
348
- treePanel = new JPanel();
363
+ treePanel = new cGridBag();
349364 treePanel.setName("Tree");
350
- ctrlPanel = new JPanel(); // new GridBagLayout());
365
+ ctrlPanel = new cGridBag().setVertical(false); // new GridBagLayout());
351366 ctrlPanel.setName("Edit");
352
- materialPanel = new JPanel();
367
+ materialPanel = new cGridBag().setVertical(true);
353368 materialPanel.setName("Material");
354369 /*JTextPane*/
355370 infoarea = createTextPane();
371
+ doc = infoarea.getStyledDocument();
372
+
356373 infoarea.setEditable(true);
357374 SetText();
358375 // infoarea.setFont(infoarea.getFont().deriveFont(10, 14f));
359376 // infoarea.setOpaque(false);
360377 // //infoarea.setForeground(textcolor);
361
- infoarea.setLineWrap(true);
362
- infoarea.setWrapStyleWord(true);
378
+// TEXTAREA infoarea.setLineWrap(true);
379
+// TEXTAREA infoarea.setWrapStyleWord(true);
363380 infoPanel = new JScrollPane(infoarea, ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED, ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); //AS_NEEDED);
364381 infoPanel.setPreferredSize(new Dimension(50, 200));
365382 infoPanel.setName("Info");
....@@ -370,16 +387,16 @@
370387 mainPanel.setName("Main");
371388 mainPanel.setContinuousLayout(true);
372389 mainPanel.setOneTouchExpandable(true);
373
- mainPanel.setDividerLocation(1.0);
374390 mainPanel.setDividerSize(9);
375
- mainPanel.setResizeWeight(0);
391
+ mainPanel.setDividerLocation(0.5); //1.0);
392
+ mainPanel.setResizeWeight(0.5);
376393
377394 //ctrlPanel.setLayout(new GridLayout(4, 1, 5, 5));
378395 //mainPanel.setLayout(new GridBagLayout());
379396 toolbarPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
380
- treePanel.setLayout(new GridBagLayout());
381
- ctrlPanel.setLayout(new GridBagLayout());
382
- materialPanel.setLayout(new GridBagLayout());
397
+// treePanel.setLayout(new GridBagLayout());
398
+ //ctrlPanel.setLayout(new GridBagLayout());
399
+ //materialPanel.setLayout(new GridBagLayout());
383400
384401 aConstraints = new GridBagConstraints(0, 0, 1, 1, 1.0, 1.0,
385402 GridBagConstraints.NORTHEAST, GridBagConstraints.BOTH, new Insets(1, 1, 1, 1), 0, 0);
....@@ -418,7 +435,7 @@
418435 static String newline = "\n";
419436 protected static final String buttonString = "JButton";
420437 StyledDocument doc;
421
- JTextArea infoarea;
438
+ JTextPane infoarea;
422439
423440 void ClearInfo()
424441 {
....@@ -485,7 +502,10 @@
485502 }
486503
487504 if (full)
488
- si.SendInfo(" BBox: " + minima + " - " + maxima, "regular");
505
+ {
506
+ si.SendInfo(" BBox min: " + minima, "regular");
507
+ si.SendInfo(" BBox max: " + maxima, "regular");
508
+ }
489509
490510 if (sel.bRep != null)
491511 {
....@@ -583,6 +603,9 @@
583603 {
584604 CameraPane.pointflow = (PointFlow) sel;
585605 }
606
+
607
+ si.SendInfo("_____________________", "regular");
608
+ si.SendInfo("", "regular");
586609 }
587610 }
588611
....@@ -614,52 +637,52 @@
614637 cameraView.ToggleFullScreen();
615638 }
616639
617
- private JTextArea createTextPane()
640
+ private JTextPane createTextPane()
618641 {
619
- String[] initString =
620
- {
621
- "This is an editable JTextPane, ", //regular
622
- "another ", //italic
623
- "styled ", //bold
624
- "text ", //small
625
- "component, ", //large
626
- "which supports embedded components..." + newline,//regular
627
- " " + newline, //button
628
- "...and embedded icons..." + newline, //regular
629
- " ", //icon
630
- newline + "JTextPane is a subclass of JEditorPane that "
631
- + "uses a StyledEditorKit and StyledDocument, and provides "
632
- + "cover methods for interacting with those objects."
633
- };
642
+// TEXTAREA String[] initString =
643
+// {
644
+// "This is an editable JTextPane, ", //regular
645
+// "another ", //italic
646
+// "styled ", //bold
647
+// "text ", //small
648
+// "component, ", //large
649
+// "which supports embedded components..." + newline,//regular
650
+// " " + newline, //button
651
+// "...and embedded icons..." + newline, //regular
652
+// " ", //icon
653
+// newline + "JTextPane is a subclass of JEditorPane that "
654
+// + "uses a StyledEditorKit and StyledDocument, and provides "
655
+// + "cover methods for interacting with those objects."
656
+// };
657
+//
658
+// String[] initStyles =
659
+// {
660
+// "regular", "italic", "bold", "small", "large",
661
+// "regular", "button", "regular", "icon",
662
+// "regular"
663
+// };
664
+//
665
+// JTextPane textPane = new JTextPane();
666
+// textPane.setEditable(true);
667
+// /*StyledDocument*/ doc = textPane.getStyledDocument();
668
+// addStylesToDocument(doc);
669
+//
670
+// try
671
+// {
672
+// for (int j = 0; j < 2; j++)
673
+// {
674
+// for (int i = 0; i < initString.length; i++)
675
+// {
676
+// doc.insertString(doc.getLength(), initString[i],
677
+// doc.getStyle(initStyles[i]));
678
+// }
679
+// }
680
+// } catch (BadLocationException ble)
681
+// {
682
+// System.err.println("Couldn't insert initial text into text pane.");
683
+// }
634684
635
- String[] initStyles =
636
- {
637
- "regular", "italic", "bold", "small", "large",
638
- "regular", "button", "regular", "icon",
639
- "regular"
640
- };
641
-
642
- JTextPane textPane = new JTextPane();
643
- textPane.setEditable(true);
644
- /*StyledDocument*/ doc = textPane.getStyledDocument();
645
- addStylesToDocument(doc);
646
-
647
- try
648
- {
649
- for (int j = 0; j < 2; j++)
650
- {
651
- for (int i = 0; i < initString.length; i++)
652
- {
653
- doc.insertString(doc.getLength(), initString[i],
654
- doc.getStyle(initStyles[i]));
655
- }
656
- }
657
- } catch (BadLocationException ble)
658
- {
659
- System.err.println("Couldn't insert initial text into text pane.");
660
- }
661
-
662
- return new JTextArea(); // textPane;
685
+ return new JTextPane(); // textPane;
663686 }
664687
665688 protected void addStylesToDocument(StyledDocument doc)
....@@ -759,115 +782,83 @@
759782 JButton slowerButton;
760783 JButton fasterButton;
761784 JButton remarkButton;
785
+
786
+ cGridBag namePanel;
787
+ cGridBag setupPanel;
788
+ cGridBag commandsPanel;
789
+ cGridBag pushPanel;
790
+ cGridBag fillPanel;
762791
763
- JCheckBox AddCheckBox(ObjEditor oe, String label, boolean on)
792
+ JCheckBox AddCheckBox(cGridBag panel, String label, boolean on)
764793 {
765794 JCheckBox cb;
766795
767
- oe.aConstraints.fill = GridBagConstraints.HORIZONTAL;
768
- oe.aConstraints.gridwidth = 1; // 3;
769
-// oe.aConstraints.weightx = 1;
770
-// oe.aConstraints.anchor = GridBagConstraints.WEST;
771
- oe.ctrlPanel.add(cb = new JCheckBox(label, on), oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
796
+ panel.add(cb = new JCheckBox(label, on)); //, oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
772797 cb.addItemListener(this);
773
-// oe.aConstraints.anchor = GridBagConstraints.EAST;
774
- oe.aConstraints.gridwidth = 1;
775
- oe.aConstraints.gridx += 1;
776798
777799 return cb;
778800 }
779801
780
- cButton AddButton(ObjEditor oe, String label)
802
+ cButton AddButton(cGridBag panel, String label)
781803 {
782804 cButton cb;
783805
784
- oe.aConstraints.fill = GridBagConstraints.HORIZONTAL;
785
- oe.aConstraints.gridwidth = 1;
786
-// oe.aConstraints.weightx = 1;
787
-// oe.aConstraints.anchor = GridBagConstraints.WEST;
788
- oe.ctrlPanel.add(cb = new cButton(label), oe.aConstraints, oe.ctrlPanel.getComponentCount() - 1);
806
+ panel.add(cb = new cButton(label)); //, oe.aConstraints, oe.ctrlPanel.getComponentCount() - 1);
789807 cb.addActionListener(this);
790
-// oe.aConstraints.anchor = GridBagConstraints.EAST;
791
- oe.aConstraints.gridwidth = 1;
792
- oe.aConstraints.gridx += 1;
793808
794809 return cb;
795810 }
796811
797
- JComboBox AddCombo(ObjEditor oe, java.util.Vector list, int item)
812
+ JComboBox AddCombo(cGridBag panel, java.util.Vector list, int item)
798813 {
799814 JComboBox combo;
800815
801
- oe.aConstraints.fill = GridBagConstraints.HORIZONTAL;
802
- oe.ctrlPanel.add(combo = new JComboBox(new cListModel(list, item)), oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
803
- oe.aConstraints.gridx += 1;
816
+ panel.add(combo = new JComboBox(new cListModel(list, item))); //, oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
804817 combo.addActionListener(this);
805818
806819 return combo;
807820 }
808821
809
- NumberSlider AddSlider(JPanel ctrlPanel, String label, double min, double max, double current, double pow)
822
+ cGridBag AddSlider(cGridBag panel, String label, double min, double max, double current, double pow)
810823 {
811
- NumberSlider combo;
824
+ cGridBag control = new cGridBag();
825
+
826
+ cNumberSlider combo;
812827
813828 JLabel jlabel = new JLabel(label);
814
-
815
- aConstraints.fill = GridBagConstraints.VERTICAL;
816829 jlabel.setHorizontalAlignment(SwingConstants.TRAILING);
817
- aConstraints.gridwidth = 2;
818
- ctrlPanel.add(jlabel, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
819
- aConstraints.gridx += 1;
820
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
821
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
822
- ctrlPanel.add(combo = new NumberSlider(min, max, pow), aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
823
- aConstraints.gridx += 1;
824
- aConstraints.gridwidth = 1;
825
-
830
+ control.add(jlabel); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
831
+ control.add(combo = new cNumberSlider(this, min, max, pow)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
826832 combo.setFloat(current);
827
-
828
- combo.label = jlabel;
829
-
830
- combo.addChangeListener(this);
831
-
832
- return combo;
833
+
834
+ panel.add(control);
835
+
836
+ return control;
833837 }
834838
835
- NumberSlider AddSlider(JPanel ctrlPanel, String label, int min, int max, int current)
839
+ cGridBag AddSlider(cGridBag panel, String label, int min, int max, int current)
836840 {
837
- NumberSlider combo;
841
+ cGridBag control = new cGridBag();
842
+
843
+ cNumberSlider combo;
838844
839845 JLabel jlabel = new JLabel(label);
840
-
841
- aConstraints.fill = GridBagConstraints.VERTICAL;
842846 jlabel.setHorizontalAlignment(SwingConstants.TRAILING);
843
- aConstraints.gridwidth = 2;
844
- ctrlPanel.add(jlabel, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
845
- aConstraints.gridx += 1;
846
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
847
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
848
- ctrlPanel.add(combo = new NumberSlider(min, max), aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
849
- aConstraints.gridx += 1;
850
- aConstraints.gridwidth = 1;
851
-
847
+ control.add(jlabel); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
848
+ control.add(combo = new cNumberSlider(this, min, max)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
852849 combo.setInteger(current);
853850
854
- combo.label = jlabel;
855
-
856
- combo.addChangeListener(this);
857
-
858
- return combo;
851
+ panel.add(control);
852
+
853
+ return control;
859854 }
860855
861
- JTextArea AddText(JPanel ctrlPanel, String name)
856
+ JTextArea AddText(cGridBag ctrlPanel, String name)
862857 {
863858 JTextArea text;
864859
865
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
866
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
867
- ctrlPanel.add(text = new JTextArea(name), aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
860
+ ctrlPanel.add(text = new JTextArea(name)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
868861 text.addCaretListener(this);
869
- aConstraints.gridx += 1;
870
- aConstraints.gridwidth = 1;
871862
872863 return text;
873864 }
....@@ -897,9 +888,16 @@
897888 objEditor.ctrlPanel.remove(j);
898889 }
899890
891
+ void Remove(cNumberSlider j)
892
+ {
893
+ j.removeChangeListener(this);
894
+ //objEditor.ctrlPanel.remove(j.label);
895
+ objEditor.ctrlPanel.remove(j);
896
+ }
897
+
900898 /*
901899 */
902
- void Return() // ObjEditor oe)
900
+ void Return0() // ObjEditor oe)
903901 {
904902 aConstraints.gridy += 1;
905903 aConstraints.gridx = 0;
....@@ -954,35 +952,71 @@
954952
955953 void SetupUI2(ObjEditor oe)
956954 {
957
-// oe.aConstraints.weightx = 0;
958
-// oe.aConstraints.weighty = 0;
959
-// oe.aConstraints.gridx = 0;
960
-// oe.aConstraints.gridy = 0;
961
- SetupName(oe);
955
+ //SetupName(oe);
956
+
957
+ namePanel = new cGridBag();
958
+
959
+ nameField = AddText(namePanel, copy.GetName());
960
+ namePanel.add(nameField);
961
+ oe.ctrlPanel.add(namePanel);
962
+
963
+ oe.ctrlPanel.Return();
962964
963965 if (!GroupEditor.allparams)
964966 return;
965967
966
- liveCB = AddCheckBox(oe, "Live", copy.live);
967
- link2masterCB = AddCheckBox(oe, "Supp", copy.link2master);
968
- hideCB = AddCheckBox(oe, "Hide", copy.hide);
968
+ setupPanel = new cGridBag().setVertical(false);
969
+
970
+ liveCB = AddCheckBox(setupPanel, "Live", copy.live);
971
+ liveCB.setToolTipText("Animate object");
972
+ hideCB = AddCheckBox(setupPanel, "Hide", copy.hide);
973
+ hideCB.setToolTipText("Hide object");
969974 // Return();
970
- markCB = AddCheckBox(oe, "Mark", copy.marked);
971
- rewindCB = AddCheckBox(oe, "Rew", copy.rewind);
972
- randomCB = AddCheckBox(oe, "Rand", copy.random);
973
- Return();
974
- resetButton = AddButton(oe, "Reset");
975
- stepButton = AddButton(oe, "Step");
975
+ markCB = AddCheckBox(setupPanel, "Mark", copy.marked);
976
+ markCB.setToolTipText("Set the animation target transform");
977
+
978
+ rewindCB = AddCheckBox(setupPanel, "Rewind", copy.rewind);
979
+ rewindCB.setToolTipText("Rewind animation");
980
+
981
+ randomCB = AddCheckBox(setupPanel, "Random", copy.random);
982
+ randomCB.setToolTipText("Option for switch node");
983
+
984
+ if (Globals.ADVANCED)
985
+ {
986
+ link2masterCB = AddCheckBox(setupPanel, "Support", copy.link2master);
987
+ link2masterCB.setToolTipText("Attach to support");
988
+ speedupCB = AddCheckBox(setupPanel, "Speed", copy.speedup);
989
+ speedupCB.setToolTipText("Option motion capture");
990
+ }
991
+
992
+ oe.ctrlPanel.add(setupPanel);
993
+ oe.ctrlPanel.Return();
994
+
995
+ commandsPanel = new cGridBag().setVertical(false);
996
+
997
+ resetButton = AddButton(commandsPanel, "Reset");
998
+ resetButton.setToolTipText("Jump to frame zero");
999
+ stepButton = AddButton(commandsPanel, "Step");
1000
+ stepButton.setToolTipText("Step one frame");
9761001 // resetAllButton = AddButton(oe, "Reset All");
9771002 // stepAllButton = AddButton(oe, "Step All");
978
- speedupCB = AddCheckBox(oe, "Speed", copy.speedup);
9791003 // Return();
980
- slowerButton = AddButton(oe, "Slow");
981
- fasterButton = AddButton(oe, "Fast");
982
- remarkButton = AddButton(oe, "Rem");
1004
+ slowerButton = AddButton(commandsPanel, "Slow");
1005
+ slowerButton.setToolTipText("Decrease animation speed");
1006
+ fasterButton = AddButton(commandsPanel, "Fast");
1007
+ fasterButton.setToolTipText("Increase animation speed");
1008
+ remarkButton = AddButton(commandsPanel, "Remark");
1009
+ remarkButton.setToolTipText("Set the current transform as the target");
9831010
984
- Return();
1011
+ oe.ctrlPanel.add(commandsPanel);
1012
+ oe.ctrlPanel.Return();
9851013
1014
+ pushPanel = AddSlider(oe.ctrlPanel, "Push", -10, 10, 0, 1);
1015
+ normalpushField = (cNumberSlider)pushPanel.getComponent(1);
1016
+ //Return();
1017
+
1018
+ oe.ctrlPanel.Return();
1019
+
9861020 // oe.ctrlPanel.add(stepButton = new cButton("Step"), ObjEditor.aConstraints, oe.ctrlPanel.getComponentCount() - 2);
9871021 // ObjEditor.aConstraints.gridx += 1;
9881022
....@@ -1076,7 +1110,7 @@
10761110 oe.aConstraints.gridwidth = 1;
10771111 /**/
10781112 nameField = AddText(oe.ctrlPanel, copy.GetName());
1079
- Return();
1113
+ oe.ctrlPanel.Return();
10801114
10811115 //ctrlPanel.add(textureButton = new Button("Texture..."));
10821116 //textureButton.setEnabled(false);
....@@ -1178,10 +1212,18 @@
11781212 //JPanel worldPanel =
11791213 // new gov.nasa.worldwind.examples.ApplicationTemplate.AppPanel(null, true);
11801214 //worldPanel.setName("World");
1181
- centralPanel = new JPanel(new BorderLayout());
1215
+ centralPanel = new cGridBag();
1216
+ centralPanel.preferredWidth = 20;
11821217 timelinePanel = new JPanel(new BorderLayout());
11831218 timelineMenubar = new timeflow.app.TimeflowApp().TimeFlowWindow(timelinePanel);
11841219
1220
+ cameraPanel = new JSplitPane(JSplitPane.VERTICAL_SPLIT, cameraView, timelinePanel);
1221
+ cameraPanel.setContinuousLayout(true);
1222
+ cameraPanel.setOneTouchExpandable(true);
1223
+// cameraPanel.setDividerLocation(0.9);
1224
+// cameraPanel.setDividerSize(9);
1225
+ cameraPanel.setResizeWeight(1.0);
1226
+
11851227 centralPanel.add(cameraView);
11861228 //frame.setJMenuBar(timelineMenubar);
11871229 //centralPanel.add(timelinePanel);
....@@ -1201,12 +1243,13 @@
12011243 //frontView.object = copy;
12021244 //sideView.object = copy;
12031245
1204
- XYZPanel = new JPanel();
1205
- XYZPanel.setLayout(new GridLayout(3, 1, 5, 5));
1246
+ XYZPanel = new cGridBag().setVertical(true);
1247
+ //XYZPanel.setLayout(new GridLayout(3, 1, 5, 5));
12061248
1207
- XYZPanel.add(/*BorderLayout.SOUTH,*/sideView); // Scroll);
1208
- XYZPanel.add(/*BorderLayout.CENTER,*/frontView); // Scroll);
1209
- XYZPanel.add(/*BorderLayout.NORTH,*/topView); // Scroll);
1249
+ XYZPanel.preferredWidth = 5;
1250
+ XYZPanel.addComponent(/*BorderLayout.SOUTH,*/sideView); // Scroll);
1251
+ XYZPanel.addComponent(/*BorderLayout.CENTER,*/frontView); // Scroll);
1252
+ XYZPanel.addComponent(/*BorderLayout.NORTH,*/topView); // Scroll);
12101253
12111254 /*
12121255 gridPanel = new JPanel(); //new BorderLayout());
....@@ -1244,10 +1287,11 @@
12441287 //JScrollPane tmp = new JScrollPane(ctrlPanel, ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED, ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
12451288 //tmp.setName("Edit");
12461289 objectPanel.add(materialPanel);
1247
- JPanel north = new JPanel(new BorderLayout());
1248
- north.setName("Edit");
1249
- north.add(ctrlPanel, BorderLayout.NORTH);
1250
- objectPanel.add(north);
1290
+// JPanel north = new JPanel(new BorderLayout());
1291
+// north.setName("Edit");
1292
+// north.add(ctrlPanel, BorderLayout.NORTH);
1293
+// objectPanel.add(north);
1294
+ objectPanel.add(ctrlPanel);
12511295 objectPanel.add(infoPanel);
12521296
12531297 /*
....@@ -1268,16 +1312,23 @@
12681312 scrollpane.setWheelScrollingEnabled(true);
12691313 scrollpane.addMouseWheelListener(this); // Default not fast enough
12701314
1271
- /*JTabbedPane*/ scenePanel = new JTabbedPane();
1272
- scenePanel.add(scrollpane);
1315
+ /*JTabbedPane*/ scenePanel = new cGridBag();
1316
+ scenePanel.preferredWidth = 7;
1317
+
1318
+ JTabbedPane tabbedPane = new JTabbedPane();
1319
+ tabbedPane.add(scrollpane);
12731320
1274
- scenePanel.add(FSPane = new cFileSystemPane(this));
1321
+ tabbedPane.add(FSPane = new cFileSystemPane(this));
12751322
1276
- optionsPanel = new JPanel(new GridBagLayout());
1323
+ optionsPanel = new cGridBag().setVertical(true);
12771324
12781325 optionsPanel.setName("Options");
1279
- scenePanel.add(optionsPanel);
1280
-
1326
+
1327
+ AddOptions(optionsPanel); //, aConstraints);
1328
+
1329
+ tabbedPane.add(optionsPanel);
1330
+
1331
+ scenePanel.add(tabbedPane);
12811332
12821333 /*
12831334 cTree jTree = new cTree(null);
....@@ -1311,6 +1362,7 @@
13111362 //bigPanel.setSize(new Dimension(10,10));
13121363 //bigPanel.add(ctrlPanel);
13131364 //bigPanel.add(gridPanel);
1365
+ /**
13141366 bigThree = new JPanel();
13151367 //big.setLayout(new FlowLayout(FlowLayout.LEFT));
13161368 bigThree.setLayout(new GridBagLayout()); //1,3,5,5));
....@@ -1334,7 +1386,13 @@
13341386 // aConstraints.gridheight = 3;
13351387 aWindowConstraints.fill = GridBagConstraints.VERTICAL;
13361388 bigThree.add(XYZPanel, aWindowConstraints);
1389
+ /**/
13371390
1391
+ bigThree = new cGridBag();
1392
+ bigThree.addComponent(scenePanel);
1393
+ bigThree.addComponent(centralPanel);
1394
+ bigThree.addComponent(XYZPanel);
1395
+
13381396 // // SIDE EFFECT!!!
13391397 // aConstraints.gridx = 0;
13401398 // aConstraints.gridy = 0;
....@@ -1355,7 +1413,8 @@
13551413 //worldPane.add(bigPanel);
13561414 //worldPane.add(worldPanel);
13571415 /**/
1358
- frame.getContentPane().add(/*"Center",*/framePanel);
1416
+ //frame.getContentPane().add(/*"Center",*/framePanel);
1417
+ frame.add(/*"Center",*/framePanel);
13591418 //frame.getContentPane().add(/*"Center",*/ worldPane);
13601419
13611420 // aConstraints = gbc; // (GridBagConstraints) GrafreeD.clone(gbc);
....@@ -1376,6 +1435,10 @@
13761435 });
13771436 }
13781437
1438
+ void AddOptions(cGridBag panel) //, GridBagConstraints constraints)
1439
+ {
1440
+ }
1441
+
13791442 JTree GetTree()
13801443 {
13811444 return objEditor.jTree;
....@@ -1387,260 +1450,170 @@
13871450 ctrlPanel.removeAll();
13881451 }
13891452
1390
- void SetupMaterial(JPanel ctrlPanel)
1453
+ void SetupMaterial(cGridBag panel)
13911454 {
1392
- aConstraints.weighty = 0;
1393
- //aConstraints.weightx = 1;
1394
- /*
1455
+ /*
13951456 ctrlPanel.add(materialLabel = new JLabel("MATERIAL : "), aConstraints);
13961457 materialLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1397
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1398
- aConstraints.gridx += 1;
13991458 */
14001459
1401
- aConstraints.gridwidth = 1;
1402
- ctrlPanel.add(createMaterialButton = new cButton("Create"), aConstraints);
1403
- aConstraints.gridx += 1;
1404
- aConstraints.weighty = 0;
1405
- aConstraints.gridwidth = 1;
1460
+ cGridBag editBar = new cGridBag().setVertical(false);
1461
+
1462
+ editBar.add(createMaterialButton = new cButton("Create", !GrafreeD.NIMBUSLAF)); // , aConstraints);
1463
+ createMaterialButton.setToolTipText("Create material");
14061464
14071465 /*
14081466 ctrlPanel.add(resetSlidersButton = new cButton("Reset All"), aConstraints);
1409
- aConstraints.gridx += 1;
1410
- aConstraints.weighty = 0;
1411
- aConstraints.gridwidth = 1;
14121467 */
14131468
1414
- ctrlPanel.add(clearMaterialButton = new cButton("Clear"), aConstraints);
1415
- aConstraints.gridx += 1;
1469
+ editBar.add(clearMaterialButton = new cButton("Clear", !GrafreeD.NIMBUSLAF)); // , aConstraints);
1470
+ clearMaterialButton.setToolTipText("Clear material");
1471
+
1472
+ editBar.add(resetSlidersButton = new cButton("Reset", !GrafreeD.NIMBUSLAF)); // , aConstraints);
1473
+ editBar.add(propagateToggle = new cCheckBox("Prop", propagate)); // , aConstraints);
1474
+ editBar.add(multiplyToggle = new cCheckBox("Mult", false)); // , aConstraints);
14161475
1417
- ctrlPanel.add(resetSlidersButton = new cButton("Reset"), aConstraints);
1418
-
1419
- aConstraints.gridx += 1;
1420
-
1421
- ctrlPanel.add(propagateToggle = new cCheckBox("Prop", propagate), aConstraints);
1422
-
1423
- aConstraints.gridx += 1;
1424
-
1425
- ctrlPanel.add(multiplyToggle = new cCheckBox("Mult", false), aConstraints);
1426
-
1427
- aConstraints.gridx = 0;
1428
- aConstraints.gridy += 1;
1429
- aConstraints.weighty = 0;
1430
- aConstraints.gridwidth = 1;
1476
+ editBar.preferredHeight = 15;
1477
+
1478
+ panel.add(editBar);
1479
+
14311480 /**/
14321481 //aConstraints.weighty = 0;
14331482 ////aConstraints.weightx = 1;
14341483 //aConstraints.weighty = 1;
14351484 aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100;
14361485 //aConstraints.gridx += 1;
1437
- ctrlPanel.add(new JLabel("----------------------------------"), aConstraints);
1438
- aConstraints.weighty = 0;
1439
- aConstraints.gridx = 0;
1440
- aConstraints.gridy += 1;
1441
- aConstraints.gridwidth = 1;
1486
+ //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
14421487
1443
- ctrlPanel.add(colorLabel = new JLabel("Color/hue"), aConstraints);
1444
- colorLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1445
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1446
- aConstraints.gridx += 1;
1447
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1448
- //aConstraints.weightx = 0;
1449
- ctrlPanel.add(colorField = new NumberSlider(0.001, 1, -0.1), aConstraints);
1450
- aConstraints.gridx = 0;
1451
- aConstraints.gridy += 1;
1452
- aConstraints.gridwidth = 1;
1488
+ cGridBag colorSection = new cGridBag().setVertical(true);
1489
+
1490
+ cGridBag color = new cGridBag();
1491
+ color.add(colorLabel = new JLabel("Color/hue")); // , aConstraints);
1492
+ colorLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1493
+ color.add(colorField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
1494
+ //colorField.preferredWidth = 200;
1495
+ colorSection.add(color);
14531496
1454
- ctrlPanel.add(modulationLabel = new JLabel("Saturation"), aConstraints);
1455
- modulationLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1456
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1457
- aConstraints.gridx += 1;
1458
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1459
- ctrlPanel.add(modulationField = new NumberSlider(0.001, 1, -0.1), aConstraints);
1460
- aConstraints.gridx = 0;
1461
- aConstraints.gridy += 1;
1462
- aConstraints.gridwidth = 1;
1497
+ cGridBag modulation = new cGridBag();
1498
+ modulation.add(modulationLabel = new JLabel("Saturation")); // , aConstraints);
1499
+ modulationLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1500
+ modulation.add(modulationField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
1501
+ colorSection.add(modulation);
14631502
1464
- ctrlPanel.add(textureLabel = new JLabel("Texture"), aConstraints);
1465
- textureLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1466
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1467
- aConstraints.gridx += 1;
1468
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1469
- ctrlPanel.add(textureField = new NumberSlider(0.001, 1, -0.1), aConstraints);
1470
- aConstraints.gridx = 0;
1471
- aConstraints.gridy += 1;
1472
- aConstraints.gridwidth = 1;
1503
+ cGridBag texture = new cGridBag();
1504
+ texture.add(textureLabel = new JLabel("Texture")); // , aConstraints);
1505
+ textureLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1506
+ texture.add(textureField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
1507
+ colorSection.add(texture);
14731508
1474
- ctrlPanel.add(anisoLabel = new JLabel("AnisoU"), aConstraints);
1475
- anisoLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1476
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1477
- aConstraints.gridx += 1;
1478
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1479
- ctrlPanel.add(anisoField = new NumberSlider(0.001, 1, -0.1), aConstraints);
1480
- aConstraints.gridx = 0;
1481
- aConstraints.gridy += 1;
1482
- aConstraints.gridwidth = 1;
1509
+ cGridBag anisoU = new cGridBag();
1510
+ anisoU.add(anisoLabel = new JLabel("AnisoU")); // , aConstraints);
1511
+ anisoLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1512
+ anisoU.add(anisoField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
1513
+ colorSection.add(anisoU);
14831514
1484
- ctrlPanel.add(anisoVLabel = new JLabel("AnisoV"), aConstraints);
1485
- anisoVLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1486
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1487
- aConstraints.gridx += 1;
1488
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1489
- ctrlPanel.add(anisoVField = new NumberSlider(0.001, 1, -0.1), aConstraints);
1490
- aConstraints.gridx = 0;
1491
- aConstraints.gridy += 1;
1492
- aConstraints.gridwidth = 1;
1515
+ cGridBag anisoV = new cGridBag();
1516
+ anisoV.add(anisoVLabel = new JLabel("AnisoV")); // , aConstraints);
1517
+ anisoVLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1518
+ anisoV.add(anisoVField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
1519
+ colorSection.add(anisoV);
14931520
1494
- ctrlPanel.add(shadowbiasLabel = new JLabel("Shadowbias"), aConstraints);
1495
- shadowbiasLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1496
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1497
- aConstraints.gridx += 1;
1498
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1499
- ctrlPanel.add(shadowbiasField = new NumberSlider(0.001, 50, -1), aConstraints);
1500
- aConstraints.gridx = 0;
1501
- aConstraints.gridy += 1;
1502
- aConstraints.gridwidth = 1;
1521
+ cGridBag shadowbias = new cGridBag();
1522
+ shadowbias.add(shadowbiasLabel = new JLabel("Shadowbias")); // , aConstraints);
1523
+ shadowbiasLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1524
+ shadowbias.add(shadowbiasField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1525
+ colorSection.add(shadowbias);
15031526
1504
- //aConstraints.weighty = 1;
1505
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100;
1506
- //aConstraints.gridx += 1;
1507
- ctrlPanel.add(new JLabel("----------------------------------"), aConstraints);
1508
- aConstraints.weighty = 0;
1509
- aConstraints.gridx = 0;
1510
- aConstraints.gridy += 1;
1511
- aConstraints.gridwidth = 1;
1527
+ panel.add(new JSeparator());
1528
+
1529
+ panel.add(colorSection);
1530
+
1531
+ //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
1532
+
1533
+ cGridBag diffuseSection = new cGridBag().setVertical(true);
1534
+
1535
+ cGridBag diffuse = new cGridBag();
1536
+ diffuse.add(diffuseLabel = new JLabel("Diffuse")); // , aConstraints);
1537
+ diffuseLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1538
+ diffuse.add(diffuseField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1539
+ diffuseSection.add(diffuse);
15121540
1513
- ctrlPanel.add(diffuseLabel = new JLabel("Diffuse"), aConstraints);
1514
- diffuseLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1515
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1516
- aConstraints.gridx += 1;
1517
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1518
- ctrlPanel.add(diffuseField = new NumberSlider(0.001, 50, -1), aConstraints);
1519
- aConstraints.gridx = 0;
1520
- aConstraints.gridy += 1;
1521
- aConstraints.gridwidth = 1;
1541
+ cGridBag diffuseness = new cGridBag();
1542
+ diffuseness.add(diffusenessLabel = new JLabel("Diffusion")); // , aConstraints);
1543
+ diffusenessLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1544
+ diffuseness.add(diffusenessField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1545
+ diffuseSection.add(diffuseness);
15221546
1523
- ctrlPanel.add(diffusenessLabel = new JLabel("Diffusion"), aConstraints);
1524
- diffusenessLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1525
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1526
- aConstraints.gridx += 1;
1527
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1528
- ctrlPanel.add(diffusenessField = new NumberSlider(0.001, 50, -1), aConstraints);
1529
- aConstraints.gridx = 0;
1530
- aConstraints.gridy += 1;
1531
- aConstraints.gridwidth = 1;
1547
+ cGridBag selfshadow = new cGridBag();
1548
+ selfshadow.add(selfshadowLabel = new JLabel("Selfshadow")); // , aConstraints);
1549
+ selfshadowLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1550
+ selfshadow.add(selfshadowField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1551
+ diffuseSection.add(selfshadow);
15321552
1533
- ctrlPanel.add(selfshadowLabel = new JLabel("Selfshadow"), aConstraints);
1534
- selfshadowLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1535
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1536
- aConstraints.gridx += 1;
1537
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1538
- ctrlPanel.add(selfshadowField = new NumberSlider(0.001, 50, -1), aConstraints);
1539
- aConstraints.gridx = 0;
1540
- aConstraints.gridy += 1;
1541
- aConstraints.gridwidth = 1;
1553
+ cGridBag sheen = new cGridBag();
1554
+ sheen.add(sheenLabel = new JLabel("Sheen")); // , aConstraints);
1555
+ sheenLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1556
+ sheen.add(sheenField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1557
+ diffuseSection.add(sheen);
15421558
1543
- ctrlPanel.add(sheenLabel = new JLabel("Sheen"), aConstraints);
1544
- sheenLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1545
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1546
- aConstraints.gridx += 1;
1547
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1548
- ctrlPanel.add(sheenField = new NumberSlider(0.001, 50, -1), aConstraints);
1549
- aConstraints.gridx = 0;
1550
- aConstraints.gridy += 1;
1551
- aConstraints.gridwidth = 1;
1559
+ cGridBag subsurface = new cGridBag();
1560
+ subsurface.add(subsurfaceLabel = new JLabel("Subsurface")); // , aConstraints);
1561
+ subsurfaceLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1562
+ subsurface.add(subsurfaceField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
1563
+ diffuseSection.add(subsurface);
15521564
1553
- ctrlPanel.add(subsurfaceLabel = new JLabel("Subsurface"), aConstraints);
1554
- subsurfaceLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1555
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1556
- aConstraints.gridx += 1;
1557
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1558
- ctrlPanel.add(subsurfaceField = new NumberSlider(0.001, 1, -0.1), aConstraints);
1559
- aConstraints.gridx = 0;
1560
- aConstraints.gridy += 1;
1561
- aConstraints.gridwidth = 1;
1565
+ cGridBag shadow = new cGridBag();
1566
+ shadow.add(shadowLabel = new JLabel("Shadowing")); // , aConstraints);
1567
+ shadowLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1568
+ shadow.add(shadowField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1569
+ diffuseSection.add(shadow);
15621570
1563
- ctrlPanel.add(shadowLabel = new JLabel("Shadowing"), aConstraints);
1564
- shadowLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1565
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1566
- aConstraints.gridx += 1;
1567
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1568
- ctrlPanel.add(shadowField = new NumberSlider(0.001, 50, -1), aConstraints);
1569
- aConstraints.gridx = 0;
1570
- aConstraints.gridy += 1;
1571
- aConstraints.gridwidth = 1;
1571
+ cGridBag fakedepth = new cGridBag();
1572
+ fakedepth.add(fakedepthLabel = new JLabel("Fakedepth")); // , aConstraints);
1573
+ fakedepthLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1574
+ fakedepth.add(fakedepthField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1575
+ diffuseSection.add(fakedepth);
15721576
1573
- ctrlPanel.add(fakedepthLabel = new JLabel("Fakedepth"), aConstraints);
1574
- fakedepthLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1575
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1576
- aConstraints.gridx += 1;
1577
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1578
- ctrlPanel.add(fakedepthField = new NumberSlider(0.001, 50, -1), aConstraints);
1579
- aConstraints.gridx = 0;
1580
- aConstraints.gridy += 1;
1581
- aConstraints.gridwidth = 1;
1577
+ panel.add(new JSeparator());
1578
+
1579
+ panel.add(diffuseSection);
1580
+
1581
+ //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
1582
+
1583
+ cGridBag specularSection = new cGridBag().setVertical(true);
15821584
1583
- //aConstraints.weighty = 1;
1584
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100;
1585
- //aConstraints.gridx += 1;
1586
- ctrlPanel.add(new JLabel("----------------------------------"), aConstraints);
1587
- aConstraints.weighty = 0;
1588
- aConstraints.gridx = 0;
1589
- aConstraints.gridy += 1;
1590
- aConstraints.gridwidth = 1;
1585
+ cGridBag specular = new cGridBag();
1586
+ specular.add(specularLabel = new JLabel("Specular")); // , aConstraints);
1587
+ specularLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1588
+ specular.add(specularField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1589
+ specularSection.add(specular);
15911590
1592
- ctrlPanel.add(specularLabel = new JLabel("Specular"), aConstraints);
1593
- specularLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1594
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1595
- aConstraints.gridx += 1;
1596
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1597
- ctrlPanel.add(specularField = new NumberSlider(0.001, 50, -1), aConstraints);
1598
- aConstraints.gridx = 0;
1599
- aConstraints.gridy += 1;
1600
- aConstraints.gridwidth = 1;
1591
+ cGridBag lightarea = new cGridBag();
1592
+ lightarea.add(lightareaLabel = new JLabel("Lightarea")); // , aConstraints);
1593
+ lightareaLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1594
+ lightarea.add(lightareaField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1595
+ specularSection.add(lightarea);
16011596
1602
- ctrlPanel.add(lightareaLabel = new JLabel("Lightarea"), aConstraints);
1603
- lightareaLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1604
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1605
- aConstraints.gridx += 1;
1606
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1607
- ctrlPanel.add(lightareaField = new NumberSlider(0.001, 50, -1), aConstraints);
1608
- aConstraints.gridx = 0;
1609
- aConstraints.gridy += 1;
1610
- aConstraints.gridwidth = 1;
1597
+ cGridBag shininess = new cGridBag();
1598
+ shininess.add(shininessLabel = new JLabel("Roughness")); // , aConstraints);
1599
+ shininessLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1600
+ shininess.add(shininessField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1601
+ specularSection.add(shininess);
16111602
1612
- ctrlPanel.add(shininessLabel = new JLabel("Roughness"), aConstraints);
1613
- shininessLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1614
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1615
- aConstraints.gridx += 1;
1616
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1617
- ctrlPanel.add(shininessField = new NumberSlider(0.001, 50, -1), aConstraints);
1618
- aConstraints.gridx = 0;
1619
- aConstraints.gridy += 1;
1620
- aConstraints.gridwidth = 1;
1603
+ cGridBag metalness = new cGridBag();
1604
+ metalness.add(metalnessLabel = new JLabel("Metalness")); // , aConstraints);
1605
+ metalnessLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1606
+ metalness.add(metalnessField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
1607
+ specularSection.add(metalness);
16211608
1622
- ctrlPanel.add(metalnessLabel = new JLabel("Metalness"), aConstraints);
1623
- metalnessLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1624
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1625
- aConstraints.gridx += 1;
1626
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1627
- ctrlPanel.add(metalnessField = new NumberSlider(0.001, 1, -0.1), aConstraints);
1628
- aConstraints.gridx = 0;
1629
- aConstraints.gridy += 1;
1630
- aConstraints.gridwidth = 1;
1609
+ cGridBag velvet = new cGridBag();
1610
+ velvet.add(velvetLabel = new JLabel("Velvet")); // , aConstraints);
1611
+ velvetLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1612
+ velvet.add(velvetField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1613
+ specularSection.add(velvet);
16311614
1632
- ctrlPanel.add(velvetLabel = new JLabel("Velvet"), aConstraints);
1633
- velvetLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1634
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1635
- aConstraints.gridx += 1;
1636
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1637
- ctrlPanel.add(velvetField = new NumberSlider(0.001, 50, -1), aConstraints);
1638
- aConstraints.gridx = 0;
1639
- aConstraints.gridy += 1;
1640
- aConstraints.gridwidth = 1;
1641
-
1642
- shiftField = AddSlider(ctrlPanel, "Shift", 0.001, 50, copy.material.shift, -1);
1643
- Return();
1615
+ shiftField = (cNumberSlider)AddSlider(specularSection, "Shift", 0.001, 50, copy.material.shift, -1).getComponent(1);
1616
+ //Return();
16441617 // ctrlPanel.add(shiftLabel = new JLabel("Shift"), aConstraints);
16451618 // shiftLabel.setHorizontalAlignment(SwingConstants.TRAILING);
16461619 // aConstraints.fill = GridBagConstraints.HORIZONTAL;
....@@ -1651,130 +1624,93 @@
16511624 // aConstraints.gridy += 1;
16521625 // aConstraints.gridwidth = 1;
16531626
1654
- //aConstraints.weighty = 1;
1655
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100;
1656
- //aConstraints.gridx += 1;
1657
- ctrlPanel.add(new JLabel("----------------------------------"), aConstraints);
1658
- aConstraints.weighty = 0;
1659
- aConstraints.gridx = 0;
1660
- aConstraints.gridy += 1;
1661
- aConstraints.gridwidth = 1;
16621627
1663
- ctrlPanel.add(cameraLabel = new JLabel("GlobalLight"), aConstraints);
1664
- cameraLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1665
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1666
- aConstraints.gridx += 1;
1667
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1668
- ctrlPanel.add(cameraField = new NumberSlider(0.001, 50, -1), aConstraints);
1669
- aConstraints.gridx = 0;
1670
- aConstraints.gridy += 1;
1671
- aConstraints.gridwidth = 1;
1628
+ panel.add(new JSeparator());
1629
+
1630
+ panel.add(specularSection);
1631
+
1632
+ //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
1633
+
1634
+ cGridBag globalSection = new cGridBag().setVertical(true);
16721635
1673
- ctrlPanel.add(ambientLabel = new JLabel("Ambient"), aConstraints);
1674
- ambientLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1675
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1676
- aConstraints.gridx += 1;
1677
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1678
- ctrlPanel.add(ambientField = new NumberSlider(0.001, 50, -1), aConstraints);
1679
- aConstraints.gridx = 0;
1680
- aConstraints.gridy += 1;
1681
- aConstraints.gridwidth = 1;
1636
+ cGridBag camera = new cGridBag();
1637
+ camera.add(cameraLabel = new JLabel("GlobalLight")); // , aConstraints);
1638
+ cameraLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1639
+ camera.add(cameraField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1640
+ globalSection.add(camera);
16821641
1683
- ctrlPanel.add(backlitLabel = new JLabel("Backlit"), aConstraints);
1684
- backlitLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1685
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1686
- aConstraints.gridx += 1;
1687
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1688
- ctrlPanel.add(backlitField = new NumberSlider(0.001, 50, -1), aConstraints);
1689
- aConstraints.gridx = 0;
1690
- aConstraints.gridy += 1;
1691
- aConstraints.gridwidth = 1;
1642
+ cGridBag ambient = new cGridBag();
1643
+ ambient.add(ambientLabel = new JLabel("Ambient")); // , aConstraints);
1644
+ ambientLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1645
+ ambient.add(ambientField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1646
+ globalSection.add(ambient);
16921647
1693
- ctrlPanel.add(opacityLabel = new JLabel("Opacity"), aConstraints);
1694
- opacityLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1695
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1696
- aConstraints.gridx += 1;
1697
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1698
- ctrlPanel.add(opacityField = new NumberSlider(0.001, 1, -0.1), aConstraints);
1699
- aConstraints.gridx = 0;
1700
- aConstraints.gridy += 1;
1701
- aConstraints.gridwidth = 1;
1702
- aConstraints.weighty = 0;
1648
+ cGridBag backlit = new cGridBag();
1649
+ backlit.add(backlitLabel = new JLabel("Backlit")); // , aConstraints);
1650
+ backlitLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1651
+ backlit.add(backlitField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
1652
+ globalSection.add(backlit);
17031653
1704
- ctrlPanel.add(bumpLabel = new JLabel("Bump"), aConstraints);
1705
- bumpLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1706
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1707
- aConstraints.gridx += 1;
1708
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1709
- ctrlPanel.add(bumpField = new NumberSlider(0.0, 2), aConstraints);
1710
- aConstraints.gridx = 0;
1711
- aConstraints.gridy += 1;
1712
- aConstraints.gridwidth = 1;
1654
+ cGridBag opacity = new cGridBag();
1655
+ opacity.add(opacityLabel = new JLabel("Opacity")); // , aConstraints);
1656
+ opacityLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1657
+ opacity.add(opacityField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
1658
+ globalSection.add(opacity);
17131659
1714
- ctrlPanel.add(noiseLabel = new JLabel("Noise"), aConstraints);
1715
- noiseLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1716
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1717
- aConstraints.gridx += 1;
1718
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1719
- ctrlPanel.add(noiseField = new NumberSlider(0.0, 1/*5*/), aConstraints);
1720
- aConstraints.gridx = 0;
1721
- aConstraints.gridy += 1;
1722
- aConstraints.gridwidth = 1;
1660
+ panel.add(new JSeparator());
1661
+
1662
+ panel.add(globalSection);
1663
+
1664
+ //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
1665
+
1666
+ cGridBag textureSection = new cGridBag().setVertical(true);
17231667
1724
- ctrlPanel.add(powerLabel = new JLabel("Turbulance"), aConstraints);
1725
- powerLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1726
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1727
- aConstraints.gridx += 1;
1728
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1729
- ctrlPanel.add(powerField = new NumberSlider(0.0, 5), aConstraints);
1730
- aConstraints.gridx = 0;
1731
- aConstraints.gridy += 1;
1732
- aConstraints.gridwidth = 1;
1668
+ cGridBag bump = new cGridBag();
1669
+ bump.add(bumpLabel = new JLabel("Bump")); // , aConstraints);
1670
+ bumpLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1671
+ bump.add(bumpField = new cNumberSlider(this, 0.0, 2)); // , aConstraints);
1672
+ textureSection.add(bump);
17331673
1734
- ctrlPanel.add(borderfadeLabel = new JLabel("Borderfade"), aConstraints);
1735
- borderfadeLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1736
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1737
- aConstraints.gridx += 1;
1738
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1739
- ctrlPanel.add(borderfadeField = new NumberSlider(0.0, 2), aConstraints);
1740
- aConstraints.gridx = 0;
1741
- aConstraints.gridy += 1;
1742
- aConstraints.gridwidth = 1;
1674
+ cGridBag noise = new cGridBag();
1675
+ noise.add(noiseLabel = new JLabel("Noise")); // , aConstraints);
1676
+ noiseLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1677
+ noise.add(noiseField = new cNumberSlider(this, 0.0, 1/*5*/)); // , aConstraints);
1678
+ textureSection.add(noise);
17431679
1744
- ctrlPanel.add(fogLabel = new JLabel("Punch"), aConstraints);
1745
- fogLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1746
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1747
- aConstraints.gridx += 1;
1748
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1749
- ctrlPanel.add(fogField = new NumberSlider(0.0, 20), aConstraints);
1750
- aConstraints.gridx = 0;
1751
- aConstraints.gridy += 1;
1752
- aConstraints.gridwidth = 1;
1680
+ cGridBag power = new cGridBag();
1681
+ power.add(powerLabel = new JLabel("Turbulance")); // , aConstraints);
1682
+ powerLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1683
+ power.add(powerField = new cNumberSlider(this, 0.0, 5)); // , aConstraints);
1684
+ textureSection.add(power);
17531685
1754
- ctrlPanel.add(opacityPowerLabel = new JLabel("Halo"), aConstraints);
1755
- opacityPowerLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1756
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
1757
- aConstraints.gridx += 1;
1758
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
1759
- ctrlPanel.add(opacityPowerField = new NumberSlider(0.0, 10 /*10 dec 2013*/), aConstraints);
1760
- aConstraints.gridx = 0;
1761
- aConstraints.gridy += 1;
1762
- aConstraints.gridwidth = 1;
1686
+ cGridBag borderfade = new cGridBag();
1687
+ borderfade.add(borderfadeLabel = new JLabel("Borderfade")); // , aConstraints);
1688
+ borderfadeLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1689
+ borderfade.add(borderfadeField = new cNumberSlider(this, 0.0, 2)); // , aConstraints);
1690
+ textureSection.add(borderfade);
17631691
1764
- //aConstraints.weighty = 1;
1765
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100;
1766
- //aConstraints.gridx += 1;
1767
- ctrlPanel.add(new JLabel("----------------------------------"), aConstraints);
1768
- aConstraints.weighty = 0;
1692
+ cGridBag fog = new cGridBag();
1693
+ fog.add(fogLabel = new JLabel("Punch")); // , aConstraints);
1694
+ fogLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1695
+ fog.add(fogField = new cNumberSlider(this, 0.0, 20)); // , aConstraints);
1696
+ textureSection.add(fog);
17691697
1770
- aConstraints.gridx = 0;
1771
- aConstraints.gridy = 0;
1772
- aConstraints.gridwidth = 1;
1698
+ cGridBag opacityPower = new cGridBag();
1699
+ opacityPower.add(opacityPowerLabel = new JLabel("Halo")); // , aConstraints);
1700
+ opacityPowerLabel.setHorizontalAlignment(SwingConstants.TRAILING);
1701
+ opacityPower.add(opacityPowerField = new cNumberSlider(this, 0.0, 10 /*10 dec 2013*/)); // , aConstraints);
1702
+ textureSection.add(opacityPower);
1703
+
1704
+ panel.add(new JSeparator());
1705
+
1706
+ panel.add(textureSection);
1707
+
1708
+ //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
17731709
17741710 SetMaterial(copy); // .GetMaterial());
17751711
1776
- colorField.addChangeListener(this);
1777
- modulationField.addChangeListener(this);
1712
+ //colorField.addChangeListener(this);
1713
+// modulationField.addChangeListener(this);
17781714 metalnessField.addChangeListener(this);
17791715 diffuseField.addChangeListener(this);
17801716 specularField.addChangeListener(this);
....@@ -2586,6 +2522,7 @@
25862522 }
25872523 if (input == null)
25882524 {
2525
+ new Exception().printStackTrace();
25892526 System.exit(0);
25902527 }
25912528
....@@ -2989,7 +2926,8 @@
29892926 if (timeline)
29902927 {
29912928 centralPanel.remove(cameraView);
2992
- centralPanel.add(timelinePanel);
2929
+ cameraPanel.add(cameraView);
2930
+ centralPanel.add(cameraPanel);
29932931 frame.setJMenuBar(timelineMenubar);
29942932 wasFullScreen = CameraPane.FULLSCREEN;
29952933 if (!CameraPane.FULLSCREEN)
....@@ -2998,7 +2936,7 @@
29982936 }
29992937 else
30002938 {
3001
- centralPanel.remove(timelinePanel);
2939
+ centralPanel.remove(cameraPanel);
30022940 centralPanel.add(cameraView);
30032941 frame.setJMenuBar(null);
30042942 if (!wasFullScreen)
....@@ -3059,6 +2997,7 @@
30592997 if (event.getSource() == randomCB)
30602998 {
30612999 copy.random ^= true;
3000
+ objEditor.refreshContents();
30623001 return;
30633002 }
30643003 if (event.getSource() == speedupCB)
....@@ -3121,7 +3060,8 @@
31213060 objEditor.refreshContents();
31223061 } else if (event.getSource() == stepItem)
31233062 {
3124
- cameraView.ONESTEP = true;
3063
+ //cameraView.ONESTEP = true;
3064
+ Globals.ONESTEP = true;
31253065 cameraView.repaint();
31263066 return;
31273067 } else if (event.getSource() == stepButton)
....@@ -3278,25 +3218,25 @@
32783218
32793219 void ToggleAnimation()
32803220 {
3281
- if (!CameraPane.ANIMATION)
3221
+ if (!Globals.ANIMATION)
32823222 {
32833223 FileDialog browser = new FileDialog(frame, "Save Animation As...", FileDialog.SAVE);
3284
- browser.show();
3224
+ browser.setVisible(true);
32853225 String filename = browser.getFile();
32863226 if (filename != null && filename.length() > 0)
32873227 {
3288
- CameraPane.filename = browser.getDirectory() + filename;
3228
+ Globals.filename = browser.getDirectory() + filename;
32893229 //CameraPane.framecount = 0;
3290
- CameraPane.imagecount = 0;
3230
+ Globals.imagecount = 0;
32913231
3292
- CameraPane.ANIMATION ^= true;
3232
+ Globals.ANIMATION ^= true;
32933233
32943234 GrafreeD.wav.cursor = 0;
32953235 GrafreeD.wav.loop = 0;
32963236 }
32973237 } else
32983238 {
3299
- CameraPane.ANIMATION ^= true;
3239
+ Globals.ANIMATION ^= true;
33003240 }
33013241 }
33023242
....@@ -3313,6 +3253,7 @@
33133253 callee.refreshContents();
33143254 } else
33153255 {
3256
+ new Exception().printStackTrace();
33163257 System.exit(0);
33173258 }
33183259 }
....@@ -3475,7 +3416,7 @@
34753416 current.fakedepth = (float) fakedepthField.getFloat();
34763417 current.shadowbias = (float) shadowbiasField.getFloat();
34773418
3478
- if (!NumberSlider.frozen)
3419
+ if (!cNumberSlider.frozen)
34793420 {
34803421 //System.out.println("Propagate = " + propagate);
34813422 copy.UpdateMaterial(anchor, current, propagate);
....@@ -3523,6 +3464,7 @@
35233464 || e.getSource() == apertureField
35243465 || e.getSource() == shadowblurField)
35253466 {
3467
+ new Exception().printStackTrace();
35263468 System.exit(0);
35273469 cameraView.options1[0] = (float) focusField.getFloat() * 10;
35283470 cameraView.options1[1] = (float) apertureField.getFloat() / 1000;
....@@ -3549,7 +3491,13 @@
35493491 //System.out.println("PARENT = " + parent);
35503492 //if (parent != null)
35513493 // parent.applySelf();
3552
- refreshContents();
3494
+ if (e.getSource() == normalpushField)
3495
+ {
3496
+ objEditor.refreshContents();
3497
+ //Refresh();
3498
+ }
3499
+ else
3500
+ refreshContents();
35533501 // ??? client.refreshEditWindow();
35543502 }
35553503 //else
....@@ -3561,7 +3509,7 @@
35613509 //group.name = nameField.getText();
35623510 //objEditor.applySelf();
35633511
3564
- assert (objEditor == this);
3512
+ // OCT2018: assert (objEditor == this);
35653513 if (copy.selection == null || copy.selection.size() == 0)
35663514 //super.applySelf()
35673515 ; else
....@@ -3585,6 +3533,9 @@
35853533 objEditor.copy = keep;
35863534 }
35873535 }
3536
+
3537
+ if (normalpushField != null)
3538
+ copy.NORMALPUSH = (float)normalpushField.getFloat()/1000;
35883539 }
35893540
35903541 void SnapObject()
....@@ -3839,7 +3790,7 @@
38393790
38403791 radioPanel.revalidate();
38413792 radioPanel.repaint();
3842
- ctrlPanel.revalidate(); // ? new
3793
+ ctrlPanel.validate(); // ? new
38433794 ctrlPanel.repaint();
38443795 }
38453796 }
....@@ -4485,8 +4436,8 @@
44854436 //MenuItem normalLensItem;
44864437 MenuItem editCameraItem;
44874438 MenuItem revertCameraItem;
4488
- CheckboxMenuItem toggleLiveItem;
44894439 MenuItem stepItem;
4440
+ CheckboxMenuItem toggleLiveItem;
44904441 CheckboxMenuItem toggleFullScreenItem;
44914442 CheckboxMenuItem toggleTimelineItem;
44924443 CheckboxMenuItem toggleRenderItem;
....@@ -4503,20 +4454,21 @@
45034454 JSplitPane mainPanel;
45044455 JScrollPane scrollpane;
45054456 JPanel toolbarPanel;
4506
- JPanel treePanel;
4457
+ cGridBag treePanel;
45074458 JPanel radioPanel;
45084459 ButtonGroup buttonGroup;
4509
- JPanel ctrlPanel;
4510
- JPanel materialPanel;
4460
+ cGridBag ctrlPanel;
4461
+ cGridBag materialPanel;
45114462 JScrollPane infoPanel;
4512
- JPanel optionsPanel;
4463
+ cGridBag optionsPanel;
45134464 JTabbedPane objectPanel;
4514
- JPanel XYZPanel;
4465
+ cGridBag XYZPanel;
45154466 JSplitPane gridPanel;
45164467 JSplitPane bigPanel;
4517
- JPanel bigThree;
4518
- JTabbedPane scenePanel;
4519
- JPanel centralPanel;
4468
+ cGridBag bigThree;
4469
+ cGridBag scenePanel;
4470
+ cGridBag centralPanel;
4471
+ JSplitPane cameraPanel;
45204472 JPanel timelinePanel;
45214473 JMenuBar timelineMenubar;
45224474 JSplitPane framePanel;
....@@ -4568,65 +4520,67 @@
45684520 // MATERIAL
45694521 JLabel materialLabel;
45704522 JLabel colorLabel;
4571
- NumberSlider colorField;
4523
+ cNumberSlider colorField;
45724524 JLabel modulationLabel;
4573
- NumberSlider modulationField;
4525
+ cNumberSlider modulationField;
45744526 JLabel metalnessLabel;
4575
- NumberSlider metalnessField;
4527
+ cNumberSlider metalnessField;
45764528 JLabel diffuseLabel;
4577
- NumberSlider diffuseField;
4529
+ cNumberSlider diffuseField;
45784530 JLabel specularLabel;
4579
- NumberSlider specularField;
4531
+ cNumberSlider specularField;
45804532 JLabel shininessLabel;
4581
- NumberSlider shininessField;
4533
+ cNumberSlider shininessField;
45824534 JLabel shiftLabel;
4583
- NumberSlider shiftField;
4535
+ cNumberSlider shiftField;
45844536 JLabel ambientLabel;
4585
- NumberSlider ambientField;
4537
+ cNumberSlider ambientField;
45864538 JLabel lightareaLabel;
4587
- NumberSlider lightareaField;
4539
+ cNumberSlider lightareaField;
45884540 JLabel diffusenessLabel;
4589
- NumberSlider diffusenessField;
4541
+ cNumberSlider diffusenessField;
45904542 JLabel velvetLabel;
4591
- NumberSlider velvetField;
4543
+ cNumberSlider velvetField;
45924544 JLabel sheenLabel;
4593
- NumberSlider sheenField;
4545
+ cNumberSlider sheenField;
45944546 JLabel subsurfaceLabel;
4595
- NumberSlider subsurfaceField;
4547
+ cNumberSlider subsurfaceField;
45964548 //JLabel bumpLabel;
45974549 //NumberSlider bumpField;
45984550 JLabel backlitLabel;
4599
- NumberSlider backlitField;
4551
+ cNumberSlider backlitField;
46004552 JLabel anisoLabel;
4601
- NumberSlider anisoField;
4553
+ cNumberSlider anisoField;
46024554 JLabel anisoVLabel;
4603
- NumberSlider anisoVField;
4555
+ cNumberSlider anisoVField;
46044556 JLabel cameraLabel;
4605
- NumberSlider cameraField;
4557
+ cNumberSlider cameraField;
46064558 JLabel selfshadowLabel;
4607
- NumberSlider selfshadowField;
4559
+ cNumberSlider selfshadowField;
46084560 JLabel shadowLabel;
4609
- NumberSlider shadowField;
4561
+ cNumberSlider shadowField;
46104562 JLabel textureLabel;
4611
- NumberSlider textureField;
4563
+ cNumberSlider textureField;
46124564 JLabel opacityLabel;
4613
- NumberSlider opacityField;
4565
+ cNumberSlider opacityField;
46144566 JLabel fakedepthLabel;
4615
- NumberSlider fakedepthField;
4567
+ cNumberSlider fakedepthField;
46164568 JLabel shadowbiasLabel;
4617
- NumberSlider shadowbiasField;
4569
+ cNumberSlider shadowbiasField;
46184570 JLabel bumpLabel;
4619
- NumberSlider bumpField;
4571
+ cNumberSlider bumpField;
46204572 JLabel noiseLabel;
4621
- NumberSlider noiseField;
4573
+ cNumberSlider noiseField;
46224574 JLabel powerLabel;
4623
- NumberSlider powerField;
4575
+ cNumberSlider powerField;
46244576 JLabel borderfadeLabel;
4625
- NumberSlider borderfadeField;
4577
+ cNumberSlider borderfadeField;
46264578 JLabel fogLabel;
4627
- NumberSlider fogField;
4579
+ cNumberSlider fogField;
46284580 JLabel opacityPowerLabel;
4629
- NumberSlider opacityPowerField;
4581
+ cNumberSlider opacityPowerField;
46304582 JTree jTree;
46314583 //ObjectUI parent;
4584
+
4585
+ cNumberSlider normalpushField;
46324586 }