View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0013199VTK(No Category)public2012-05-24 05:042016-08-12 09:55
ReporterArnaud BARRE 
Assigned ToMarcus D. Hanwell 
PrioritynormalSeverityminorReproducibilityhave not tried
StatusclosedResolutionmoved 
PlatformOSOS Version
Product Version5.8.0 
Target VersionFixed in Version 
Summary0013199: vtkCharts: No more Qt text rendering with vtk 5.10
DescriptionAs reported in this post http://www.vtk.org/pipermail/vtkusers/2012-May/123540.html, [^] I am no more able to render text into charts using the Qt text renderer.

Since this post, I looked into to code of VTK 5.10 and found some issues:

First, the constructor of the class vtkOpenGLContextDevice2D doesn't use anymore the QApplication::instance condition as it was done in VTK 5.6.1. Then everytime, it is a FreeType text rendering which is used. Trying to force the rendering to Qt using the method vtkOpenGLContextDevice2D::SetStringRendererToQt has no effect.

If in the constructor of the class vtkOpenGLContextDevice2D you set the rendering to Qt, then it works! But there is no text (everything is like blank text). This problem is related to the use of the origin instead of the geometry in the method void vtkOpenGLContextDevice2D::DrawString(float *point, const vtkStdString &string). Using the geometry fix this problem, but then the text is not align correctly. This last problem is related to the use of some pixel padding, the shadow even if not enabled and the creation of a bigger image than expected.

The joined patch resolve all of these problems.
TagsNo tags attached.
ProjectRelease
Typeincorrect functionality
Attached Fileszip file icon vtkChartQtTexRendering.patch.zip [^] (1,244 bytes) 2012-05-24 05:04

 Relationships

  Notes
(0028640)
Marcus D. Hanwell (developer)
2012-05-24 10:22

As I said, we prefer patches uncompressed as they are easier to view inline. I will take a look at this soon, but as a first step want to confirm the regression tests continue to pass for the FreeType rendering.
(0028641)
Arnaud BARRE (reporter)
2012-05-24 12:30

There is two files in the patch (one for each patched files). I know it is not the best way to give to the developer but I use only the release version of VTK and not the GIT version. From what I saw the FreeType rendering is not affected (if you don't use Qt and that you have not executed the event loop of the QApplication). The lines which could affect the FreeType rendering are only these two:

@@ -747,8 +760,8 @@
   vtkTexture* texture = cache.Texture;
   texture->Render(this->Renderer);
 
- float width = static_cast<float>(image->GetOrigin()[0]);
- float height = static_cast<float>(image->GetOrigin()[1]);
+ float width = static_cast<float>(image->GetDimensions()[0]);
+ float height = static_cast<float>(image->GetDimensions()[1]);

And from my tests, it won't change anything for the freetype rendering.

By the way, I personally thank you for the development of the Charts module. It gives me an easy way to plot data!
(0031251)
Dave DeMarle (administrator)
2013-07-22 20:02

moving all "tabled" bugs into "backlog" category since "tabled" is no longer used.
(0033551)
Marcus D. Hanwell (developer)
2014-10-02 17:22

Getting back to this, I will see what I can do (sorry about forgetting this for so long).
(0036261)
Berk Geveci (administrator)
2016-07-06 16:48

Setting to status of bugs that have not been updated in the last year to expired. Please re-open if still important.
(0037277)
Kitware Robot (administrator)
2016-08-12 09:55

Resolving issue as `moved`.

This issue tracker is no longer used. Further discussion of this issue may take place in the current VTK Issues page linked in the banner at the top of this page.

 Issue History
Date Modified Username Field Change
2012-05-24 05:04 Arnaud BARRE New Issue
2012-05-24 05:04 Arnaud BARRE File Added: vtkChartQtTexRendering.patch.zip
2012-05-24 10:20 Marcus D. Hanwell Assigned To => Marcus D. Hanwell
2012-05-24 10:20 Marcus D. Hanwell Status backlog => tabled
2012-05-24 10:22 Marcus D. Hanwell Note Added: 0028640
2012-05-24 12:30 Arnaud BARRE Note Added: 0028641
2013-07-22 20:02 Dave DeMarle Status tabled => backlog
2013-07-22 20:02 Dave DeMarle Note Added: 0031251
2014-10-02 17:22 Marcus D. Hanwell Note Added: 0033551
2014-10-02 17:22 Marcus D. Hanwell Status backlog => active development
2016-07-06 16:48 Berk Geveci Status active development => expired
2016-07-06 16:48 Berk Geveci Note Added: 0036261
2016-08-12 09:55 Kitware Robot Note Added: 0037277
2016-08-12 09:55 Kitware Robot Status expired => closed
2016-08-12 09:55 Kitware Robot Resolution open => moved


Copyright © 2000 - 2018 MantisBT Team