.. | .. |
---|
23 | 23 | DragGestureListener, DragSourceListener, DropTargetListener, |
---|
24 | 24 | ItemListener // ListSelectionListener |
---|
25 | 25 | { |
---|
| 26 | + |
---|
| 27 | + public void AddSkyboxButton(String f, String s, cGridBag row) |
---|
| 28 | + { |
---|
| 29 | + cButton skyboxButton; |
---|
| 30 | + final String path = "cubemaps/" + f + "-skyboxes/" + s; |
---|
| 31 | + row.add(skyboxButton = GetButton(path + "/preview.jpg", !Grafreed.NIMBUSLAF)); |
---|
| 32 | + //row.add(skyboxButton = GetButton(path + "/negx.jpg", !Grafreed.NIMBUSLAF)); |
---|
| 33 | + skyboxButton.setToolTipText(s); |
---|
| 34 | + skyboxButton.addActionListener(new ActionListener() |
---|
| 35 | + { |
---|
| 36 | + @Override |
---|
| 37 | + public void actionPerformed(ActionEvent e) |
---|
| 38 | + { |
---|
| 39 | + ChangeSkybox(path); |
---|
| 40 | + } |
---|
| 41 | + }); |
---|
| 42 | + } |
---|
| 43 | + |
---|
| 44 | + public void AddSkyboxTab0(JTabbedPane skyboxpanel) |
---|
| 45 | + { |
---|
| 46 | + cGridBag tab0 = new cGridBag().setVertical(true); |
---|
| 47 | + |
---|
| 48 | + tab0.setName("Urban"); |
---|
| 49 | + skyboxpanel.add(tab0); |
---|
| 50 | + |
---|
| 51 | + cGridBag row0 = new cGridBag(); |
---|
| 52 | + cGridBag row1 = new cGridBag(); |
---|
| 53 | + cGridBag row2 = new cGridBag(); |
---|
| 54 | + cGridBag row3 = new cGridBag(); |
---|
| 55 | + cGridBag row4 = new cGridBag(); |
---|
| 56 | + cGridBag row5 = new cGridBag(); |
---|
| 57 | + cGridBag row6 = new cGridBag(); |
---|
| 58 | + |
---|
| 59 | + AddSkyboxButton("default", "rgb", row0); |
---|
| 60 | + //AddSkyboxButton("default", "cornell", row0); |
---|
| 61 | + AddSkyboxButton("penguins", "dust", row0); |
---|
| 62 | + AddSkyboxButton("penguins", "tropic", row0); |
---|
| 63 | + AddSkyboxButton("default", "skycube", row0); |
---|
| 64 | + |
---|
| 65 | + AddSkyboxButton("default", "uffizi", row1); |
---|
| 66 | + AddSkyboxButton("bridge", "Bridge", row1); |
---|
| 67 | + AddSkyboxButton("bridge", "Bridge2", row1); |
---|
| 68 | + AddSkyboxButton("urban", "GamlaStan2", row1); |
---|
| 69 | + |
---|
| 70 | + AddSkyboxButton("urban", "Parliament", row2); |
---|
| 71 | + AddSkyboxButton("urban", "Roundabout", row2); |
---|
| 72 | + AddSkyboxButton("urban", "SaintLazarusChurch", row2); |
---|
| 73 | + AddSkyboxButton("urban", "SaintLazarusChurch2", row2); |
---|
| 74 | + |
---|
| 75 | + AddSkyboxButton("urban", "SaintLazarusChurch3", row3); |
---|
| 76 | + AddSkyboxButton("urban", "UnionSquare", row3); |
---|
| 77 | + AddSkyboxButton("urban", "Medborgarplatsen", row3); |
---|
| 78 | + AddSkyboxButton("park", "BerzeliiPark", row3); |
---|
| 79 | + |
---|
| 80 | + AddSkyboxButton("park", "Buddha", row4); |
---|
| 81 | + AddSkyboxButton("park", "CNTower2", row4); |
---|
| 82 | + AddSkyboxButton("park", "NiagaraFalls1", row4); |
---|
| 83 | + AddSkyboxButton("park", "NiagaraFalls3", row4); |
---|
| 84 | + |
---|
| 85 | + AddSkyboxButton("park", "Park", row5); |
---|
| 86 | + AddSkyboxButton("park", "Pond", row5); |
---|
| 87 | + AddSkyboxButton("park", "Skansen", row5); |
---|
| 88 | + AddSkyboxButton("park", "Skansen2", row5); |
---|
| 89 | + |
---|
| 90 | + AddSkyboxButton("park", "Skansen3", row6); |
---|
| 91 | + AddSkyboxButton("park", "Skansen4", row6); |
---|
| 92 | + AddSkyboxButton("park", "Skansen5", row6); |
---|
| 93 | + AddSkyboxButton("park", "Stairs", row6); |
---|
| 94 | + |
---|
| 95 | + tab0.add(row0); |
---|
| 96 | + tab0.add(row1); |
---|
| 97 | + tab0.add(row2); |
---|
| 98 | + tab0.add(row3); |
---|
| 99 | + tab0.add(row4); |
---|
| 100 | + tab0.add(row5); |
---|
| 101 | + tab0.add(row6); |
---|
| 102 | + |
---|
| 103 | + for (int i=5; --i>=0;) |
---|
| 104 | + { |
---|
| 105 | + //oe.toolboxPanel.Return(); |
---|
| 106 | + //tab0.add(new cGridBag()); |
---|
| 107 | + } |
---|
| 108 | + } |
---|
| 109 | + |
---|
| 110 | + public void AddSkyboxTab1(JTabbedPane skyboxpanel) |
---|
| 111 | + { |
---|
| 112 | + cGridBag tab0 = new cGridBag().setVertical(true); |
---|
| 113 | + |
---|
| 114 | + tab0.setName("Nature"); |
---|
| 115 | + skyboxpanel.add(tab0); |
---|
| 116 | + |
---|
| 117 | + cGridBag row0 = new cGridBag(); |
---|
| 118 | + cGridBag row1 = new cGridBag(); |
---|
| 119 | + cGridBag row2 = new cGridBag(); |
---|
| 120 | + cGridBag row3 = new cGridBag(); |
---|
| 121 | + cGridBag row4 = new cGridBag(); |
---|
| 122 | + cGridBag row5 = new cGridBag(); |
---|
| 123 | + cGridBag row6 = new cGridBag(); |
---|
| 124 | + |
---|
| 125 | + AddSkyboxButton("beach", "HeartInTheSand", row0); |
---|
| 126 | + AddSkyboxButton("beach", "LarnacaBeach", row0); |
---|
| 127 | + AddSkyboxButton("beach", "PalmTrees", row0); |
---|
| 128 | + AddSkyboxButton("beach", "Tenerife", row0); |
---|
| 129 | + |
---|
| 130 | + AddSkyboxButton("beach", "Tenerife2", row1); |
---|
| 131 | + AddSkyboxButton("beach", "Tenerife3", row1); |
---|
| 132 | + AddSkyboxButton("field", "FishPond", row1); |
---|
| 133 | + AddSkyboxButton("field", "Footballfield", row1); |
---|
| 134 | + |
---|
| 135 | + AddSkyboxButton("field", "Meadow", row2); |
---|
| 136 | + AddSkyboxButton("field", "Sorsele", row2); |
---|
| 137 | + AddSkyboxButton("field", "Sorsele2", row2); |
---|
| 138 | + AddSkyboxButton("field", "Sorsele3", row2); |
---|
| 139 | + |
---|
| 140 | + AddSkyboxButton("forest", "Brudslojan", row3); |
---|
| 141 | + AddSkyboxButton("forest", "Langholmen2", row3); |
---|
| 142 | + AddSkyboxButton("forest", "Plants", row3); |
---|
| 143 | + AddSkyboxButton("mountain", "Maskonaive", row3); |
---|
| 144 | + |
---|
| 145 | + AddSkyboxButton("mountain", "Maskonaive2", row4); |
---|
| 146 | + AddSkyboxButton("mountain", "Maskonaive3", row4); |
---|
| 147 | + AddSkyboxButton("mountain", "Ryfjallet", row4); |
---|
| 148 | + AddSkyboxButton("mountain", "Teide", row4); |
---|
| 149 | + AddSkyboxButton("park", "Tantolunden4", row4); |
---|
| 150 | + |
---|
| 151 | + AddSkyboxButton("penguins", "wrath", row5); |
---|
| 152 | + AddSkyboxButton("penguins", "yonder", row5); |
---|
| 153 | + AddSkyboxButton("rocky", "Langholmen", row5); |
---|
| 154 | + AddSkyboxButton("rocky", "Skinnarviksberget", row5); |
---|
| 155 | + AddSkyboxButton("rocky", "Tantolunden6", row5); |
---|
| 156 | + |
---|
| 157 | + AddSkyboxButton("default", "CloudyHills", row6); |
---|
| 158 | + AddSkyboxButton("daz", "Autumn", row6); |
---|
| 159 | + AddSkyboxButton("daz", "Greenlands", row6); |
---|
| 160 | + AddSkyboxButton("daz", "MountainTrail", row6); |
---|
| 161 | + AddSkyboxButton("daz", "Oasis", row6); |
---|
| 162 | + /* |
---|
| 163 | +Autumn |
---|
| 164 | +Greenlands |
---|
| 165 | +MountainTrail |
---|
| 166 | +Oasis |
---|
| 167 | +TheRock |
---|
| 168 | +TopOfTheWorld |
---|
| 169 | +Winter |
---|
| 170 | + */ |
---|
| 171 | + |
---|
| 172 | + tab0.add(row0); |
---|
| 173 | + tab0.add(row1); |
---|
| 174 | + tab0.add(row2); |
---|
| 175 | + tab0.add(row3); |
---|
| 176 | + tab0.add(row4); |
---|
| 177 | + tab0.add(row5); |
---|
| 178 | + tab0.add(row6); |
---|
| 179 | + |
---|
| 180 | + for (int i=5; --i>=0;) |
---|
| 181 | + { |
---|
| 182 | + //oe.toolboxPanel.Return(); |
---|
| 183 | + //tab0.add(new cGridBag()); |
---|
| 184 | + } |
---|
| 185 | + } |
---|
| 186 | + |
---|
| 187 | + public void AddSkyboxTab2(JTabbedPane skyboxpanel) |
---|
| 188 | + { |
---|
| 189 | + cGridBag tab0 = new cGridBag().setVertical(true); |
---|
| 190 | + |
---|
| 191 | + tab0.setName("Night"); |
---|
| 192 | + skyboxpanel.add(tab0); |
---|
| 193 | + |
---|
| 194 | + cGridBag row0 = new cGridBag(); |
---|
| 195 | + cGridBag row1 = new cGridBag(); |
---|
| 196 | + cGridBag row2 = new cGridBag(); |
---|
| 197 | + cGridBag row3 = new cGridBag(); |
---|
| 198 | + cGridBag row4 = new cGridBag(); |
---|
| 199 | + cGridBag row5 = new cGridBag(); |
---|
| 200 | + cGridBag row6 = new cGridBag(); |
---|
| 201 | + |
---|
| 202 | + AddSkyboxButton("night", "NightPath", row0); |
---|
| 203 | + AddSkyboxButton("night", "PondNight", row0); |
---|
| 204 | + AddSkyboxButton("night", "Powerlines", row0); |
---|
| 205 | + AddSkyboxButton("night", "SwedishRoyalCastle", row0); |
---|
| 206 | + |
---|
| 207 | + AddSkyboxButton("urban", "CNTower", row1); |
---|
| 208 | + AddSkyboxButton("bridge", "ArstaBridge", row1); |
---|
| 209 | + AddSkyboxButton("rocky", "Riddarfjarden", row1); |
---|
| 210 | + AddSkyboxButton("penguins", "sleepyhollow", row1); |
---|
| 211 | + |
---|
| 212 | + AddSkyboxButton("penguins", "kenon_star", row2); |
---|
| 213 | + AddSkyboxButton("indoors", "DallasW", row2); |
---|
| 214 | + AddSkyboxButton("indoors", "MarriottMadisonWest", row2); |
---|
| 215 | + AddSkyboxButton("indoors", "Vasa", row2); |
---|
| 216 | + |
---|
| 217 | + AddSkyboxButton("winter", "Backyard", row3); |
---|
| 218 | + AddSkyboxButton("winter", "Creek", row3); |
---|
| 219 | + AddSkyboxButton("winter", "FootballField3", row3); |
---|
| 220 | + AddSkyboxButton("winter", "Forest", row3); |
---|
| 221 | + |
---|
| 222 | + AddSkyboxButton("winter", "HornstullsStrand2", row4); |
---|
| 223 | + AddSkyboxButton("winter", "House", row4); |
---|
| 224 | + AddSkyboxButton("winter", "IceLake", row4); |
---|
| 225 | + AddSkyboxButton("winter", "IceRiver", row4); |
---|
| 226 | + |
---|
| 227 | + AddSkyboxButton("winter", "Park3", row5); |
---|
| 228 | + AddSkyboxButton("winter", "PondWinter", row5); |
---|
| 229 | + AddSkyboxButton("winter", "Tantolunden5", row5); |
---|
| 230 | + AddSkyboxButton("winter", "Vindelalven", row5); |
---|
| 231 | + |
---|
| 232 | + AddSkyboxButton("daz", "TheRock", row6); |
---|
| 233 | + AddSkyboxButton("daz", "TopOfTheWorld", row6); |
---|
| 234 | + AddSkyboxButton("daz", "Winter", row6); |
---|
| 235 | + AddSkyboxButton("penguins", "desertdawn", row6); |
---|
| 236 | + |
---|
| 237 | + tab0.add(row0); |
---|
| 238 | + tab0.add(row1); |
---|
| 239 | + tab0.add(row2); |
---|
| 240 | + tab0.add(row3); |
---|
| 241 | + tab0.add(row4); |
---|
| 242 | + tab0.add(row5); |
---|
| 243 | + tab0.add(row6); |
---|
| 244 | + |
---|
| 245 | + for (int i=5; --i>=0;) |
---|
| 246 | + { |
---|
| 247 | + //oe.toolboxPanel.Return(); |
---|
| 248 | + //tab0.add(new cGridBag()); |
---|
| 249 | + } |
---|
| 250 | + } |
---|
| 251 | + |
---|
| 252 | + public void ChangeSkybox(String name) |
---|
| 253 | + { |
---|
| 254 | + //cameraView.envyoff = false; |
---|
| 255 | + group.skyboxname = name; |
---|
| 256 | + group.skyboxext = "jpg"; |
---|
| 257 | + cameraView.repaint(); |
---|
| 258 | + } |
---|
| 259 | + |
---|
26 | 260 | //ObjEditor objEditor; |
---|
27 | 261 | public void closeUI2() |
---|
28 | 262 | { |
---|
.. | .. |
---|
608 | 842 | */ |
---|
609 | 843 | cGridBag copyOptionsPanel = new cGridBag(); |
---|
610 | 844 | |
---|
611 | | - copyOptionsPanel.preferredHeight = 1; |
---|
| 845 | + copyOptionsPanel.preferredHeight = 2; |
---|
612 | 846 | |
---|
613 | 847 | //this.AddOptions(oe.toolbarPanel, oe.aConstraints); |
---|
614 | 848 | |
---|
.. | .. |
---|
688 | 922 | oe.toolbarPanel.add(snapobjectButton = new cButton("O+", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
689 | 923 | snapobjectButton.addActionListener(this); |
---|
690 | 924 | snapobjectButton.setToolTipText("Snap Object"); |
---|
| 925 | + |
---|
| 926 | + oe.toolbarPanel.add(fourButton = GetButton("icons/controls-horizontal.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 927 | + fourButton.addActionListener(this); |
---|
| 928 | + fourButton.setToolTipText("Show control panel only"); |
---|
691 | 929 | } |
---|
692 | 930 | |
---|
693 | 931 | //oe.toolbarPanel.add(new JSeparator(SwingConstants.VERTICAL)); |
---|
694 | 932 | |
---|
695 | | - oe.toolbarPanel.add(fourButton = new cButton("-||", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
696 | | - fourButton.addActionListener(this); |
---|
697 | | - fourButton.setToolTipText("Show left panel only"); |
---|
698 | | - |
---|
699 | | - oe.toolbarPanel.add(twoButton = new cButton("|-|", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
700 | | - twoButton.setToolTipText("Show right view only"); |
---|
| 933 | + oe.toolbarPanel.add(twoButton = GetButton("icons/cube.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 934 | + twoButton.setToolTipText("Show 3D view only"); |
---|
701 | 935 | twoButton.addActionListener(this); |
---|
702 | 936 | this.fullscreenLayout = twoButton; |
---|
703 | 937 | |
---|
704 | | - oe.toolbarPanel.add(sixButton = new cButton("-|-|", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
705 | | - sixButton.setToolTipText("Show left and right"); |
---|
| 938 | + oe.toolbarPanel.add(threeButton = GetButton("icons/controlsview.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 939 | + threeButton.setToolTipText("Show controls and 3D view"); |
---|
| 940 | + threeButton.addActionListener(this); |
---|
| 941 | + oe.toolbarPanel.add(sixButton = GetButton("icons/viewcontrols.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 942 | + sixButton.setToolTipText("Show 3D view and controls"); |
---|
706 | 943 | sixButton.addActionListener(this); |
---|
707 | | -// oe.toolbarPanel.add(threeButton = new cButton("|-|-", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
708 | | -// threeButton.setToolTipText("2-column layout right"); |
---|
709 | | -// threeButton.addActionListener(this); |
---|
710 | 944 | // oe.toolbarPanel.add(sevenButton = new cButton("-|-|-", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
711 | 945 | // sevenButton.setToolTipText("3-column layout"); |
---|
712 | 946 | // sevenButton.addActionListener(this); |
---|
.. | .. |
---|
722 | 956 | //oe.treePanel.add(clearButton = new cButton("X"), oe.aConstraints); |
---|
723 | 957 | //clearButton.addActionListener(this); |
---|
724 | 958 | |
---|
| 959 | + cGridBag row1 = new cGridBag(); |
---|
| 960 | + |
---|
725 | 961 | // INSERT |
---|
726 | | - oe.toolboxPanel.add(gridButton = GetButton("icons/grid.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 962 | + row1.add(gridButton = GetButton("icons/grid.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
727 | 963 | gridButton.setToolTipText("Create grid"); |
---|
728 | 964 | gridButton.addActionListener(this); |
---|
729 | 965 | |
---|
730 | | - oe.toolboxPanel.add(boxButton = GetButton("icons/box.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 966 | + row1.add(boxButton = GetButton("icons/box.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
731 | 967 | boxButton.setToolTipText("Create box"); |
---|
732 | 968 | boxButton.addActionListener(this); |
---|
733 | 969 | |
---|
734 | | - oe.toolboxPanel.add(sphereButton = GetButton("icons/sphere.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 970 | + row1.add(sphereButton = GetButton("icons/sphere.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
735 | 971 | sphereButton.setToolTipText("Create sphere"); |
---|
736 | 972 | sphereButton.addActionListener(this); |
---|
737 | 973 | |
---|
738 | | - oe.toolboxPanel.add(coneButton = GetButton("icons/cone.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 974 | + row1.add(coneButton = GetButton("icons/cone.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
739 | 975 | coneButton.setToolTipText("Create cone"); |
---|
740 | 976 | coneButton.addActionListener(this); |
---|
741 | 977 | |
---|
742 | | - oe.toolboxPanel.add(torusButton = GetButton("icons/torus.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 978 | + row1.add(torusButton = GetButton("icons/torus.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
743 | 979 | torusButton.setToolTipText("Create torus"); |
---|
744 | 980 | torusButton.addActionListener(this); |
---|
745 | 981 | |
---|
746 | | - oe.toolboxPanel.add(superButton = GetButton("icons/super.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 982 | + row1.add(superButton = GetButton("icons/super.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
747 | 983 | superButton.setToolTipText("Create superellipsoid"); |
---|
748 | 984 | superButton.addActionListener(this); |
---|
749 | 985 | |
---|
.. | .. |
---|
754 | 990 | kleinButton.addActionListener(this); |
---|
755 | 991 | } |
---|
756 | 992 | |
---|
757 | | - oe.toolboxPanel.add(particlesButton = GetButton("icons/particles.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 993 | + row1.add(particlesButton = GetButton("icons/particles.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
758 | 994 | particlesButton.setToolTipText("Create particle system"); |
---|
759 | 995 | particlesButton.addActionListener(this); |
---|
760 | 996 | |
---|
761 | | - oe.toolboxPanel.Return(); |
---|
| 997 | + oe.toolboxPanel.add(row1); |
---|
762 | 998 | |
---|
763 | | - oe.toolboxPanel.add(groupButton = GetButton("icons/group.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 999 | + cGridBag row2 = new cGridBag(); |
---|
| 1000 | + |
---|
| 1001 | + row2.add(groupButton = GetButton("icons/group.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
764 | 1002 | groupButton.setToolTipText("Create group"); |
---|
765 | 1003 | groupButton.addActionListener(this); |
---|
766 | 1004 | |
---|
767 | | - oe.toolboxPanel.add(compositeButton = GetButton("icons/composite.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 1005 | + row2.add(compositeButton = GetButton("icons/composite.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
768 | 1006 | compositeButton.setToolTipText("Create composite"); |
---|
769 | 1007 | compositeButton.addActionListener(this); |
---|
770 | 1008 | |
---|
771 | | - oe.toolboxPanel.add(switchButton = GetButton("icons/switch.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 1009 | + row2.add(switchButton = GetButton("icons/switch.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
772 | 1010 | switchButton.setToolTipText("Create item switcher"); |
---|
773 | 1011 | switchButton.addActionListener(this); |
---|
774 | 1012 | |
---|
775 | | - oe.toolboxPanel.add(loopButton = GetButton("icons/loop.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 1013 | + row2.add(loopButton = GetButton("icons/loop.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
776 | 1014 | loopButton.setToolTipText("Create loop"); |
---|
777 | 1015 | loopButton.addActionListener(this); |
---|
778 | 1016 | |
---|
779 | | - oe.toolboxPanel.add(textureButton = GetButton("icons/texture.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 1017 | + row2.add(textureButton = GetButton("icons/texture.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
780 | 1018 | textureButton.setToolTipText("Create texture"); |
---|
781 | 1019 | textureButton.addActionListener(this); |
---|
782 | 1020 | |
---|
783 | | - oe.toolboxPanel.add(overlayButton = GetButton("icons/overlay.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 1021 | + row2.add(overlayButton = GetButton("icons/overlay.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
784 | 1022 | overlayButton.setToolTipText("Create overlay"); |
---|
785 | 1023 | overlayButton.addActionListener(this); |
---|
786 | 1024 | |
---|
787 | | - oe.toolboxPanel.add(lightButton = GetButton("icons/light-bulb.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
| 1025 | + row2.add(lightButton = GetButton("icons/light-bulb.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
788 | 1026 | lightButton.setToolTipText("Create light"); |
---|
789 | 1027 | lightButton.addActionListener(this); |
---|
790 | 1028 | |
---|
791 | | - for (int i=6; --i>=0;) |
---|
792 | | - { |
---|
793 | | - oe.toolboxPanel.Return(); |
---|
794 | | - oe.toolboxPanel.add(new cGridBag()); |
---|
795 | | - oe.toolboxPanel.add(new cGridBag()); |
---|
796 | | - oe.toolboxPanel.add(new cGridBag()); |
---|
797 | | - oe.toolboxPanel.add(new cGridBag()); |
---|
798 | | - oe.toolboxPanel.add(new cGridBag()); |
---|
799 | | - oe.toolboxPanel.add(new cGridBag()); |
---|
800 | | - oe.toolboxPanel.add(new cGridBag()); |
---|
801 | | - } |
---|
| 1029 | + oe.toolboxPanel.add(row2); |
---|
| 1030 | + |
---|
| 1031 | + // ENVYMAPS |
---|
| 1032 | + cGridBag skyboxpane = new cGridBag(); |
---|
| 1033 | + skyboxpane.preferredHeight = 100; |
---|
| 1034 | + |
---|
| 1035 | + oe.toolboxPanel.add(skyboxpane); |
---|
| 1036 | + |
---|
| 1037 | + JTabbedPane skyboxpanel = new JTabbedPane(); |
---|
| 1038 | + skyboxpane.add(skyboxpanel); |
---|
| 1039 | + |
---|
| 1040 | + AddSkyboxTab0(skyboxpanel); |
---|
| 1041 | + AddSkyboxTab1(skyboxpanel); |
---|
| 1042 | + AddSkyboxTab2(skyboxpanel); |
---|
802 | 1043 | |
---|
803 | 1044 | // EDIT panel |
---|
804 | 1045 | editCommandsPanel.add(editButton = GetButton("icons/controls.png", !Grafreed.NIMBUSLAF)); //, oe.aConstraints); |
---|
.. | .. |
---|
858 | 1099 | versionSlider = (cNumberSlider)sliderPane.getComponent(1); |
---|
859 | 1100 | sliderPane.preferredHeight = 1; |
---|
860 | 1101 | |
---|
861 | | -// mainPanel.setDividerLocation(0.5); //1.0); |
---|
862 | | -// mainPanel.setResizeWeight(0.5); |
---|
| 1102 | +// mainPanel.setDividerLocation(0.1); //1.0); |
---|
| 1103 | + mainPanel.setResizeWeight(0.4); |
---|
863 | 1104 | |
---|
864 | 1105 | //jList.addListSelectionListener(this); |
---|
865 | 1106 | oe.jTree.addTreeSelectionListener(this); |
---|
.. | .. |
---|
867 | 1108 | //jTree.setEditable(true); |
---|
868 | 1109 | oe.jTree.setDragEnabled(true); |
---|
869 | 1110 | //jTree.setPreferredSize(new Dimension(10,10)); |
---|
870 | | - jSP.setPreferredSize(new Dimension(100,200)); |
---|
| 1111 | + //jSP.setPreferredSize(new Dimension(100,200)); |
---|
871 | 1112 | |
---|
872 | 1113 | oe.jTree.setCellRenderer(new cTreeModel.Renderer()); |
---|
873 | 1114 | |
---|
.. | .. |
---|
2139 | 2380 | { |
---|
2140 | 2381 | makeSomething(new Light()); |
---|
2141 | 2382 | } else |
---|
| 2383 | +// if (source == skybox1Button || |
---|
| 2384 | +// source == skybox2Button || |
---|
| 2385 | +// source == skybox3Button || |
---|
| 2386 | +// source == skybox4Button || |
---|
| 2387 | +// source == skybox5Button || |
---|
| 2388 | +// source == skybox6Button || |
---|
| 2389 | +// source == skybox7Button || |
---|
| 2390 | +// source == skybox11Button || |
---|
| 2391 | +// source == skybox12Button || |
---|
| 2392 | +// source == skybox13Button || |
---|
| 2393 | +// source == skybox14Button || |
---|
| 2394 | +// source == skybox15Button || |
---|
| 2395 | +// source == skybox16Button || |
---|
| 2396 | +// source == skybox17Button) |
---|
| 2397 | +// { |
---|
| 2398 | +// ChangeSkybox(source); |
---|
| 2399 | +// } else |
---|
2142 | 2400 | if (source == csgItem) |
---|
2143 | 2401 | { |
---|
2144 | 2402 | group(new CSG()); |
---|
.. | .. |
---|
2224 | 2482 | if (source == computeAOItem) |
---|
2225 | 2483 | { |
---|
2226 | 2484 | Globals.drawMode = CameraPane.OCCLUSION; |
---|
2227 | | - Globals.theRenderer.repaint(); |
---|
| 2485 | + cameraView.repaint(); |
---|
2228 | 2486 | } else |
---|
2229 | 2487 | if (source == recompileItem) |
---|
2230 | 2488 | { |
---|
.. | .. |
---|
3300 | 3558 | // centralPanel.setVisible(true); |
---|
3301 | 3559 | // XYZPanel.setVisible(true); |
---|
3302 | 3560 | bigThree.ClearUI(); |
---|
| 3561 | + bigThree.add(scenePanel); |
---|
3303 | 3562 | bigThree.add(centralPanel); |
---|
3304 | | - bigThree.add(XYZPanel); |
---|
3305 | 3563 | bigThree.FlushUI(); |
---|
3306 | 3564 | |
---|
3307 | 3565 | cameraView.requestFocusInWindow(); |
---|
.. | .. |
---|
3381 | 3639 | // centralPanel.setVisible(true); |
---|
3382 | 3640 | // XYZPanel.setVisible(false); |
---|
3383 | 3641 | bigThree.ClearUI(); |
---|
3384 | | - bigThree.add(scenePanel); |
---|
3385 | 3642 | bigThree.add(centralPanel); |
---|
| 3643 | + bigThree.add(scenePanel); |
---|
3386 | 3644 | bigThree.FlushUI(); |
---|
3387 | 3645 | |
---|
3388 | 3646 | cameraView.requestFocusInWindow(); |
---|
.. | .. |
---|
5676 | 5934 | cButton loopButton; |
---|
5677 | 5935 | cButton textureButton; |
---|
5678 | 5936 | |
---|
| 5937 | + cButton skybox1Button; |
---|
| 5938 | + cButton skybox2Button; |
---|
| 5939 | + cButton skybox3Button; |
---|
| 5940 | + cButton skybox4Button; |
---|
| 5941 | + cButton skybox5Button; |
---|
| 5942 | + cButton skybox6Button; |
---|
| 5943 | + cButton skybox7Button; |
---|
| 5944 | + |
---|
| 5945 | + cButton skybox11Button; |
---|
| 5946 | + cButton skybox12Button; |
---|
| 5947 | + cButton skybox13Button; |
---|
| 5948 | + cButton skybox14Button; |
---|
| 5949 | + cButton skybox15Button; |
---|
| 5950 | + cButton skybox16Button; |
---|
| 5951 | + cButton skybox17Button; |
---|
| 5952 | + |
---|
5679 | 5953 | cButton gridButton; |
---|
5680 | 5954 | cButton boxButton; |
---|
5681 | 5955 | cButton sphereButton; |
---|