This site is currently read-only as we are migrating to Oracle Forums for an improved community experience. You will not be able to initiate activity until January 31st, when you will be able to use this site as normal.

    Forum Stats

  • 3,890,899 Users
  • 2,269,649 Discussions


What the index means? in setCoordinate(int index...?

843799 Member Posts: 49,999
edited Jan 5, 2002 7:15AM in Java 3D
What the index means? in setCoordinate(int index...?
Although I looked at the API manual, but I still don't get it.
public void setCoordinate(int index,
double[] coordinate)
Sets the coordinate associated with the vertex at the specified index.
index - destination vertex index in this geometry array
coordinate - source array of 3 values containing the new coordinate


  • 843799
    843799 Member Posts: 49,999
    When you create geometry via a GeometryArray object the coords are stored in an array in which the order is important (eg a tri strip uses the last 2 coords and the current to draw a triangle, a tri fan uses the first, last and current to draw a triangle).

    That method allows you to overwrite a coord at a specific point to change the geometry.
This discussion has been closed.