[vtkusers] vtkRenderLargeImage and vtkTextActor

John Biddiscombe biddisco at cscs.ch
Mon Jun 20 08:02:26 EDT 2005


I fixed this a few weeks/months back and if you use the cvs version it 
may be better. Let me know if it works for you.

JB


Christian Pfaffel-Janser wrote:

>Hello all!
>
>When I use vtkRenderLargeImage and vtkTextActor, I see that the text
>is replicated in each tile. The code looks like this:
>
>
>####################### snip ######################
>from vtkpython import *
>
>sphere = vtk.vtkSphereSource()
>sphereMapper = vtk.vtkPolyDataMapper()
>sphereMapper.SetInput(sphere.GetOutput())
>sphereActor = vtk.vtkActor()
>sphereActor.SetMapper(sphereMapper)
>
>textActor = vtk.vtkTextActor()
>textActor.SetInput("This is a sphere")
>
>ren = vtk.vtkRenderer()
>ren.AddActor2D(textActor)
>ren.AddActor(sphereActor)
>
>renWin = vtk.vtkRenderWindow()
>renWin.AddRenderer(ren)
>
>iren = vtk.vtkRenderWindowInteractor()
>iren.SetRenderWindow(renWin)
>iren.Initialize()
>iren.Start()
>
>
>renderLarge = vtkRenderLargeImage()
>renderLarge.SetInput(ren)
>renderLarge.SetMagnification(4)
>
>pswriter = vtkPNMWriter()
>pswriter.SetFileName("t.pnm")
>pswriter.SetInput(renderLarge.GetOutput())
>pswriter.Write()
>####################### snip ######################
>
>I am using version 4.4.2 and I would appreciate any hint or help on
>what I can do to obtain only a single line of text.
>
>Regards and thanks,
>Christian
>
>  
>


-- 
John Biddiscombe,                            email:biddisco @ cscs.ch
http://www.cscs.ch/about/BJohn.php
CSCS, Swiss National Supercomputing Centre  | Tel:  +41 (91) 610.82.07
Via Cantonale, 6928 Manno, Switzerland      | Fax:  +41 (91) 610.82.82





More information about the vtkusers mailing list