> Date: Sat, 5 Feb 2000 20:16:06 +0100
> From: Julian Scheid <[EMAIL PROTECTED]>
> Therefore it is always faster to use an indexed geometry whenever there are
> shared vertices - and most objects share many vertices.
No, not for Java 3D. To actually render geometry it uses native graphics
APIs, such as OpenGL, which are oriented toward hardware acceleration.
Almost all commercial 3D graphics accelerators require vertices to be
transmitted as linear streams of data; there is no way in such hardware to
store and reference more than a few vertices at a time, which prevents the
direct hardware rendering of indexed geometry. Such data is expanded by
Java 3D into non-indexed representations before transmission to the API,
which consumes even more memory and time than directly using non-indexed
representations such as GeometryArray to begin with.
Most graphics acclerators can remember the last two vertices of the last
triangle they rendered, which allows an efficient accelerated rendering for
StripArrays. These representations can approach 1 vertex per triangle
depending upon the topology of the source geometry and the algorithms used
to construct them. Java 3D provides a utility Stripifier class to allow
applications to reorder the vertices of their geometry into strips that
share vertex data between abutting polygons.
Indexed geometry is an efficient and compact way of representing and
manipulating geometry in application data structures, but is less than
optimal for hardware rendering. Since Java 3D doesn't implement a pure Java
software renderer (the native software rendering APIs would be far faster),
the indexed geometry node components should be considered primarily a
convenience feature for applications already storing data in indexed
formats.
-- Mark Hood
===========================================================================
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".