<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style id="owaParaStyle" type="text/css">P {margin-top:0;margin-bottom:0;}</style>
</head>
<body ocsi="0" fpstyle="1">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">Having got my program to build and run with VTK-6.3, I am now encountering a problem with its behaviour. The 3D display of the scene is working fine, but code that captures the
image (for creating a video) is failing.<br>
<br>
Previously I have been doing this with VTK-5.10:<br>
<br>
<span style=" color:#c0c0c0;"></span><font color="000000">id = vtkImageData::New();
</font>
<pre style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><font color="000000">id = w2i->GetOutput();</font></pre>
<font color="000000"></font>
<pre style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><font color="000000">w2i-><span style="font-style: italic;">Modified</span>();</font></pre>
<font color="000000">id->Update(); </font>
<pre style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><font color="000000">imwidth = id->GetDimensions()[0];</font></pre>
<font color="000000"></font>
<pre style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><font color="000000">imheight = id->GetDimensions()[1];</font></pre>
<span style=" color:#000000;">if (</span><span style=" color:#000000;">imwidth</span><span style=" color:#c0c0c0;">
</span><span style=" color:#000000;">==</span><span style=" color:#c0c0c0;"> </span>
<span style=" color:#000080;">0</span><span style=" color:#000000;">)</span><span style=" color:#c0c0c0;">
</span><span style=" color:#000000;">{</span>
<pre style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" color:#c0c0c0;"> </span>LOG_QMSG<span style=" color:#000000;">(</span><span style=" color:#008000;">"ERROR:</span><span style=" color:#c0c0c0;"> </span><span style=" color:#008000;">recorder:</span><span style=" color:#c0c0c0;"> </span><span style=" color:#008000;">vtkImageData</span><span style=" color:#c0c0c0;"> </span><span style=" color:#008000;">dimension</span><span style=" color:#c0c0c0;"> </span><span style=" color:#008000;">=</span><span style=" color:#c0c0c0;"> </span><span style=" color:#008000;">0"</span><span style=" color:#000000;">);</span></pre>
<pre style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" color:#c0c0c0;"> </span>exit<span style=" color:#000000;">(</span><span style=" color:#000080;">1</span><span style=" color:#000000;">);</span></pre>
<pre style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" color:#c0c0c0;"></span><span style=" color:#000000;">}<br><font face="Arial"><br>To get this to compile now I have to comment out the id->Update(). When the program executes it stops with the error that imwidth=0.<br><br>Should I replace id->Update() with something else?<br><br>Thanks<br>Gib<br></font></span></pre>
<font face="Arial"></font>
<pre style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><font face="Arial"><br></font></pre>
<br>
</div>
</body>
</html>