Hi Shuxing, On 4/26/07, Shuxing Xiao <[EMAIL PROTECTED]> wrote:
I searched the former discussion, and I got that it's better to bind attribute per vertex but per primitive,
Its better to bind per vertex or bind overall or bind per primitive set, all these options can keep you on OpenGL fast paths - small number of OpenGL calls to dispatch the data. Bind per primitive forces the OSG down on OpenGL slow paths - large number of OpenGL to dispatch the data.
because bind attribute per primitive will force the geometry not to use fast path (though I don't know what a fast path is), When dealing with Triangle strip, how to transform attribute per primitive to the GLSL shader?
Do not use slow paths, its slow... use fast paths where possible. GLSL shaders are totally orthogonal to how you pass vertex and primitive data, so they don't care how the data is passed in.
Because I want every triangle in the triangle strip to have different color I specified but not the color bilinear interpolated from the three vertices. Which on should I choose, bind attribute per vertex or
I'd recommend that you spend some time learning about OpenGL, it'll help you understand how to use the OSG as it just passes data onto OpenGL in mapping that is close to 1:1. Robert. _______________________________________________ osg-users mailing list [email protected] http://openscenegraph.net/mailman/listinfo/osg-users http://www.openscenegraph.org/
