[Paraview] white legend using vtkGL2PSExporter

Sven Buijssen sven.buijssen at tu-dortmund.de
Sat Jun 19 06:56:05 EDT 2010


Hi Martin,

No, it's not due to colors still being interpolated. I tracked the very
issue down myself a year ago or so. What you are seeing happens since

commit 8fe6d5fa88c7ecbb1420776850f176690b504c71
Author: Ken Moreland <kmorel at sandia.gov>
Date:   Tue Nov 25 09:28:25 2008 -0500

  ENH: add tickmarks to scalar bar widget (and other improvements).  BUG
#6217.

The problem is that along with the bug fix the legend is now realized as
an overlay texture. That's something GL2PS does not handle properly. I
don't recall all the details any more, especially not the class, but I
think I tracked it further down to an early exit of kind if-overlay- or
if-texture-then-return in a render call during the export. Anyway, it
comes down to VTK/Rendering/vtkGL2PSExporter.cxx not being able to
handle the legend properly, hence the legend is stripped off all colors.

I'm using a pre-November 2008 version of
Servers/Filters/vtkPVScalarBarActor.{h,cxx} ever since, ParaView does
compile smoothly with it ever since and the legend is colorful in
vectorgraphics Postscript exports ever since. So, even though you're
using 3.6 and not git master, it should be feasible to simply revert
mentioned commit to solve the issue.

Hope that helps.

Sven


Martin Hautefeuille wrote, On 19.06.2010 00:38:
> Hello,
> 
> I am using paraview 3.6 compiled with VTK_GL2PS_ON.
> 
> When I uncheck "Interpolate Colors" in Object Inspector for the object I
> want to plot, I am able to generate colored high quality eps images
> using the following command in the python shell:
> 
> from libvtkRenderingPython import vtkGL2PSExporter
> exporter = vtkGL2PSExporter()
> exporter.SetFileFormatToPS()
> exporter.SetFilePrefix("testImage")
> view = GetActiveView().GetRenderWindow()
> exporter.SetRenderWindow(view)
> exporter.Write()
> 
> However, the legend is colored white.  My guess is that I am still
> interpolating colors for the legend and I do not know how to specify not
> to do it?
> 
> Thanks a lot for your help!
> 
> -Martin
> 
> 
> 
> 
> _______________________________________________
> Powered by www.kitware.com
> 
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
> 
> Please keep messages on-topic and check the ParaView Wiki at: http://paraview.org/Wiki/ParaView
> 
> Follow this link to subscribe/unsubscribe:
> http://www.paraview.org/mailman/listinfo/paraview



More information about the ParaView mailing list