<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Nov 17, 2015 at 3:36 AM, Simon ESNEAULT <span dir="ltr"><<a href="mailto:simon.esneault@gmail.com" target="_blank">simon.esneault@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Dear Aashish,<br><br>Yes the root cause is probably located in vtkTexturedActor2D, or in vtkOpenGLTexture::Load( vtkRenderer* ) which looks like the responsible class for loading the texture.<br>Shall I fill a bug ?<br></div></blockquote><div><br></div><div>Yes, please. </div><div><br></div><div>- Aashish</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thanks<span class="HOEnZb"><font color="#888888"><br>Simon</font></span></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">2015-11-16 17:49 GMT+01:00 Aashish Chaudhary <span dir="ltr"><<a href="mailto:aashish.chaudhary@kitware.com" target="_blank">aashish.chaudhary@kitware.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I see so its not just related to volume rendering and it seems to be a vtkTextActor2D problem? In that can probably Ken / David Lonie wants to take a look at it. Nonetheless, we will follow up on this bug. <span><font color="#888888"><div><br></div><div>- Aashish</div></font></span></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Nov 16, 2015 at 11:12 AM, Simon ESNEAULT <span dir="ltr"><<a href="mailto:simon.esneault@gmail.com" target="_blank">simon.esneault@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hello Aashish,<br><br>Thanks !<br>After doing some test, I realized the patch I've just sent is not the correct fix at all, because the text is not rendered properly when we don't use a vtkFixedPointVolumeRayCastMapper anymore.<br><br>I believe the problem is probably larger than this and probably has nothing to do with the freetype text generation, but more with the vtkTexturedActor2D rendering part used together with a vtkFixedPointVolumeRayCastMapper on the new rendering backend, when the texture has some transparent pixel in it ...<br><br>Attached there is a new example that demonstrate that a vtkTextActor AND a vtkTexturedButtonRepresentation2D are not correctly drawn in that case :<br>- <a href="http://picpaste.com/pics/OGL1-Texture-okay.1447690100.png" target="_blank">OpenGL1 backend</a> : Transparent pixel in Texture are correctly drawn<div>- <a href="http://picpaste.com/pics/OGL2-Texture-not-okay.1447690272.png" target="_blank">OpenGL2 backend</a> : Transparent pixel in Texture are not correctly drawn (clamped to white ?)<br><br></div><div>The example is more simple than the previous one and does not need any additional data.<br><br>Hope that helps !<span><font color="#888888"><br>-Simon</font></span></div></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">2015-11-16 16:11 GMT+01:00 Aashish Chaudhary <span dir="ltr"><<a href="mailto:aashish.chaudhary@kitware.com" target="_blank">aashish.chaudhary@kitware.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Simon, <div><br></div><div>Thanks for the report. I will follow up with other developers on this bug. </div><div><br></div><div>- Aashish</div><div><br><div class="gmail_extra"><br><div class="gmail_quote"><div><div>On Mon, Nov 16, 2015 at 6:08 AM, Simon ESNEAULT <span dir="ltr"><<a href="mailto:simon.esneault@gmail.com" target="_blank">simon.esneault@gmail.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr">Hello,<br><br>Trying to solve this problem, I found out that if one call "vtkFreeTypeTools::GetInstance()->DebugTexturesOn();" before to render a string with a vtkTextActor, the text is properly rendered with a yellow dot at the anchor point, and with a transparent gray background.<div><div>- DebugTexturesOn : <a href="http://picpaste.com/pics/Blurred.1447668943.PNG" target="_blank">http://picpaste.com/pics/Blurred.1447668943.PNG</a><br>- DebugTexturesOff : <a href="http://picpaste.com/pics/Not-Blurred.1447669009.PNG" target="_blank">http://picpaste.com/pics/Not-Blurred.1447669009.PNG</a><br><br>Now digging into the code in vtkFreeTypeTools.cxx, I suspect this is a blending problem. When we activate Texture Debugging, a gray background is first drawn, and after that in the method RenderCharacter( ... ) line 1887; we either blend the rendered text with the background or not.</div><div><br>Attached is a diff file that solves the problem for me. I do not really understand why, so maybe a developer with more VTK's knowledge can integrate this properly :)<br><br>Thanks,<br>Simon</div></div><div><br></div><div><br></div></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">2015-11-13 16:43 GMT+01:00 Simon ESNEAULT <span dir="ltr"><<a href="mailto:simon.esneault@gmail.com" target="_blank">simon.esneault@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi All,<br><br>All vtkTextActor are rendered blurred when using with vtkFixedPointVolumeRayCastMapper in the same renderer in vtk 6.3 with the new rendering backend.<div><br></div><div>Here are some snapshots :<br> - <a href="http://picpaste.com/pics/OGL1-not-blurred.1447428990.png" target="_blank">OpenGL1</a></div><div> - <a href="http://picpaste.com/pics/OGL2-blurred.1447429027.png" target="_blank">OpenGL2</a><br><br>Attached some code that reproduces the problem, to be used with <a href="https://www.dropbox.com/s/ptqwi0ebv75kt35/volume.zip" target="_blank">this</a> volume. Visible on OSX and Windows to our knowledge, probably on more OS.<br><br>The text is rendered properly when used with the old backend or when using a vtkGPUVolumeRayCastMapper instead of the vtkFixedPointVolumeRayCastMapper.<br><br>Shall I feel a bug, is this a known issue ?<br><br>Thanks,<br>Simon<span><font color="#888888"><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><div>------------------------------------------------------------------<br>Simon Esneault<div>Rennes, France<br>------------------------------------------------------------------</div></div></div></div>
</font></span></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><div>------------------------------------------------------------------<br>Simon Esneault<div>Rennes, France<br>------------------------------------------------------------------</div></div></div></div>
</div>
</div></div><br></div></div>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" rel="noreferrer" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtkusers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtkusers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtkusers" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><span><font color="#888888"><br><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><font face="trebuchet ms, sans-serif"><i>| Aashish Chaudhary <br>| Technical Leader         <br>| Kitware Inc.            <br></i></font><div><i><font face="trebuchet ms, sans-serif">| </font><a href="http://www.kitware.com/company/team/chaudhary.html" target="_blank">http://www.kitware.com/company/team/chaudhary.html</a></i></div></div></div>
</font></span></div></div></div>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><div>------------------------------------------------------------------<br>Simon Esneault<div>Rennes, France<br>------------------------------------------------------------------</div></div></div></div>
</div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><font face="trebuchet ms, sans-serif"><i>| Aashish Chaudhary <br>| Technical Leader         <br>| Kitware Inc.            <br></i></font><div><i><font face="trebuchet ms, sans-serif">| </font><a href="http://www.kitware.com/company/team/chaudhary.html" target="_blank">http://www.kitware.com/company/team/chaudhary.html</a></i></div></div></div>
</div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div><div dir="ltr"><div>------------------------------------------------------------------<br>Simon Esneault<div>Rennes, France<br>------------------------------------------------------------------</div></div></div></div>
</div>
</div></div></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><font face="trebuchet ms, sans-serif"><i>| Aashish Chaudhary <br>| Technical Leader         <br>| Kitware Inc.            <br></i></font><div><i><font face="trebuchet ms, sans-serif">| </font><a href="http://www.kitware.com/company/team/chaudhary.html" target="_blank">http://www.kitware.com/company/team/chaudhary.html</a></i></div></div></div>
</div></div>