I use osg without osgUtils::SceneView and it works very well
188void Renderer::draw(Drawable* drawable)
189{
190 EASY3D_ASSERT(drawable && "No Drawable");
191 StateSet* s = drawable->getStateSet();
192 _state->apply(s);
193#if OPENSCENEGRAPH_VERSION > 120
194 drawable->drawImplementation(_renderInfo);
195#else
196 drawable->drawImplementation(*_state);
197#endif
198}
you can see the code here:
http://hg.plopbyte.net/easy3d/file/20d208265c5d/easy3d/renderer.cpp
I hope it will help
Robert Osfield wrote:
> Hi John,
>
> The closest code to what you are trying to achieve can be found in the
> osgProducer projects src/osgProducer/ViewerEventHandler.cpp where is
> sets up the and renders the stats and help.
>
> In 2.x and osgViewer's stats and help I just go ahead and use a full
> blown scene graph as it makes more things just more straight forward.
>
> Robert.
>
> On 8/27/07, Argentieri, John-P63223 <[EMAIL PROTECTED]> wrote:
>
>>
>> Hello all, and long time no see!
>>
>> I am trying to create an osgText::Text object and call drawImplementation on
>> it manually. I think it is almost working. Here is how I am setting up the
>> RenderInfo that I am passing in:
>>
>> spState = new osg::State();
>> spViewState =
>> spSceneView->getRenderInfo().getState();
>> if( spViewState.valid() )
>> {
>> spState->setGraphicsContext(
>> spViewState->getGraphicsContext() );
>> spState->setContextID( spViewState->getContextID() );
>> }
>> renderInfo = osg::RenderInfo( spState.get(), spSceneView->getView()
>> );
>>
>> The problem is, that the textures are being lost. Can anyone help me to
>> accomplish this without adding the osgText::Text to the sceneview's scene
>> data?
>>
>>
>> Much appreciated!
>> John
>> _______________________________________________
>> osg-users mailing list
>> [email protected]
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>>
>>
>>
> _______________________________________________
> osg-users mailing list
> [email protected]
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org