Hi Jonas, dunno if this helps or you already checked this out, but make sure that your projection matrix is updated upon window resize event.
Just my 2 cents :) Cheers, Michele On Wed, Mar 19, 2008 at 2:27 PM, Jonas Dehlin <[EMAIL PROTECTED]> wrote: > Hi again, > > Since noone has answered my last post I'm trying once more. Does anyone know > if this patch has been implemented in a release newer than 2.0? I'm having > problems that I think i similar to the ones described by Martin Prosicky in > his posts. My problem is as follows. > > I want to have a constant size (height) in pixels for my text independent of > how my window is resized. > > I use osgText with characterSizeMode set to SCREEN_COORDS and axisAlignment > set to SCREEN and when I'm resizing my window I get in my opinion unwanted > results. This is also seen in the osgtext example. I've attached some > screenshots illustrating the problem. Look at the text "CharacterSizeMode > SCREEN_COORDS(size 32.0)" in the different screenshots and how it differ. > > When making the window smaller in the height direction, the text seems to > shrink closer together, but this behavior is not seen when resizing the > window in the width direction. Am I doing something wrong or is this the way > it is supposed to be? > > How are character size and font resolution related to each other? > > What does it mean to set the character size to e.g. 32 when using > SCREEN_COORDS for character size mode and SCREEN for axis alignment? Is this > related to the size of the text in pixels? > > Regards > Jonas > > On Thu, Feb 28, 2008 at 4:28 PM, Jonas Dehlin <[EMAIL PROTECTED]> > wrote: > > Hi, > > > > When using osgText::Text with SCREEN_COORDS I have experienced similar > problems as disussed in the referenced thread and I'm wondering if this > suggested patch has been implemented? If not, why? > > > > I'm currently using OSG 2.0. > > > > Regards > > Jonas > > > > > > > > > > > > On Mon, Dec 10, 2007 at 1:18 PM, Thibault Genessay <[EMAIL PROTECTED]> > wrote: > > > > > Hi Robert, > > > > > > This august, Martin Prosicky posted a patch to work around a > > > longstanding bug in osgText::Text using the SCREEN_COORDS mode. I came > > > across this bug and noticed your discussion > > > > (http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/2007-August/001607.html). > > > I applied Martin's patch and my aspect ratio bug went away. I am using > > > the SVN version of the OSG. > > > > > > Is it that you did not want to apply the patch, not to risk breaking > > > existing applications ? Or that you did not want to merge the file > > > with it's not so pretty #ifdef > > > COMPILE_MartinProsicky_text_aspect_ratio_code macro ? > > > > > > However, if you don't have the time to dig into that issue, I propose > > > the following: I can patch osgText::Text so that it has another member > > > in the CharacterSizeMode and so that users can choose whether they > > > want the old or new way to compute SCREEN_COORDS. We could rename the > > > existing code so that SCREEN_COORDS becomes SCREEN_COORDS_LEGACY (or > > > something like that) and that Martin's code becomes the new > > > SCREEN_COORDS. > > > > > > This way, people seeing problems with an SVN update could easily roll > > > back to the previous size computation algorithm, while if everything > > > goes seamlessly (which was the case for me), the change could go > > > unnoticed and the SCREEN_COORDS_LEGACY thing could be removed. > > > > > > Of course I am open to any other workaround you might suggest. Any > thoughts ? > > > > > > Regards > > > > > > Thibault > > > _______________________________________________ > > > osg-users mailing list > > > [email protected] > > > > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > > > > > > > > > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > > _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

