[osg-users] osgText: problem with SCREEN_COORDS mode

Robert Osfield robert.osfield at gmail.com
Mon May 21 12:06:51 PDT 2018


Thanks Glenn, PR merged with master and the 3.6 branch.

On 21 May 2018 at 18:28, Glenn Waldron <gwaldron at gmail.com> wrote:
> Robert,
> Thanks for looking into this. Your update works well.
>
> I have one additional request: the computing of the origin, left, and up
> vectors (lines 517-519) need to be done in double-precision. In my graticule
> example, the text jitters as you manipulate the scene; changing those lines
> to use osg::Vec3d resolves the issue. I have submitted a PR.
>
> Glenn Waldron / osgEarth
>
>
> On Sun, May 20, 2018 at 8:34 AM Robert Osfield <robert.osfield at gmail.com>
> wrote:
>>
>> Hi Glenn,
>>
>> I have tried various ways to try and make the scale of the text
>> consistent when using CharacterSizeMode is SCREEN_COORDS whle
>> AxisAlignment is not SCREEN but in the end found the only solution
>> that produces consistent results was to apply the same maths as was
>> being use for the auto rotate case, except the auto-rotation itself is
>> ignored when generating the final matrix.
>>
>> What I have checked in is:
>>
>> https://github.com/openscenegraph/OpenSceneGraph/commit/55c0afbe3ad2c6587f8c329a7dcc61284d8d18b9
>>
>> This is also checked into OSG master.
>>
>> To help test the various possibilities out I amend you test example to
>> have --xy, --xz, --screen etc. command line options for setting how to
>> set the axis alignment of the text.  This amended version is attached.
>> With the above fix everything looks to be working fine, at least for
>> the case of this test, the tests that other users have posted and
>> osgtext.  Fingers crossed this means that osgText is now working
>> solidly for 3.6.1.
>>
>> Cheers,
>> Robert.
>> _______________________________________________
>> osg-users mailing list
>> osg-users at lists.openscenegraph.org
>> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>
>
> _______________________________________________
> osg-users mailing list
> osg-users at lists.openscenegraph.org
> http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
>


More information about the osg-users mailing list