[vtkusers] vtkWindowToImageFilter - Possibly a bug??
rakesh patil
prakeshofficial at gmail.com
Mon May 21 07:48:48 EDT 2012
Hi,
I don't know whether this is a bug or not. What I did was, I displayed
legend scale actor along with normal Sphere. I used vtkWindowToImageFilter
to get the screenshot of the contents of the window. I combined the
following two examples.
http://www.vtk.org/Wiki/VTK/Examples/Cxx/Visualization/LegendScaleActor
http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/Screenshot
What I observed is, when I don't use SetMagnification() function, the
output comes perfectly fine. On the other hand, when I use
SetMagnification() function, some part of legend scale goes out of the
window. This behavior I first observed with glyphs. When the screenshot was
taken with SetMagnification function, the glyphs were not visible at all,
and without SetMagnification function, they were visible. This behavior I
understood is due to an observer which I had added, to scale the size of
the glyph(to keep glyph size same, instead of changing) as and how it is
zoomed in and out. To solve it, I removed the observer just before the code
where screenshot is taken and, once screenshot was taken, I added back the
observer. That solved my problem of displaying glyphs. But the legend scale
was going out of the window.
So is this possibly a bug or its a natural behaviour? Is there any
alternative way to solve this problem? I have attached a sample screenshot
along with this.
Thanks in advance
Regards
Rakesh Patil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120521/86eb6c7c/attachment.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: scrvtk.rar
Type: application/rar
Size: 115763 bytes
Desc: not available
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20120521/86eb6c7c/attachment.rar>
More information about the vtkusers
mailing list