aboutsummaryrefslogtreecommitdiffstats
path: root/src/classes/share
diff options
context:
space:
mode:
authorHarvey Harrison <[email protected]>2012-11-18 15:52:09 -0800
committerHarvey Harrison <[email protected]>2012-11-18 15:52:09 -0800
commit9fcef4ebc1d2596384e580926993ef36ff509c9e (patch)
tree51b4c8354aad84b5d2e822df9b9c66ee377bb563 /src/classes/share
parent7959ae7d3ec88869d131e25165e4ce4c09314e15 (diff)
j3dcore: remove some more dead D3D code
Signed-off-by: Harvey Harrison <[email protected]>
Diffstat (limited to 'src/classes/share')
-rw-r--r--src/classes/share/javax/media/j3d/RenderAtom.java87
-rw-r--r--src/classes/share/javax/media/j3d/RenderMolecule.java63
-rw-r--r--src/classes/share/javax/media/j3d/TexCoordGenerationRetained.java8
3 files changed, 68 insertions, 90 deletions
diff --git a/src/classes/share/javax/media/j3d/RenderAtom.java b/src/classes/share/javax/media/j3d/RenderAtom.java
index 3129f9f..66e202b 100644
--- a/src/classes/share/javax/media/j3d/RenderAtom.java
+++ b/src/classes/share/javax/media/j3d/RenderAtom.java
@@ -195,55 +195,48 @@ class RenderAtom extends Object implements ObjectUpdate {
TransparencyAttributesRetained ta = app.transparencyAttributes;
- if (!VirtualUniverse.mc.isD3D()) {
- // D3D doesn't support line/point antialiasing
- switch (geometryAtom.geoType) {
- case GeometryRetained.GEO_TYPE_POINT_SET:
- case GeometryRetained.GEO_TYPE_INDEXED_POINT_SET:
- if ((app.pointAttributes != null) &&
- app.pointAttributes.pointAntialiasing) {
- return false;
- }
- break;
- case GeometryRetained.GEO_TYPE_LINE_SET:
- case GeometryRetained.GEO_TYPE_LINE_STRIP_SET:
- case GeometryRetained.GEO_TYPE_INDEXED_LINE_SET:
- case GeometryRetained.GEO_TYPE_INDEXED_LINE_STRIP_SET:
- if ((app.lineAttributes != null) &&
- app.lineAttributes.lineAntialiasing) {
- return false;
- }
- break;
- case GeometryRetained.GEO_TYPE_RASTER:
- case GeometryRetained.GEO_TYPE_COMPRESSED:
- break;
- default:
- if (app.polygonAttributes != null) {
- if ((app.polygonAttributes.polygonMode ==
- PolygonAttributes.POLYGON_POINT) &&
- (app.pointAttributes != null) &&
- app.pointAttributes.pointAntialiasing) {
- return false;
- } else if ((app.polygonAttributes.polygonMode ==
- PolygonAttributes.POLYGON_LINE) &&
- (app.lineAttributes != null) &&
- app.lineAttributes.lineAntialiasing) {
- return false;
- }
- }
- break;
+ switch (geometryAtom.geoType) {
+ case GeometryRetained.GEO_TYPE_POINT_SET:
+ case GeometryRetained.GEO_TYPE_INDEXED_POINT_SET:
+ if ((app.pointAttributes != null) &&
+ app.pointAttributes.pointAntialiasing) {
+ return false;
+ }
+ break;
+ case GeometryRetained.GEO_TYPE_LINE_SET:
+ case GeometryRetained.GEO_TYPE_LINE_STRIP_SET:
+ case GeometryRetained.GEO_TYPE_INDEXED_LINE_SET:
+ case GeometryRetained.GEO_TYPE_INDEXED_LINE_STRIP_SET:
+ if ((app.lineAttributes != null) &&
+ app.lineAttributes.lineAntialiasing) {
+ return false;
+ }
+ break;
+ case GeometryRetained.GEO_TYPE_RASTER:
+ case GeometryRetained.GEO_TYPE_COMPRESSED:
+ break;
+ default:
+ if (app.polygonAttributes != null) {
+ if ((app.polygonAttributes.polygonMode ==
+ PolygonAttributes.POLYGON_POINT) &&
+ (app.pointAttributes != null) &&
+ app.pointAttributes.pointAntialiasing) {
+ return false;
+ } else if ((app.polygonAttributes.polygonMode ==
+ PolygonAttributes.POLYGON_LINE) &&
+ (app.lineAttributes != null) &&
+ app.lineAttributes.lineAntialiasing) {
+ return false;
}
-
- return ((ta == null) ||
- (ta.transparencyMode ==
- TransparencyAttributes.NONE) ||
- (ta.transparencyMode ==
- TransparencyAttributes.SCREEN_DOOR));
- } else {
- return ((ta == null) ||
- (ta.transparencyMode ==
- TransparencyAttributes.NONE));
}
+ break;
+ }
+
+ return ((ta == null) ||
+ (ta.transparencyMode ==
+ TransparencyAttributes.NONE) ||
+ (ta.transparencyMode ==
+ TransparencyAttributes.SCREEN_DOOR));
}
boolean inRenderBin() {
diff --git a/src/classes/share/javax/media/j3d/RenderMolecule.java b/src/classes/share/javax/media/j3d/RenderMolecule.java
index 98aae33..0b214d3 100644
--- a/src/classes/share/javax/media/j3d/RenderMolecule.java
+++ b/src/classes/share/javax/media/j3d/RenderMolecule.java
@@ -2395,43 +2395,36 @@ class RenderMolecule extends IndexedObject implements ObjectUpdate, NodeComponen
boolean isOpaque() {
- if (!VirtualUniverse.mc.isD3D()) {
- // D3D doesn't support line/point antialiasing
- if ((geometryType & SURFACE) != 0) {
- if (definingPolygonAttributes != null) {
- if ((definingPolygonAttributes.polygonMode ==
- PolygonAttributes.POLYGON_POINT) &&
- (definingPointAttributes != null) &&
- definingPointAttributes.pointAntialiasing) {
- return false;
- } else if ((definingPolygonAttributes.polygonMode ==
- PolygonAttributes.POLYGON_LINE) &&
- (definingLineAttributes != null) &&
- definingLineAttributes.lineAntialiasing) {
- return false;
- }
- }
- } else if ((geometryType & POINT) != 0) {
- if ((definingPointAttributes != null) &&
- definingPointAttributes.pointAntialiasing) {
- return false;
- }
- } else if ((geometryType & LINE) != 0) {
- if ((definingLineAttributes != null) &&
- definingLineAttributes.lineAntialiasing) {
- return false;
- }
+ if ((geometryType & SURFACE) != 0) {
+ if (definingPolygonAttributes != null) {
+ if ((definingPolygonAttributes.polygonMode ==
+ PolygonAttributes.POLYGON_POINT) &&
+ (definingPointAttributes != null) &&
+ definingPointAttributes.pointAntialiasing) {
+ return false;
+ } else if ((definingPolygonAttributes.polygonMode ==
+ PolygonAttributes.POLYGON_LINE) &&
+ (definingLineAttributes != null) &&
+ definingLineAttributes.lineAntialiasing) {
+ return false;
}
- return ((definingTransparency == null) ||
- (definingTransparency.transparencyMode ==
- TransparencyAttributes.NONE) ||
- (definingTransparency.transparencyMode ==
- TransparencyAttributes.SCREEN_DOOR));
- } else {
- return ((definingTransparency == null) ||
- (definingTransparency.transparencyMode ==
- TransparencyAttributes.NONE));
}
+ } else if ((geometryType & POINT) != 0) {
+ if ((definingPointAttributes != null) &&
+ definingPointAttributes.pointAntialiasing) {
+ return false;
+ }
+ } else if ((geometryType & LINE) != 0) {
+ if ((definingLineAttributes != null) &&
+ definingLineAttributes.lineAntialiasing) {
+ return false;
+ }
+ }
+ return ((definingTransparency == null) ||
+ (definingTransparency.transparencyMode ==
+ TransparencyAttributes.NONE) ||
+ (definingTransparency.transparencyMode ==
+ TransparencyAttributes.SCREEN_DOOR));
}
diff --git a/src/classes/share/javax/media/j3d/TexCoordGenerationRetained.java b/src/classes/share/javax/media/j3d/TexCoordGenerationRetained.java
index 5812b8d..85aee97 100644
--- a/src/classes/share/javax/media/j3d/TexCoordGenerationRetained.java
+++ b/src/classes/share/javax/media/j3d/TexCoordGenerationRetained.java
@@ -272,7 +272,6 @@ class TexCoordGenerationRetained extends NodeComponentRetained {
void updateNative(Canvas3D cv) {
int gMode = genMode;
- Transform3D trans = null;
Transform3D m = cv.vworldToEc;
if (((cv.textureExtendedFeatures & Canvas3D.TEXTURE_CUBE_MAP) == 0) &&
@@ -281,13 +280,6 @@ class TexCoordGenerationRetained extends NodeComponentRetained {
gMode = TexCoordGeneration.SPHERE_MAP;
}
- if (VirtualUniverse.mc.isD3D() &&
- (gMode == TexCoordGeneration.EYE_LINEAR)) {
- trans = new Transform3D(cv.vworldToEc);
- trans.invert();
- m = trans;
- }
-
Pipeline.getPipeline().updateTexCoordGeneration(cv.ctx,
enable, gMode, format, planeS.x, planeS.y, planeS.z,
planeS.w, planeT.x, planeT.y, planeT.z, planeT.w,