-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0e92241
commit 88229a6
Showing
25 changed files
with
105 additions
and
131 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
src/main/java/PanoViewer/Camera.java → src/main/java/org/panoviewer/Camera.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/PanoViewer/FileChooser.java → ...main/java/org/panoviewer/FileChooser.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/PanoViewer/LookFeel.java → src/main/java/org/panoviewer/LookFeel.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
src/main/java/PanoViewer/MainScreen.java → src/main/java/org/panoviewer/MainScreen.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/PanoViewer/Mode.java → src/main/java/org/panoviewer/Mode.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/PanoViewer/PanoViewer.java → src/main/java/org/panoviewer/PanoViewer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
// License: GPL. For details, see LICENSE file. | ||
package PanoViewer; | ||
package org.panoviewer; | ||
|
||
/** | ||
* | ||
|
2 changes: 1 addition & 1 deletion
2
src/main/java/PanoViewer/Settings.java → src/main/java/org/panoviewer/Settings.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
src/main/java/PanoViewer/SwitchModes.java → ...main/java/org/panoviewer/SwitchModes.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 3 additions & 3 deletions
6
...main/java/PanoViewer/gui/AboutDialog.java → .../java/org/panoviewer/gui/AboutDialog.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...main/java/PanoViewer/gui/ImageViewer.java → .../java/org/panoviewer/gui/ImageViewer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 5 additions & 5 deletions
10
src/main/java/PanoViewer/gui/Menu.java → src/main/java/org/panoviewer/gui/Menu.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/PanoViewer/gui/Pannable.java → ...ain/java/org/panoviewer/gui/Pannable.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
src/main/java/PanoViewer/gui/ZoomPanLis.java → ...n/java/org/panoviewer/gui/ZoomPanLis.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/main/java/PanoViewer/gui/Zoomable.java → ...ain/java/org/panoviewer/gui/Zoomable.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
// License: GPL. For details, see LICENSE file. | ||
package PanoViewer.gui; | ||
package org.panoviewer.gui; | ||
|
||
/** | ||
* | ||
|
6 changes: 3 additions & 3 deletions
6
...n/java/PanoViewer/gui/jogl/FlatPanel.java → ...va/org/panoviewer/gui/jogl/FlatPanel.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
.../PanoViewer/gui/jogl/JOGLImageViewer.java → .../panoviewer/gui/jogl/JOGLImageViewer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
12 changes: 6 additions & 6 deletions
12
...a/PanoViewer/gui/jogl/PanoramicPanel.java → ...g/panoviewer/gui/jogl/PanoramicPanel.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
src/main/java/PanoViewer/math/Sphere.java → ...main/java/org/panoviewer/math/Sphere.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...ain/java/PanoViewer/Utils/imageutils.java → ...java/org/panoviewer/utils/imageutils.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 4 additions & 4 deletions
8
...main/java/PanoViewer/Utils/joglUtils.java → .../java/org/panoviewer/utils/joglUtils.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
// License: GPL. For details, see LICENSE file. | ||
package org.panoviewer; | ||
|
||
import junit.framework.TestCase; | ||
import org.junit.Test; | ||
|
||
/** | ||
* Tests {@link Camera} | ||
*/ | ||
public class CameraTest extends TestCase { | ||
|
||
public CameraTest() { | ||
} | ||
|
||
@Test | ||
public void Camera_test() { | ||
Camera camera_new = new Camera(); | ||
double epsilon = 0.00001; | ||
assertEquals(true, camera_new.getYaw() - (0) < epsilon); | ||
} | ||
|
||
@Test | ||
public void rotate_test() { | ||
Camera rotate_test = new Camera(); | ||
double epsilon = 1e-5; | ||
|
||
rotate_test.rotate((float) (Math.PI / 4), (float) (Math.PI / 4)); | ||
assertTrue(rotate_test.getYaw() <= 2 * Math.PI + epsilon); | ||
assertTrue(rotate_test.getYaw() >= 0 - epsilon); | ||
assertEquals((float) (Math.PI / 4), rotate_test.getYaw(), epsilon); | ||
assertTrue(Math.abs(rotate_test.getPitch() - Math.PI / 4) < epsilon); | ||
|
||
rotate_test.rotate((float) (3 * Math.PI / 4), (float) (Math.PI / 2)); | ||
assertTrue(rotate_test.getYaw() <= 2 * Math.PI + epsilon); | ||
assertTrue(rotate_test.getYaw() >= 0 - epsilon); | ||
assertTrue(rotate_test.getPitch() <= Math.PI / 2 + epsilon); | ||
assertTrue(rotate_test.getPitch() >= -Math.PI / 2 - epsilon); | ||
assertTrue(rotate_test.getYaw() + epsilon >= (float) (3 / 2 * Math.PI)); | ||
assertTrue(rotate_test.getYaw() - epsilon <= (float) (3 / 2 * Math.PI)); | ||
assertTrue(rotate_test.getPitch() + epsilon >= (float) (Math.PI / 2)); | ||
assertTrue(rotate_test.getPitch() - epsilon <= (float) (Math.PI / 2)); | ||
|
||
rotate_test.rotate((float) (4 / 3 * Math.PI), (float) (7 / 4 * Math.PI)); | ||
assertTrue(rotate_test.getYaw() <= 2 * Math.PI + epsilon); | ||
assertTrue(rotate_test.getYaw() >= 0 - epsilon); | ||
assertTrue(rotate_test.getYaw() + epsilon >= (float) (4 / 6 * Math.PI)); | ||
assertTrue(rotate_test.getYaw() - epsilon <= (float) (4 / 6 * Math.PI)); | ||
assertTrue(rotate_test.getPitch() <= Math.PI / 2 + epsilon); | ||
assertTrue(rotate_test.getPitch() >= -Math.PI / 2 - epsilon); | ||
} | ||
} |