<div>Look at the test TestInteractorTimers.cxx .&nbsp;VTK renderwindowinteractor supports the API to create a repeating timer. You can create a command to observe the timer event and respond. (What you are doing to respond better be quick, unless you want to stop the timer and reschedule).</div>

<div><br><br>&nbsp;</div>
<div><span class="gmail_quote">On 3/12/08, <b class="gmail_sendername">Graham E Voysey</b> &lt;<a href="mailto:gvoysey@infoscitex.com">gvoysey@infoscitex.com</a>&gt; wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Hello List,<br><br>I&#39;m using VTK to display a human avatar and manipulate its position.<br>The intended user is a test subject in a motion study who will use a<br>
joystick to position the avatar so that it reflects how the user feels<br>that they are moving.<br><br>I&#39;ve been asked to modify our script to include logging the camera<br>orientation and position every 250ms.&nbsp;&nbsp;I&#39;ve hit two areas that confuse<br>
me.<br><br>1. The script currently creates a log file with a hardcoded name.&nbsp;&nbsp;I&#39;d<br>like to change this so that the name of the file is<br>&lt;dateAndTimeFirstOpened&gt;.log, so that logs are not accidentally<br>overwritten.<br>
<br>set logFile [open &quot;GSV_log.log&quot; w 0666]<br><br>would replacing the above with something like<br><br>set logFile [open &quot;[clock format [clock seconds]].log&quot; w 0666]<br><br>be anything close to proper syntax?<br>
<br>2.&nbsp;&nbsp;I&#39;m confused about how I would create a loop that would write a line<br>to said logfile at a given time interval.&nbsp;&nbsp;What&#39;s a good way to think<br>about this, or do it?<br><br><br>Thanks,<br><br>-graham<br>_______________________________________________<br>
This is the private VTK discussion list.<br>Please keep messages on-topic. Check the FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ">http://www.vtk.org/Wiki/VTK_FAQ</a><br>Follow this link to subscribe/unsubscribe:<br><a href="http://www.vtk.org/mailman/listinfo/vtkusers">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
</blockquote></div>