Hi,
Thanks fo the details.
Thank you!
Cheers,
Gaëtan
--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=54530#54530
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.opensceneg
On 10 June 2013 18:10, Gaëtan André wrote:
>
> reflectionMap->setFilter(osg::TextureCubeMap::MIN_FILTER,osg::TextureCubeMap::LINEAR);
>
> reflectionMap->setFilter(osg::TextureCubeMap::MAG_FILTER,osg::TextureCubeMap::LINEAR);
>
> These two line solved my problem.
>
> What is the default f
Hi,
reflectionMap->setFilter(osg::TextureCubeMap::MIN_FILTER,osg::TextureCubeMap::LINEAR);
reflectionMap->setFilter(osg::TextureCubeMap::MAG_FILTER,osg::TextureCubeMap::LINEAR);
These two line solved my problem.
What is the default filter and why does not it work with it ?
Thank you!
Hi,
Thanks again for replying.
In my code
camera->setRenderOrder(osg::Camera::PRE_RENDER);
is present.
I looked at the examples, there does not seem to have much difference.
Cheers,
Gaëtan
--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=54521#54
Hi Gaëtan,
On 10 June 2013 15:26, Gaëtan André wrote:
> Then this CubeMap is used twice per cycle.
>
> First on a object, via shaders.
> Second on two quads,displayed by a HUD camera (in order to see what is in the
> map).
>
> On the object, a still image is displayed corresponding to a render
Hi,
I followed your advice and applied directly the cubemap on the quad using 3D
texture coordinates.
Allow me to ask another question are things are very weird !
I render the scene in the CubeMap
Code:
reflectionMap = new osg::TextureCubeMap;
reflectionMap->setTextureSize( 256, 256 );
Hi Gaëtan,
There is too much information about the usage of the textures and
associated images to know what is going on, but my best guess is that
your first texture is being used and has the UnRefImageDataAfterApply
set to true (this is the default) so once it's used the image will be
discarded,
Hi,
Ok I will try to make it clearer.
I have a generated CubeMap, and I want to display each face on a quad with a
HUD Camera. I first tried to generate on face in a Texture2D and it worked
welll since I don't have to copy the image in the original texture in a new
texture (on the opposite if
Hi Gaëtan,
If you are assigning a new Image to an already existing and possibly
bound texture, try to set the image dirty.
Secondly, you might want to try to set the texture explicitly to:
stateset->setTextureAttributeAndModes( 0,map, osg::StateAttribute::ON |
osg::StateAttribute::OVERRIDE);
ah, I missread it. from your original post the map texture was not
initialized and was used later in the statest. I had to write something
like:
osg::ref_ptr map = new osg::Texture2D;
stateset->setTextureAttributeAndModes( 0,map);
if you post your code in whole then the chance to get help if high
Hi,
Thank you for the reply.
I am not quite sure to understand your answer.
Do you mean I should do this :
//does not display the texture
osg::StateSet* stateset = HUD_camera->getOrCreateStateSet();
osg::ref_ptr lm = new osg::Texture2D;
stateset->setTextureAttributeAndModes( 0,map);
lm->setImag
Hi,
initialize the texture and then reference it, in that order
osg::ref_ptr lm = new osg::Texture2D;
stateset->setTextureAttributeAndModes( 0,map);
Nick
On Sun, Jun 9, 2013 at 3:02 PM, Gaëtan André wrote:
> Hi,
>
> I am trying to understand how texture ande Image are working
>
> //some initi
Hi,
I am trying to understand how texture ande Image are working
//some initialized texture with contents
osg::ref_ptr map
//displays correctly the texture
osg::StateSet* stateset = HUD_camera->getOrCreateStateSet();
stateset->setTextureAttributeAndModes( 0,map);
//does not display the text
13 matches
Mail list logo