diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/classes/share/javax/media/j3d/IndexedGeometryArrayRetained.java | 4 | ||||
-rw-r--r-- | src/classes/share/javax/media/j3d/IndexedGeometryStripArrayRetained.java | 50 |
2 files changed, 28 insertions, 26 deletions
diff --git a/src/classes/share/javax/media/j3d/IndexedGeometryArrayRetained.java b/src/classes/share/javax/media/j3d/IndexedGeometryArrayRetained.java index b8fdc02..3e0d74d 100644 --- a/src/classes/share/javax/media/j3d/IndexedGeometryArrayRetained.java +++ b/src/classes/share/javax/media/j3d/IndexedGeometryArrayRetained.java @@ -91,7 +91,6 @@ abstract class IndexedGeometryArrayRetained extends GeometryArrayRetained { GeometryArrayRetained cloneNonIndexedGeometry() { GeometryArrayRetained obj = null; - int vOffset; switch (this.geoType) { case GEO_TYPE_INDEXED_LINE_SET: @@ -116,7 +115,8 @@ abstract class IndexedGeometryArrayRetained extends GeometryArrayRetained { vertexAttrCount, vertexAttrSizes); obj.cloneSourceArray = this; obj.unIndexify(this); - + obj.source=source; + return obj; } diff --git a/src/classes/share/javax/media/j3d/IndexedGeometryStripArrayRetained.java b/src/classes/share/javax/media/j3d/IndexedGeometryStripArrayRetained.java index 656b0f5..98293cc 100644 --- a/src/classes/share/javax/media/j3d/IndexedGeometryStripArrayRetained.java +++ b/src/classes/share/javax/media/j3d/IndexedGeometryStripArrayRetained.java @@ -11,7 +11,6 @@ */ package javax.media.j3d; -import java.util.Vector; import java.util.ArrayList; /** @@ -138,29 +137,32 @@ abstract class IndexedGeometryStripArrayRetained extends IndexedGeometryArrayRet } - GeometryArrayRetained cloneNonIndexedGeometry() { - GeometryStripArrayRetained obj = null; - int i; - switch (this.geoType) { - case GEO_TYPE_INDEXED_LINE_STRIP_SET: - obj = new LineStripArrayRetained(); - break; - case GEO_TYPE_INDEXED_TRI_FAN_SET: - obj = new TriangleFanArrayRetained(); - break; - case GEO_TYPE_INDEXED_TRI_STRIP_SET: - obj = new TriangleStripArrayRetained(); - break; - } - obj.createGeometryArrayData(validIndexCount, - (vertexFormat & ~(GeometryArray.BY_REFERENCE|GeometryArray.INTERLEAVED|GeometryArray.USE_NIO_BUFFER)), - texCoordSetCount, texCoordSetMap, - vertexAttrCount, vertexAttrSizes); - obj.unIndexify(this); - obj.setStripVertexCounts(stripIndexCounts); - - return obj; - } + @Override + GeometryArrayRetained cloneNonIndexedGeometry() { + GeometryStripArrayRetained obj = null; + + switch (this.geoType) { + case GEO_TYPE_INDEXED_LINE_STRIP_SET: + obj = new LineStripArrayRetained(); + break; + case GEO_TYPE_INDEXED_TRI_FAN_SET: + obj = new TriangleFanArrayRetained(); + break; + case GEO_TYPE_INDEXED_TRI_STRIP_SET: + obj = new TriangleStripArrayRetained(); + break; + } + obj.createGeometryArrayData(validIndexCount, + (vertexFormat & ~(GeometryArray.BY_REFERENCE|GeometryArray.INTERLEAVED|GeometryArray.USE_NIO_BUFFER)), + texCoordSetCount, texCoordSetMap, + vertexAttrCount, vertexAttrSizes); + obj.unIndexify(this); + obj.setStripVertexCounts(stripIndexCounts); + obj.cloneSourceArray = this; + obj.source = source; + + return obj; + } /** |