There is something weird here...is the problem case dependent ?
I went back and checked whether the USE_COORD_INDEX_ONLY bit was
ignored when you retrieve an IndexedGeometryArray from GeometryInfo.
As I indicated previously, in my special case at least, IT IS NOT.
IIRC, if you run NormalGenerator on un-indexed tris, they would
be automatically converted to indexed tris.
For example, here is the sequence I am using:
GeometryInfo gi = new GeometryInfo( GeometryInfo.TRIANGLE_ARRAY );
gi.setCoordinates( triangleCoordinates );
NormalGenerator ng = new NormalGenerator();
ng.generateNormals( gi );
IndexedGeometryArray iga =
gi.getIndexedGeometryArray( false, false, false, true, false );
int vertexFormat = iga.getVertexFormat();
if ( ( vertexFormat & IndexedGeometryArray.USE_COORD_INDEX_ONLY )
== IndexedGeometryArray.USE_COORD_INDEX_ONLY ) )
{
System.out.println("The CoordIndexBit is Definitely SET !!!");
}
I do get confirmation printout indicating that the bit is indeed set.
Regards
Raj
>On Thu, 11 Apr 2002 18:45:36 +0200, Artur Biesiadowski <[EMAIL PROTECTED]> wrote:
>Chien Yang wrote:
>> Artur,
>> Thanks! It looks like a Java 3D util. bug. A bug report has been
>> file for your tracking :
>>
>> Bug Id: 4666597 - GeometryInfo - usecoordonly bit is discarded in
>> convertToIndexedTriangles().
>
>I suppose that it has something to do with NormalGenerator. Without it
>I'm able to create coord-index geometry.
>
>Artur
>
> ==========================================================================
>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".