<div dir="ltr"><div><div><div>Hi David, <br><br></div>Looks like you were right on the money. After some consideration here we ended up agreeing with you guys so we'll just update the images on our end. For reference, I did pull master and try the new 'tight' bounding box setting and it did indeed generate my base image. Do we have a ballpark for 7.1's release date?<br><br></div>Thank you for your help,<br><br></div>Tiago<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Sep 23, 2016 at 12:08 PM, David Lonie <span dir="ltr"><<a href="mailto:david.lonie@kitware.com" target="_blank">david.lonie@kitware.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">"That's not a bug, it's a feature" ;)<div><br></div><div>VTK previously used a "tight" bounding box for aligning/sizing text, which gives better results in cases like this. However, this caused issues with animations in ParaView, since if a string changed height by gaining/losing ascenders (e.g. "T" vs "n") or descenders (e.g. "j" vs "i"), the text would jump around. So the change was made to have all strings always account for ascenders/descenders to keep the baseline consistent in such cases.</div><div><br></div><div>Dan Lipsa very recently added the option to vtkTextProperty to use a tight bounding box:</div><div><br></div><div><a href="https://gitlab.kitware.com/vtk/vtk/merge_requests/1925" target="_blank">https://gitlab.kitware.com/<wbr>vtk/vtk/merge_requests/1925</a><br></div><div><br></div><div>This is available in master, and should be in the upcoming 7.1 release. It should allow you to render strings like in the "before" image.</div><div><br></div><div>HTH,</div><div>Dave</div></div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="h5">On Fri, Sep 23, 2016 at 7:27 AM, Tiago Nobrega <span dir="ltr"><<a href="mailto:tigarmo@gmail.com" target="_blank">tigarmo@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 class="h5"><div dir="ltr"><div><div>Hello,<br><br></div>I apologize for not reading the guidelines properly and submitting an issue on Gitlab before trying the mailing list. Here's my issue:<br><br>We are in the process of updating VTK from 6.3 to 7.0 and some of our tests are failing because text actors are being rendered differently. This usually happens when we update the library (minor differences are to be expected) but in this particular case it looks like a regression.<br><br>The following code (python):<br><br></div>```python<br>import vtk<br><br>ren1 = vtk.vtkRenderer()<br>renWin = vtk.vtkRenderWindow()<br>renWin.AddRenderer(ren1)<br>iren = vtk.vtkRenderWindowInteractor(<wbr>)<br>iren.SetRenderWindow(renWin)<br><br>prop_1 = vtk.vtkCaptionActor2D()<br>prop_1.SetCaption('Hello')<br>prop_1.SetAttachmentPoint((-0.<wbr>1, 0.0, 0.0))<br><br>prop_1.GetCaptionTextProperty(<wbr>).Modified()<br><br>ren1.AddActor(prop_1)<br>ren1.SetBackground(0, 0, 0)<br>ren1.GetActiveCamera().SetFoca<wbr>lPoint(0,0,0)<br>ren1.GetActiveCamera().SetPosi<wbr>tion(1,0,0)<br>ren1.GetActiveCamera().SetView<wbr>Up(0,0,1)<br>ren1.ResetCamera()<br>renWin.SetSize(500, 500)<br><br>iren.Start()<br>```<br><br>... generates two different renderings depending on the version, as shown on the following image: <br><br><a href="http://imgur.com/w8VXM8z" target="_blank">http://imgur.com/w8VXM8z</a><br><br><p>The left side is VTK 6.3, and the right one is 7.0. Both ran on a
Windows 10 machine, but the issue was replicated on our Linux boxes too.
In all cases we're still using the old OpenGL backend and not the new
OpenGL2 one. The behavior in version 6.3 seems more "correct" in the
sense that the text is more fully filling up the rectangle, with the
default scaling mode being to scale to the prop. I've investigated the
commit history for the classes that seem relevant - vtkCaptionActor2D,
vtkTextActor, vtkTextProperty, etc - but nothing stood out as possible
"culprits".</p>
<p>Let me know if you need further info or clarifications. Thanks.</p><span><font color="#888888"><p></p><p>Tiago Nobrega<br></p><br></font></span></div>
<br></div></div>______________________________<wbr>_________________<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/opensou<wbr>rce/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_FA<wbr>Q</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=<wbr>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/mail<wbr>man/listinfo/vtkusers</a><br>
<br></blockquote></div><br></div>
</blockquote></div><br></div>