> From: Dirk Reiners [mailto:[email protected]] > Sent: Wednesday, July 01, 2009 10:54
> Have you compared the performance of just having a set of single-indexed > triangles to the strips? Going back and forth between them, especially for > a real-time simulation, sounds expensive and probably not necessary on > current graphics hardware. I was expecting triangles, and was surprised that the loader gave me triangle-strips. But I have to deal with it. There are many things in the scene besides tearable cloth, and I'm not sure it makes sense to disable stripping the scene for the sake of a bit of cloth. I'm not placing any restrictions on the input scene. It may arrive through VRML or some other format, as TRIANGLES or TRIANGLE_STRIPs. The texture may or may not be tiled. That's all up to the artist creating the scene. Single-indexing can't preserve colors and textures across tears, unless color and texture values are assigned to new points as they're created by tearing. Even then it's quite problematic because adjacent triangles that share a vertex don't necessarily agree on the texture coordinate at that vertex. If the texture is tiled across the triangle mesh, one triangle may see texture coordinate u=1 while an adjacent triangle may see u=0 at the same vertex. After initial loading, it's only necessary to process the cloth mesh once to get the triangles and reconfigure the index mapping; it doesn't go back and forth. Thereafter, the physics simulation changes the vertex positions. When the cloth tears, it adds new vertex positions and changes triangle position indices. The number of triangles remains constant, and their color and texture indices remain constant. -- Ted ------------------------------------------------------------------------------ _______________________________________________ Opensg-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/opensg-users
