Hi Oliver,
On Wed, 2005-10-12 at 13:17 +0200, Oliver Kutter wrote:
> Hi,
>
> I want to use ImageRefPtr for some images. I want to set them to a
> texture chunk and I want to change the images of the texture. I use the
> ImageRefPtr, so that the other images won't be deleted, because I need
> them anymore.
>
> But when I want to set the first image to the texture (like this)
>
> texChunk->setImage(images[currentID]);
>
> my compiler give me this:
>
> error: no matching function for call to
> `osg::TextureChunk::setImage(osg::RefPtr<osg::ImagePtr>&)'
> /usr/local/include/OpenSG/OSGTextureChunk.inl:60: error: candidates are:
> void osg::TextureChunk::setImage(osg::ImagePtr&)
>
>
> When I change it to this
>
> texChunk->setImage(images[currentID].get());
>
> then my compiler says this:
>
> error: no matching function for call to
> `osg::TextureChunk::setImage(osg::ImagePtr)'
> /usr/local/include/OpenSG/OSGTextureChunk.inl:60: error: candidates are:
> void osg::TextureChunk::setImage(osg::ImagePtr&)
>
> Does anyone know the correct usage?
the workaround is
osg::ImagePtr i = images[currentID];
texChunk->setImage(i);
It's ugly, I agree, but I'm not sure how to fix it without introducing
some dangerous side effects.
Dirk
-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users