summaryrefslogtreecommitdiffstats
path: root/src/jogl/classes/jogamp/opengl/glu/GLUquadricImpl.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2014-07-08 22:10:03 +0200
committerSven Gothel <[email protected]>2014-07-08 22:10:03 +0200
commitde53d193c86a02a3cdc46c5c8758192d957d1c67 (patch)
tree8be8e36381d6f25850b887c9ff0df7e9c2279487 /src/jogl/classes/jogamp/opengl/glu/GLUquadricImpl.java
parentbe2b608e22d9a2a3a80eb547bee6180c2ca22678 (diff)
Findbugs: Misc minor issues (see below)
- remove duplicate code in branch - Use Type.valueOf(primitive) - Don't use array.toString() directly - remove dead code
Diffstat (limited to 'src/jogl/classes/jogamp/opengl/glu/GLUquadricImpl.java')
-rw-r--r--src/jogl/classes/jogamp/opengl/glu/GLUquadricImpl.java12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/jogl/classes/jogamp/opengl/glu/GLUquadricImpl.java b/src/jogl/classes/jogamp/opengl/glu/GLUquadricImpl.java
index a6952ec5a..c91a045ae 100644
--- a/src/jogl/classes/jogamp/opengl/glu/GLUquadricImpl.java
+++ b/src/jogl/classes/jogamp/opengl/glu/GLUquadricImpl.java
@@ -463,21 +463,21 @@ public class GLUquadricImpl implements GLUquadric {
x = sin((i * da));
y = cos((i * da));
}
- if (nsign == 1.0f) {
+ // if (nsign == 1.0f) {
normal3f(gl, (x * nsign), (y * nsign), (nz * nsign));
TXTR_COORD(gl, s, t);
glVertex3f(gl, (x * r), (y * r), z);
normal3f(gl, (x * nsign), (y * nsign), (nz * nsign));
TXTR_COORD(gl, s, t + dt);
glVertex3f(gl, (x * (r + dr)), (y * (r + dr)), (z + dz));
- } else {
+ /* } else {
normal3f(gl, x * nsign, y * nsign, nz * nsign);
TXTR_COORD(gl, s, t);
glVertex3f(gl, (x * r), (y * r), z);
normal3f(gl, x * nsign, y * nsign, nz * nsign);
TXTR_COORD(gl, s, t + dt);
glVertex3f(gl, (x * (r + dr)), (y * (r + dr)), (z + dz));
- }
+ } */
s += ds;
} // for slices
glEnd(gl);
@@ -625,7 +625,7 @@ public class GLUquadricImpl implements GLUquadric {
if (innerRadius != 0.0) {
float a;
glBegin(gl, GL.GL_LINE_LOOP);
- for (a = 0.0f; a < 2.0 * PI; a += da) {
+ for (a = 0.0f; a < PI_2; a += da) {
final float x = innerRadius * sin(a);
final float y = innerRadius * cos(a);
glVertex2f(gl, x, y);
@@ -635,7 +635,7 @@ public class GLUquadricImpl implements GLUquadric {
{
float a;
glBegin(gl, GL.GL_LINE_LOOP);
- for (a = 0; a < 2.0f * PI; a += da) {
+ for (a = 0; a < PI_2; a += da) {
final float x = outerRadius * sin(a);
final float y = outerRadius * cos(a);
glVertex2f(gl, x, y);
@@ -1120,7 +1120,7 @@ public class GLUquadricImpl implements GLUquadric {
//
private static final float PI = FloatUtil.PI;
- private static final float PI_2 = 2f * FloatUtil.PI;
+ private static final float PI_2 = 2f * PI;
private static final int CACHE_SIZE = 240;
private final void glBegin(final GL gl, final int mode) {