<div dir="ltr"><div class="gmail_default" style="font-family:tahoma,sans-serif">Hi Robert,</div><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">I tried adding the setShaderHint() line but things get a bit worse - alpha issue still there and not text at all, see attached screenshot.</div><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">I get display errors also in my other HUD contents where I actually use gl_ builtins so your guess might be right,</div><div class="gmail_default" style="font-family:tahoma,sans-serif">but unfortunately adding the ShaderHint does not fix it.</div><div class="gmail_default" style="font-family:tahoma,sans-serif"><br></div><div class="gmail_default" style="font-family:tahoma,sans-serif">Riccardo</div></div><br><div class="gmail_quote"><div dir="ltr">On Thu, Sep 6, 2018 at 12:42 PM Robert Osfield <<a href="mailto:robert.osfield@gmail.com">robert.osfield@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Ricardo,<br>
<br>
On Thu, 6 Sep 2018 at 10:49, Riccardo Corsi <<a href="mailto:riccardo.corsi@kairos3d.it" target="_blank">riccardo.corsi@kairos3d.it</a>> wrote:<br>
> good guess! I've enabled the aliasing and my shaders works now with osg default build!<br>
> With this configuration there is still a side effect though: something is wrong with alpha settings for HUD cameras.<br>
> See attached screenshot that shows the issue: it's a modified osgsimplegl3 example with stats handler enabled, but I have alpha issues with other HUDs as well.<br>
> I've counter checked in my examples that the 2 aliasing/uniform calls are the culprit: if I comment them out the shaders don't work anymore but the stats are displayed correctly.<br>
<br>
I'm busy with other work right now so can't look at the modified code<br>
right away.<br>
<br>
My best guess right now is that osgText and the StatsHandler are using<br>
GL2 shader paths that assume gl_ builtins are available, but with the<br>
aliasing enabled perhaps this is causing problem. Could you set the<br>
DIsplaySettings ShaderHint to GL3 to see if that helps i.e.<br>
<br>
To the main before the scene graph setup add:<br>
<br>
osg::DisplaySettings::instance()->setShaderHint(osg::DisplaySettings::SHADER_GL3);<br>
<br>
Robert.<br>
_______________________________________________<br>
osg-users mailing list<br>
<a href="mailto:osg-users@lists.openscenegraph.org" target="_blank">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>