Re: [osg-users] Unexpected osgText::TextBase::computeBound() behaviour

2012-04-11 Thread Filip Arlet
Hi,
it's a bug, 
computation of bb in osgText::TextBase (without auto tranform cache) doesnt 
count with text alignment

http://forum.openscenegraph.org/viewtopic.php?p=45355

Cheers,
Filip

--
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=46966#46966





___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


[osg-users] Unexpected osgText::TextBase::computeBound() behaviour

2012-04-09 Thread Preet
Hi all

Calling computeBound() on an osg::Text object seems to return height
values as if the text were aligned using the baseline of the first
line of text only. So if I had a text object with a total height of
50, using an alignment of osgText::TextBase::CENTER_CENTER positioned
at (0,0,0), I'd expect yMin and yMax from the bounding box to be at
-25 and 25. Instead it'll be according to what I specified previously.
This happens with or without multiple lines in the text.

I've linked a minimal example and a screenshot illustrating the issue.
The screenshot shows the bounding box with respect to the text. Ignore
the glitchy character glyphs -- that's an issue with the drivers on my
system.

screenshot: http://imgur.com/YJasY
code: http://pastie.org/3754296

Regards,

Preet
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org