<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:st1="urn:schemas-microsoft-com:office:smarttags" xmlns="http://www.w3.org/TR/REC-html40">

<head>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii">
<meta name=Generator content="Microsoft Word 11 (filtered medium)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]--><o:SmartTagType
 namespaceuri="urn:schemas-microsoft-com:office:smarttags" name="PostalCode"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="State"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="Street"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="PlaceName"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="PlaceType"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="address"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="place"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="City"/>
<o:SmartTagType namespaceuri="urn:schemas-microsoft-com:office:smarttags"
 name="PersonName"/>
<!--[if !mso]>
<style>
st1\:*{behavior:url(#default#ieooui) }
</style>
<![endif]-->
<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman";}
a:link, span.MsoHyperlink
        {color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {color:blue;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-reply;
        font-family:Arial;
        color:navy;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</style>
<!--[if gte mso 9]><xml>
 <o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
 <o:shapelayout v:ext="edit">
  <o:idmap v:ext="edit" data="1" />
 </o:shapelayout></xml><![endif]-->
</head>

<body lang=EN-US link=blue vlink=blue>

<div class=Section1>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>Michael,<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'>I am not sure about how to
programmatically align the renderwindows, but as for your question about displaying
multiple render windows, I think the problem is that once you call
windowinteractor.Start(), the render window will block the code from continuing
until the interaction is terminated.&nbsp; You can work around this by calling
Render() on each of the windows before you call Start().&nbsp; Based on what it
sounds like you are doing, it looks like you might be interested in looking at
using one render window with multiple renderers in separate viewports.&nbsp; This will
allow you to display different scenes in each renderer, but you will only have
to manage one render window.&nbsp; I have attached examples of both scenarios below:<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=blue
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:blue'>import</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'> vtk</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=blue
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:blue'>def</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'> <b><span
style='font-weight:bold'>main</span></b>():</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><i><font size=2 color="#00aa00"
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:#00AA00;font-style:italic'>'''multiple render windows'''</span></font></i><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; iren_list = []</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><font size=2 color=blue face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:blue'>for</span></font><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'> i </span></font><font size=2 color=blue
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:blue'>in</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'> range(</span></font><font
size=2 color=maroon face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>4</span></font><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>):</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; rw = vtk.vtkRenderWindow()</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ren = vtk.vtkRenderer()</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; rw.AddRenderer(ren)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; iren = vtk.vtkRenderWindowInteractor()</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; iren.SetRenderWindow(rw)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; rw.Render()</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; rw.SetWindowName(</span></font><i><font size=2
color="#00aa00" face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:#00AA00;font-style:italic'>'RW: '</span></font></i><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>+str(i))</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; iren_list.append(iren)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></font><font size=2 color=silver face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:silver'>#Create a
sphere</span></font><font size=2 face="Courier New"><span style='font-size:
10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sphereSource = vtk.vtkSphereSource()</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sphereSource.SetCenter(</span></font><font size=2
color=maroon face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>0.0</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>, </span></font><font
size=2 color=maroon face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>0.0</span></font><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>, </span></font><font size=2 color=maroon face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:maroon'>0.0</span></font><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>)</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sphereSource.SetRadius(</span></font><font size=2
color=maroon face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>5</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>)</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></font><font size=2 color=silver face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:silver'>#Create a <u>mapper</u>
and actor</span></font><font size=2 face="Courier New"><span style='font-size:
10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; mapper = vtk.vtkPolyDataMapper()</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; mapper.SetInputConnection(sphereSource.GetOutputPort())</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; actor = vtk.vtkActor()</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; actor.SetMapper(mapper)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ren.AddActor(actor)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ren.ResetCamera()</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; iren_list[-</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>1</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>].Start()</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=blue
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:blue'>def</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'> <b><span
style='font-weight:bold'>main2</span></b>():</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><i><font size=2 color="#00aa00"
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:#00AA00;font-style:italic'>'''One render window, multiple <u>viewports</u>'''</span></font></i><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; iren_list = []</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; rw = vtk.vtkRenderWindow()</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; iren = vtk.vtkRenderWindowInteractor()</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; iren.SetRenderWindow(rw)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><font size=2 color=silver face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:silver'># Define <u>viewport</u>
ranges</span></font><font size=2 face="Courier New"><span style='font-size:
10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; xmins=[</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>0</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>,.</span></font><font
size=2 color=maroon face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>5</span></font><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>,</span></font><font size=2 color=maroon face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:maroon'>0</span></font><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>,.</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>5</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>]</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; xmaxs=[</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>0.5</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>,</span></font><font
size=2 color=maroon face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>1</span></font><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>,</span></font><font size=2 color=maroon face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:maroon'>0.5</span></font><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>,</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>1</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>]</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; ymins=[</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>0</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>,</span></font><font
size=2 color=maroon face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>0</span></font><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>,.</span></font><font size=2 color=maroon face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:maroon'>5</span></font><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>,.</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>5</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>]</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; ymaxs=[</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>0.5</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>,</span></font><font
size=2 color=maroon face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>0.5</span></font><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>,</span></font><font size=2 color=maroon face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:maroon'>1</span></font><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>,</span></font><font size=2 color=maroon
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>1</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>]</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><font size=2 color=blue face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:blue'>for</span></font><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'> i </span></font><font size=2 color=blue
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:blue'>in</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'> range(</span></font><font
size=2 color=maroon face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>4</span></font><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>):</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ren = vtk.vtkRenderer()</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; rw.AddRenderer(ren)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ren.SetViewport(xmins[i],ymins[i],xmaxs[i],ymaxs[i])</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></font><font size=2 color=silver face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:silver'>#Create a
sphere</span></font><font size=2 face="Courier New"><span style='font-size:
10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sphereSource = vtk.vtkSphereSource()</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sphereSource.SetCenter(</span></font><font size=2
color=maroon face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>0.0</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>, </span></font><font
size=2 color=maroon face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:maroon'>0.0</span></font><font size=2
color=black face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>, </span></font><font size=2 color=maroon face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:maroon'>0.0</span></font><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>)</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; sphereSource.SetRadius(</span></font><font size=2
color=maroon face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:maroon'>5</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>)</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span></font><font size=2 color=silver face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:silver'>#Create a <u>mapper</u>
and actor</span></font><font size=2 face="Courier New"><span style='font-size:
10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; mapper = vtk.vtkPolyDataMapper()</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; mapper.SetInputConnection(sphereSource.GetOutputPort())</span></font><font
size=2 face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; actor = vtk.vtkActor()</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; actor.SetMapper(mapper)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ren.AddActor(actor)</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ren.ResetCamera()</span></font><font size=2
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; rw.Render()</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; rw.SetWindowName(</span></font><i><font size=2 color="#00aa00"
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:#00AA00;font-style:italic'>'RW: Multiple ViewPorts'</span></font></i><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>)</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; iren.Start()</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; </span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=blue
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:blue'>if</span></font><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'> __name__ == </span></font><i><font
size=2 color="#00aa00" face="Courier New"><span style='font-size:10.0pt;
font-family:"Courier New";color:#00AA00;font-style:italic'>'__main__'</span></font></i><font
size=2 color=black face="Courier New"><span style='font-size:10.0pt;font-family:
"Courier New";color:black'>:</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal style='text-autospace:none'><font size=2 color=black
face="Courier New"><span style='font-size:10.0pt;font-family:"Courier New";
color:black'>&nbsp;&nbsp;&nbsp; main()</span></font><font size=2 face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New"'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=black face="Courier New"><span
style='font-size:10.0pt;font-family:"Courier New";color:black'>&nbsp;&nbsp;&nbsp; main2()</span></font><font
size=2 color=navy face=Arial><span style='font-size:10.0pt;font-family:Arial;
color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal><font size=2 color=navy face=Arial><span style='font-size:
10.0pt;font-family:Arial;color:navy'><o:p>&nbsp;</o:p></span></font></p>

<div>

<div>

<div>

<div>

<p class=MsoNormal><font size=2 color="#ff8040" face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:#FF8040'>____________________________</span></font><font
color=navy><span style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><st1:PersonName w:st="on"><strong><b><font size=2
 color="#0000a0" face=Arial><span style='font-size:10.0pt;font-family:Arial;
 color:#0000A0'>Bryan P. Conrad</span></font></b></strong></st1:PersonName><strong><b><font
size=2 color="#0000a0" face=Arial><span style='font-size:10.0pt;font-family:
Arial;color:#0000A0'>, Ph.D.</span></font></b></strong><font color=navy><span
style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><strong><b><font size=2 color="#0000a0" face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:#0000A0'>Senior&nbsp;Engineer</span></font></b></strong><font
color=navy><span style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=3 color=navy face="Times New Roman"><span
style='font-size:12.0pt;color:navy'>&nbsp;<o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color="#0000a0" face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:#0000A0'>Department of
Orthopaedics and Rehabilitation</span></font><font color=navy><span
style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><st1:place w:st="on"><st1:PlaceType w:st="on"><font size=2
  color="#0000a0" face=Arial><span style='font-size:10.0pt;font-family:Arial;
  color:#0000A0'>University</span></font></st1:PlaceType><font size=2
 color="#0000a0" face=Arial><span style='font-size:10.0pt;font-family:Arial;
 color:#0000A0'> of <st1:PlaceName w:st="on">Florida</st1:PlaceName></span></font></st1:place><font
color=navy><span style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><st1:address w:st="on"><st1:Street w:st="on"><font size=2
  color="#0000a0" face=Arial><span style='font-size:10.0pt;font-family:Arial;
  color:#0000A0'>PO Box</span></font></st1:Street><font size=2 color="#0000a0"
 face=Arial><span style='font-size:10.0pt;font-family:Arial;color:#0000A0'>
 112727</span></font></st1:address><font color=navy><span style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><st1:place w:st="on"><st1:City w:st="on"><font size=2
  color="#0000a0" face=Arial><span style='font-size:10.0pt;font-family:Arial;
  color:#0000A0'>Gainesville</span></font></st1:City><font size=2
 color="#0000a0" face=Arial><span style='font-size:10.0pt;font-family:Arial;
 color:#0000A0'>, <st1:State w:st="on">FL</st1:State> <st1:PostalCode w:st="on">32611</st1:PostalCode></span></font></st1:place><font
color=navy><span style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color="#0000a0" face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:#0000A0'>Phone: 352.273.7412</span></font><font
color=navy><span style='color:navy'><o:p></o:p></span></font></p>

<p class=MsoNormal><font size=2 color="#0000a0" face=Arial><span
style='font-size:10.0pt;font-family:Arial;color:#0000A0'>Fax: 352.273.7407<o:p></o:p></span></font></p>

</div>

</div>

</div>

</div>

<div>

<div class=MsoNormal align=center style='text-align:center'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>

<hr size=2 width="100%" align=center tabindex=-1>

</span></font></div>

<p class=MsoNormal><b><font size=2 face=Tahoma><span style='font-size:10.0pt;
font-family:Tahoma;font-weight:bold'>From:</span></font></b><font size=2
face=Tahoma><span style='font-size:10.0pt;font-family:Tahoma'>
vtkusers-bounces@vtk.org [mailto:vtkusers-bounces@vtk.org] <b><span
style='font-weight:bold'>On Behalf Of </span></b>michiel mentink<br>
<b><span style='font-weight:bold'>Sent:</span></b> Thursday, January 07, 2010
6:45 AM<br>
<b><span style='font-weight:bold'>To:</span></b> David Doria<br>
<b><span style='font-weight:bold'>Cc:</span></b> vtkusers@vtk.org<br>
<b><span style='font-weight:bold'>Subject:</span></b> Re: [vtkusers] giving
renderwindow a name</span></font><o:p></o:p></p>

</div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

<p class=MsoNormal style='margin-bottom:12.0pt'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>thanks guys, I've the
title working now.<br>
<br>
For a touch of perfection; is there a way to automatically set the window
coordinates so that the windows are aligned wherever you want them?<br>
(i.e. next to each other?)<br>
<br>
<br>
And one last question: after the first render window has been created, the
program waits for me to press 'q' to continue the program. Is<br>
there a way for the program to continue without pressing 'q'?<br>
<br>
I tried: renwindow-&gt;Finalize(); // doesn't do anything<br>
<br>
windowinteractor-&gt;TerminateApp(); // this closes the application altogether
when 'q' is pressed<br>
<br>
windowinteractor-&gt;UnRegister(); // error: no matching function call<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
// note: candidates are: virtual void
vtkRenderWindowInteractor::UnRegister(vtkObjectBase*)<br>
<br>
windowinteractor-&gt;CreateOneShotTimer(1); // doesn't release focus<br>
<br>
I'd just like all windows to pop up as soon as possible and be able to
manipulate them with my mouse whenever I'd like to.<br>
At this point I can manipulate all renderwindows fine, I'd just like the
windows to appear without having to press 'q'.<br>
<br>
cheers, Michael<o:p></o:p></span></font></p>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>On Tue, Jan 5, 2010 at 10:42 PM, David Doria &lt;<a
href="mailto:daviddoria%2Bvtk@gmail.com">daviddoria+vtk@gmail.com</a>&gt;
wrote:<o:p></o:p></span></font></p>

<div>

<div>

<p class=MsoNormal style='margin-bottom:12.0pt'><font size=3
face="Times New Roman"><span style='font-size:12.0pt'>On Tue, Jan 5, 2010 at
5:22 PM, <st1:PersonName w:st="on">Bryan P. Conrad</st1:PersonName> &lt;<a
href="mailto:conrabp@ortho.ufl.edu">conrabp@ortho.ufl.edu</a>&gt; wrote:<br>
&gt; I have only done this in python, not C++, but I think the trick is to use
the method &quot;SetWindowName&quot; and it has to be called *after* the
renderWindow is rendered the first time. &nbsp;See the python code below
(copied from David's C++ example), for a version that works on my machine.<br>
&gt;<br>
&gt; import vtk<br>
&gt;<br>
&gt; def main():<br>
&gt; &nbsp; &nbsp;#Create a sphere<br>
&gt; &nbsp; &nbsp;sphereSource = vtk.vtkSphereSource()<br>
&gt; &nbsp; &nbsp;sphereSource.SetCenter(0.0, 0.0, 0.0)<br>
&gt; &nbsp; &nbsp;sphereSource.SetRadius(5)<br>
&gt;<br>
&gt; &nbsp; &nbsp;#Create a mapper and actor<br>
&gt; &nbsp; &nbsp;mapper = vtk.vtkPolyDataMapper()<br>
&gt; &nbsp; &nbsp;mapper.SetInputConnection(sphereSource.GetOutputPort())<br>
&gt; &nbsp; &nbsp;actor = vtk.vtkActor()<br>
&gt; &nbsp; &nbsp;actor.SetMapper(mapper)<br>
&gt;<br>
&gt; &nbsp; &nbsp;# Setup a renderer, render window, and interactor<br>
&gt; &nbsp; &nbsp;renderer = vtk.vtkRenderer()<br>
&gt; &nbsp; &nbsp;renderWindow = vtk.vtkRenderWindow()<br>
&gt; &nbsp; &nbsp;#renderWindow.SetWindowName(&quot;Test&quot;)<br>
&gt;<br>
&gt; &nbsp; &nbsp;renderWindow.AddRenderer(renderer);<br>
&gt; &nbsp; &nbsp;renderWindowInteractor = vtk.vtkRenderWindowInteractor()<br>
&gt; &nbsp; &nbsp;renderWindowInteractor.SetRenderWindow(renderWindow)<br>
&gt;<br>
&gt; &nbsp; &nbsp;#Add the actor to the scene<br>
&gt; &nbsp; &nbsp;renderer.AddActor(actor)<br>
&gt; &nbsp; &nbsp;renderer.SetBackground(1,1,1) # Background color white<br>
&gt;<br>
&gt; &nbsp; &nbsp;#Render and interact<br>
&gt; &nbsp; &nbsp;renderWindow.Render()<br>
&gt;<br>
&gt; &nbsp; &nbsp;#*** SetWindowName after renderWindow.Render() is called***<br>
&gt; &nbsp; &nbsp;renderWindow.SetWindowName(&quot;Test&quot;)<br>
&gt;<br>
&gt; &nbsp; &nbsp;renderWindowInteractor.Start()<br>
&gt;<br>
&gt;<br>
&gt; if __name__ == '__main__':<br>
&gt; &nbsp; &nbsp;main()<br>
&gt;<br>
&gt; ____________________________<br>
&gt; <st1:PersonName w:st="on">Bryan P. Conrad</st1:PersonName>, Ph.D.<br>
&gt; Senior Engineer<br>
&gt;<br>
&gt; Department of Orthopaedics and Rehabilitation<br>
&gt; <st1:place w:st="on"><st1:PlaceType w:st="on">University</st1:PlaceType>
 of <st1:PlaceName w:st="on">Florida</st1:PlaceName></st1:place><br>
&gt; PO Box 112727<br>
&gt; <st1:place w:st="on"><st1:City w:st="on">Gainesville</st1:City>, <st1:State
 w:st="on">FL</st1:State> <st1:PostalCode w:st="on">32611</st1:PostalCode></st1:place><br>
&gt; Phone: 352.273.7412<br>
&gt; Fax: 352.273.7407<br>
&gt;<br>
&gt; -----Original Message-----<br>
&gt; From: <a href="mailto:vtkusers-bounces@vtk.org">vtkusers-bounces@vtk.org</a>
[mailto:<a href="mailto:vtkusers-bounces@vtk.org">vtkusers-bounces@vtk.org</a>]
On Behalf Of David Doria<br>
&gt; Sent: Tuesday, January 05, 2010 2:07 PM<br>
&gt; Cc: <a href="mailto:vtkusers@vtk.org">vtkusers@vtk.org</a><br>
&gt; Subject: Re: [vtkusers] giving renderwindow a name<br>
&gt;<br>
&gt; On Tue, Jan 5, 2010 at 11:25 AM, michiel mentink<br>
&gt; &lt;<a href="mailto:michael.mentink@st-hughs.ox.ac.uk">michael.mentink@st-hughs.ox.ac.uk</a>&gt;
wrote:<br>
&gt;&gt; I'm trying to give a renderwindow a title.<br>
&gt;&gt;<br>
&gt;&gt; I'm using the following code to create a window. So far so good.<br>
&gt;&gt;<br>
&gt;&gt; &nbsp; // create a renderer<br>
&gt;&gt; &nbsp; vtkSmartPointer&lt;vtkRenderer&gt; renderer =<br>
&gt;&gt; &nbsp;&nbsp;&nbsp; vtkSmartPointer&lt;vtkRenderer&gt;::New();<br>
&gt;&gt; &nbsp; renderer-&gt;AddActor(actor);<br>
&gt;&gt;<br>
&gt;&gt; &nbsp; // create a render window<br>
&gt;&gt; &nbsp; vtkSmartPointer&lt;vtkRenderWindow&gt; renwin =<br>
&gt;&gt; &nbsp;&nbsp;&nbsp; vtkSmartPointer&lt;vtkRenderWindow&gt;::New();<br>
&gt;&gt; &nbsp; renwin-&gt;AddRenderer(renderer);<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; &nbsp; // create an interactor<br>
&gt;&gt; &nbsp; vtkSmartPointer&lt;vtkRenderWindowInteractor&gt; iren =<br>
&gt;&gt; &nbsp;&nbsp;&nbsp;
vtkSmartPointer&lt;vtkRenderWindowInteractor&gt;::New();<br>
&gt;&gt; &nbsp; iren-&gt;SetRenderWindow(renwin);<br>
&gt;&gt; &nbsp;&nbsp;&nbsp; renwin-&gt;SetSize(640, 480);<br>
&gt;&gt;<br>
&gt;&gt; &nbsp; iren-&gt;Initialize();<br>
&gt;&gt; &nbsp; iren-&gt;Start();<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; ///////////end code////////<br>
&gt;&gt;<br>
&gt;&gt; Before iren-&gt;initialize, I tried the following:<br>
&gt;&gt;<br>
&gt;&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; iren-&gt;SetWindowInfo(
&quot;window1&quot; );<br>
&gt;&gt; &nbsp;&nbsp;&nbsp;&nbsp; renwin-&gt;SetWindowInfo(
&quot;window1&quot;);<br>
&gt;&gt;<br>
&gt;&gt; and also -&gt;SetWindowId(&quot;window1&quot;);<br>
&gt;&gt; and -&gt;SetWindowName(&quot;window1&quot;);<br>
&gt;&gt;<br>
&gt;&gt; but it keeps giving me error messages upon compiling:<br>
&gt;&gt;<br>
&gt;&gt; 'class vtkRenderWindowInteractor' has no member named 'SetWindowInfo'<br>
&gt;&gt; or<br>
&gt;&gt; error: 'renWin' was not declared in this scope<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;&gt; It's probably a simple mistake, but I'm still beginning to understand
VTK.<br>
&gt;&gt; Can anybody point me in the right direction?<br>
&gt;&gt;<br>
&gt;&gt; Kind regards, Michael<br>
&gt;&gt;<br>
&gt;&gt;<br>
&gt;<br>
&gt; I setup an example if anyone cares to play with it to get it to work:<br>
&gt; <a href="http://www.cmake.org/Wiki/VTK/Examples/WindowTitle"
target="_blank">http://www.cmake.org/Wiki/VTK/Examples/WindowTitle</a><br>
&gt;<br>
&gt; Thanks,<br>
&gt;<br>
&gt; David<o:p></o:p></span></font></p>

</div>

</div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>Thanks <st1:City w:st="on"><st1:place w:st="on">Bryan</st1:place></st1:City>,
that did the trick.<br>
<br>
The example can be found here (c++):<o:p></o:p></span></font></p>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><a href="http://www.cmake.org/Wiki/VTK/Examples/WindowTitle"
target="_blank">http://www.cmake.org/Wiki/VTK/Examples/WindowTitle</a><o:p></o:p></span></font></p>

</div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'>and here(python): <a
href="http://www.cmake.org/Wiki/VTK/Examples/Python/WindowTitle" target="_blank">http://www.cmake.org/Wiki/VTK/Examples/Python/WindowTitle</a><o:p></o:p></span></font></p>

<div>

<div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><br>
Thanks,<br>
<br>
David<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a
href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/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" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><o:p></o:p></span></font></p>

</div>

</div>

</div>

<p class=MsoNormal><font size=3 face="Times New Roman"><span style='font-size:
12.0pt'><o:p>&nbsp;</o:p></span></font></p>

</div>

</body>

</html>