Hi Community,

me again on this issue. As I mentioned in my previous post, I figured out a
way how to wrap a OpejnGL texture created externaly with OpenGL calls into
osg::Texture. Following is the code snippet for that and it seam to be
working. However when I run the app I am getting this warning. Any clue?

"TextureObjectManager::releaseTextureObject(Texture::TextureObject* to) Not
implemented yet

GLuint textureHandle = (GLuint)texHandle;

_texture = new osg::Texture2D;

osg::ref_ptr<osg::Texture::TextureObject> textureObject = new
osg::Texture::TextureObject(_texture.get(),textureHandle,GL_TEXTURE_2D);
textureObject->setAllocated();

_texture->setTextureObject(renderInfo.getContextID(),textureObject.get());
state.setActiveTextureUnit(_textureStage);
_texture->apply( state );

// Tell state about our changes
state.haveAppliedTextureAttribute(_textureStage, _texture.get());

Thanks a bunch!

Nick


On Sat, Oct 5, 2013 at 5:10 PM, Trajce Nikolov NICK <
trajce.nikolov.n...@gmail.com> wrote:

> Found the way, it is possible. Thanks anyway ! :-)
>
> Nick
>
>
> On Sat, Oct 5, 2013 at 4:16 PM, Trajce Nikolov NICK <
> trajce.nikolov.n...@gmail.com> wrote:
>
>> Hi Community,
>>
>> I ran into a topic of this mentioned in the subject. I am using 3rd party
>> SDK (OpenGL) with OSG and I get a texture created by this SDK. Is there a
>> way to wrap it into osg TextureObject and have it all osg-ish without
>> mixing with GL calls?
>>
>> Thanks a bunch!
>>
>> Nick
>>
>> --
>> trajce nikolov nick
>>
>
>
>
> --
> trajce nikolov nick
>



-- 
trajce nikolov nick
_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to