import tim.prune.data.NumberUtils;
import tim.prune.data.Track;
import tim.prune.function.Export3dFunction;
+import tim.prune.gui.DialogCloser;
import tim.prune.load.GenericFileFilter;
import tim.prune.threedee.LineDialog;
import tim.prune.threedee.ThreeDModel;
}
_fontName = new JTextField(defaultFont, 12);
_fontName.setAlignmentX(Component.LEFT_ALIGNMENT);
+ _fontName.addKeyListener(new DialogCloser(_dialog));
centralPanel.add(_fontName);
//coordinates of camera
JLabel cameraXLabel = new JLabel(I18nManager.getText("dialog.exportpov.camerax"));
{
FileWriter writer = null;
// find out the line separator for this system
- String lineSeparator = System.getProperty("line.separator");
+ final String lineSeparator = System.getProperty("line.separator");
try
{
// create and scale model
private void writeStartOfFile(FileWriter inWriter, double inModelSize, String inLineSeparator)
throws IOException
{
- inWriter.write("// Pov file produced by Prune - see http://activityworkshop.net/");
+ inWriter.write("// Pov file produced by GpsPrune - see http://activityworkshop.net/");
inWriter.write(inLineSeparator);
inWriter.write(inLineSeparator);
// Select font based on user input
" sphere {",
" <0, 0, 0>, 0.3", // size should depend on model size
" texture {",
- " pigment {color rgb <0.2 1.0 0.2>}",
+ " pigment {color rgb <0.1 0.6 0.1>}", // dark green
" finish { phong 1 }",
" }",
" }",
" sphere {",
" <0, 0, 0>, 0.3", // size should depend on model size
" texture {",
- " pigment {color rgb <0.6 1.0 0.2>}",
+ " pigment {color rgb <0.4 0.9 0.2>}", // green
" finish { phong 1 }",
" }",
" }",
" sphere {",
" <0, 0, 0>, 0.3", // size should depend on model size
" texture {",
- " pigment {color rgb <1.0 1.0 0.1>}",
+ " pigment {color rgb <0.7 0.8 0.2>}", // yellow
" finish { phong 1 }",
" }",
" }",
" sphere {",
" <0, 0, 0>, 0.3", // size should depend on model size
" texture {",
- " pigment {color rgb <1.0 1.0 1.0>}",
+ " pigment {color rgb <0.5 0.8 0.6>}", // greeny
" finish { phong 1 }",
" }",
" }",
" sphere {",
" <0, 0, 0>, 0.3", // size should depend on model size
" texture {",
- " pigment {color rgb <0.1 1.0 1.0>}",
+ " pigment {color rgb <0.2 0.9 0.9>}", // cyan
+ " finish { phong 1 }",
+ " }",
+ " }",
+ "#declare track_sphere5 =",
+ " sphere {",
+ " <0, 0, 0>, 0.3", // size should depend on model size
+ " texture {",
+ " pigment {color rgb <1.0 1.0 1.0>}", // white
" finish { phong 1 }",
" }",
" }",
* @param inLineSeparator line separator to use
* @throws IOException on file writing error
*/
- private void writeLatLongLines(FileWriter inWriter, ThreeDModel inModel, String inLineSeparator)
+ private static void writeLatLongLines(FileWriter inWriter, ThreeDModel inModel, String inLineSeparator)
throws IOException
{
inWriter.write("// Latitude and longitude lines:");
* @param inLineSeparator line separator to use
* @throws IOException on file writing error
*/
- private void writeDataPointsBallsAndSticks(FileWriter inWriter, ThreeDModel inModel, String inLineSeparator)
+ private static void writeDataPointsBallsAndSticks(FileWriter inWriter, ThreeDModel inModel, String inLineSeparator)
throws IOException
{
inWriter.write("// Data points:");
* @param inLineSeparator line separator to use
* @throws IOException on file writing error
*/
- private void writeDataPointsTubesAndWalls(FileWriter inWriter, ThreeDModel inModel, String inLineSeparator)
+ private static void writeDataPointsTubesAndWalls(FileWriter inWriter, ThreeDModel inModel, String inLineSeparator)
throws IOException
{
inWriter.write("// Data points:");
*/
private static byte checkHeightCode(byte inCode)
{
- final byte maxHeightCode = 4;
+ final byte maxHeightCode = 5;
if (inCode < 0) return 0;
if (inCode > maxHeightCode) return maxHeightCode;
return inCode;