On 7/16/07, Amal <[EMAIL PROTECTED]> wrote:
So Since I have only Shader code to be used to draw the Cubic I was thinking
I should be implementing the drawImplementation Function of the
osg::Drawable after subclassing it.

But Now I understand that I can just subclass from the osg::Node and which
can use the Shader and render the cubic and i need not have the
osg::Drawable at all .

Am I right ?

Yes, you want a custom Node that provides the public methods for
controlling the cubic and have this set up the Uniform and Shaders and
subgraph with osg::Geometry appropriate for these settings.  As far as
the user is concerned they would just have a CubicNode or whetever you
want to call it, and they set the values on it add it to the scene
graph and hey presto pretty graphics appear.

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to