Hi Paul,
It seems like the objects would only be invisible if blending is on. If
blending is off, then the alpha would essentially be ignored and
everything would be visible. I know osgviewer doesn't enable blending,
and I suspect osganimationviewer doesn't either. That means blending
must be enabled in your model. If that's the case, then it seems like
it's being rendered correctly -- invisible.
You're right, blending is on, and that seems to come from the fact that
the fbx plugin thinks the object should be transparent when it reads it,
and adds an osg::BlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA) to the
model's stateset.
So if the fbx plugin didn't think the model was transparent, it would be
ok. Which brings us to:
However, I do agree there might be some confusion in how the fbx plugin
is setting the alpha value.
I have an fbx file that I've been doing some work with lately. It
renders visible, and Material diffuseColor always has alpha 1.0. So I
suspect there is some issue with how your model was created.
I would accept that, except for two things.
First, as I said, I've tested this both with a file I created and one I
downloaded. I'm willing to admit I can do something wrong, but I doubt a
model that's made by others (and used in other software) would have the
same problem.
Second, even for the model I created myself, it's fully visible in
XSI... Even if I export the fbx file and then re-import it, the model is
visible. So it should be visible when read by OSG's fbx plugin, I would
think... So I would pin the problem on the way the fbx plugin interprets
the file, and not the file itself.
And even for the model I downloaded, it's an fbx file, and it's visible
when I open it in XSI, but not in OSG. Check the link I gave in my first
post if you're curious...
J-S
--
______________________________________________________
Jean-Sebastien Guay [email protected]
http://www.cm-labs.com/
http://whitestar02.webhop.org/
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org