Here is my best advice....
Don't use IndexAnything.
Unless it makes your code simpler. Java3d will just expand it anyway and
send the unindexed version to the card.
Dave Yazel
> ----------
> From: R Wang[SMTP:[EMAIL PROTECTED]]
> Reply To: Discussion list for Java 3D API
> Sent: Friday, December 15, 2000 2:45 PM
> To: [EMAIL PROTECTED]
> Subject: [JAVA3D] Again, setValidVertexCount in IndexedGeometryArray
>
> Hello guys, from some old posts I learned that setValidVertexCount()
> in IndexedGeometryArray will actually apply to the index arrays. But for
> some reason it just won't work here in my program. Here's what my example
> code looks like:
>
> IndexedQuadArray ga = new IndexedQuadArray(100,
> GeometryArray.COORDINATES | GeometryArray.BY_REFERENCE,
> 200);
> ga.setCapability(GeometryArray.ALLOW_COUNT_WRITE);
>
> float[] mfCoordinates = new float[100*3];
> int[] miCoordIndices = new int[200];
> ....
> ga.setCoordRefFloat(mfCoordinates);
> ga.setCoordinateIndices(0, miCoordIndices);
>
> now if I setValidVertexCount(200), it'll have an exception like
> "initialVertexIndex + validVertexCount > vertexCount". (InitialIndex is
> 0).
> It seemed to apply to the vertex array. Even if I setValidVertexCount(80),
> it still doesn't look right. The whole geometry array is rendered but not
> the first 80 indices.
>
> Can anyone give an example codes that works?
>
> thanks in advance.
>
> -Ruopeng
>
> ==========================================================================
> =
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
> body
> of the message "signoff JAVA3D-INTEREST". For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
>
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".