📄 geometryarray.java
字号:
* or when the data mode is <code>INTERLEAVED</code>. * @return the current initial vertex index for this GeometryArray object. * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * * @since Java 3D 1.2 */ public int getInitialVertexIndex() { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COUNT_READ)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray91")); return ((GeometryArrayRetained)this.retained).getInitialVertexIndex(); } /** * Sets the coordinate associated with the vertex at * the specified index for this object. * @param index destination vertex index in this geometry array * @param coordinate source array of 3 values containing the new coordinate * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinate(int index, float coordinate[]) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray3")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinate(index, coordinate); } /** * Sets the coordinate associated with the vertex at * the specified index. * @param index destination vertex index in this geometry array * @param coordinate source array of 3 values containing the new coordinate * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinate(int index, double coordinate[]) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray3")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinate(index, coordinate); } /** * Sets the coordinate associated with the vertex at * the specified index for this object. * @param index destination vertex index in this geometry array * @param coordinate a point containing the new coordinate * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinate(int index, Point3f coordinate) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray3")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinate(index, coordinate); } /** * Sets the coordinate associated with the vertex at * the specified index for this object. * @param index destination vertex index in this geometry array * @param coordinate a point containing the new coordinate * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinate(int index, Point3d coordinate) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray3")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinate(index, coordinate); } /** * Sets the coordinates associated with the vertices starting at * the specified index for this object. The entire source array is * copied to this geometry array. * @param index starting destination vertex index in this geometry array * @param coordinates source array of 3*n values containing n new coordinates * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinates(int index, float coordinates[]) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray7")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinates(index, coordinates); } /** * Sets the coordinates associated with the vertices starting at * the specified index for this object. The entire source array is * copied to this geometry array. * @param index starting destination vertex index in this geometry array * @param coordinates source array of 3*n values containing n new coordinates * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinates(int index, double coordinates[]) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray7")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinates(index, coordinates); } /** * Sets the coordinates associated with the vertices starting at * the specified index for this object. The entire source array is * copied to this geometry array. * @param index starting destination vertex index in this geometry array * @param coordinates source array of points containing new coordinates * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinates(int index, Point3f coordinates[]) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray7")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinates(index, coordinates); } /** * Sets the coordinates associated with the vertices starting at * the specified index for this object. The entire source array is * copied to this geometry array. * @param index starting destination vertex index in this geometry array * @param coordinates source array of points containing new coordinates * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinates(int index, Point3d coordinates[]) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray7")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinates(index, coordinates); } /** * Sets the coordinates associated with the vertices starting at * the specified index for this object using coordinate data starting * from vertex index <code>start</code> for <code>length</code> vertices. * @param index starting destination vertex index in this geometry array * @param coordinates source array of 3*n values containing n new coordinates * @param start starting source vertex index in <code>coordinates</code> array. * @param length number of vertices to be copied. * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinates(int index, float coordinates[], int start, int length) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray7")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinates(index, coordinates, start, length); } /** * Sets the coordinates associated with the vertices starting at * the specified index for this object using coordinate data starting * from vertex index <code>start</code> for <code>length</code> vertices. * @param index starting destination vertex index in this geometry array * @param coordinates source array of 3*n values containing n new coordinates * @param start starting source vertex index in <code>coordinates</code> array. * @param length number of vertices to be copied. * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinates(int index, double coordinates[], int start, int length) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray7")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinates(index, coordinates, start, length); } /** * Sets the coordinates associated with the vertices starting at * the specified index for this object using coordinate data starting * from vertex index <code>start</code> for <code>length</code> vertices. * @param index starting destination vertex index in this geometry array * @param coordinates source array of points containing new coordinates * @param start starting source vertex index in <code>coordinates</code> array. * @param length number of vertices to be copied. * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinates(int index, Point3f coordinates[], int start, int length) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray7")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinates(index, coordinates, start, length); } /** * Sets the coordinates associated with the vertices starting at * the specified index for this object using coordinate data starting * from vertex index <code>start</code> for <code>length</code> vertices. * @param index starting destination vertex index in this geometry array * @param coordinates source array of points containing new coordinates * @param start starting source vertex index in <code>coordinates</code> array. * @param length number of vertices to be copied. * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception IllegalStateException if the data mode for this geometry * array object is <code>BY_REFERENCE</code>. */ public void setCoordinates(int index, Point3d coordinates[], int start, int length) { if (isLiveOrCompiled()) if(!this.getCapability(ALLOW_COORDINATE_WRITE)) throw new CapabilityNotSetException(J3dI18N.getString("GeometryArray7")); int format = ((GeometryArrayRetained)this.retained).vertexFormat; if ((format & BY_REFERENCE) != 0) throw new IllegalStateException(J3dI18N.getString("GeometryArray82")); ((GeometryArrayRetained)this.retained).setCoordinates(index, coordinates, start, length); } /** * Sets the color associated with the vertex at * the specified index for this object. * @param index destination vertex index in this geometry array * @param color source array of 3 or 4 values containing the new color * @exception CapabilityNotSetException if the appropriate capability is * not set and this object is part of a live or compiled scene graph * @exception ArrayIndexOutOfBoun
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -