<div dir="ltr"><div><div><div><div><div>Hi Michael,<br><br></div>Your code is creating it's own osg::Camera then assigning this to the viewer replacing the it's Camera.  The one you are creating you aren't setting up any OpenGL default state so it's just left with OpenGL defaults, these aren't ideal for most 3D applications, while the one originally assigned to the Viewer has it's StateSet set up with defaults for OpenGL that are more appropriate for 3D rendering.<br><br></div>To rectify this you simply call:<br><br></div>  camera->getOrCreateStateSet()->setGlobalDefaults();<br><br></div>Or reuse the view(er)'s Camera assigning the graphics context you are creating to it, rather than replacing it wholesale like you have done.<br><br></div>Robert.<br></div><div class="gmail_extra"><br><div class="gmail_quote">On 16 August 2015 at 12:49, Michael Shiringin <span dir="ltr"><<a href="mailto:koryuun@gmail.com" target="_blank">koryuun@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi,<br>
<br>
Why if I uncomment the line "viewer.setCamera(createCamera (createGraphicsContext()));" the text becomes ugly? How can I set the Camera and DeviceContext without losing the the quality of the text?<br>
<br>
OpenSceneGraph-3.4.0-rc12.<br>
<br>
Thank you!<br>
<br>
Cheers,<br>
Michael<br>
<br>
------------------<br>
Read this topic online here:<br>
<a href="http://forum.openscenegraph.org/viewtopic.php?p=64789#64789" rel="noreferrer" target="_blank">http://forum.openscenegraph.org/viewtopic.php?p=64789#64789</a><br>
<br>
<br>
<br>
<br>
Attachments:<br>
<a href="http://forum.openscenegraph.org//files/osgtest_150.cpp" rel="noreferrer" target="_blank">http://forum.openscenegraph.org//files/osgtest_150.cpp</a><br>
<a href="http://forum.openscenegraph.org//files/ugly_916.png" rel="noreferrer" target="_blank">http://forum.openscenegraph.org//files/ugly_916.png</a><br>
<a href="http://forum.openscenegraph.org//files/beautiful_155.png" rel="noreferrer" target="_blank">http://forum.openscenegraph.org//files/beautiful_155.png</a><br>
<br>
<br>
_______________________________________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org">osg-users@lists.openscenegraph.org</a><br>
<a href="http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org" rel="noreferrer" target="_blank">http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org</a><br>
</blockquote></div><br></div>