<div dir="ltr">Hi Matt,<div><br></div><div>yes, otherwise I guess I couldn't see anything:</div><div><br></div><div><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(128,0,0)">con</span><span style="color:rgb(0,0,0)">-></span><span style="color:rgb(0,0,0)">SetInput</span><span style="color:rgb(0,0,0)">(itkImage</span><span style="color:rgb(0,0,0)">);</span></pre>
<pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(128,0,0)">con</span><span style="color:rgb(0,0,0)">-></span><span style="font-style:italic;color:rgb(0,0,0)">Update</span><span style="color:rgb(0,0,0)">();</span></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(0,0,0)"><br></span></pre><pre style="margin-top:0px;margin-bottom:0px"><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(128,0,0)">imageData</span><span style="color:rgb(0,0,0)">-></span><span style="font-style:italic;color:rgb(0,0,0)">DeepCopy</span><span style="color:rgb(0,0,0)">(</span><span style="color:rgb(0,0,0)">con</span><span style="color:rgb(0,0,0)">-></span><span style="color:rgb(0,0,0)">GetOutput</span><span style="color:rgb(0,0,0)">());</span></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(128,0,0)">imageViewer</span><span style="color:rgb(0,0,0)">-></span><span style="font-style:italic;color:rgb(0,0,0)">SetInputData</span><span style="color:rgb(0,0,0)">(</span><span style="color:rgb(128,0,0)">imageData</span><span style="color:rgb(0,0,0)">);</span></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(128,0,0)">imageViewer</span><span style="color:rgb(0,0,0)">-></span><span style="font-style:italic;color:rgb(0,0,0)">GetRenderer</span><span style="color:rgb(0,0,0)">()-></span><span style="color:rgb(0,0,0)">ResetCamera</span><span style="color:rgb(0,0,0)">();</span></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(0,0,0)"><br></span></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(0,0,0)">// some renderwindow and interactor settings for the widget</span></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(0,0,0)"><br></span></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(0,0,0)">widget->update()</span></pre></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(0,0,0)"><br></span></pre><pre style="margin-top:0px;margin-bottom:0px"><br></pre><pre style="margin-top:0px;margin-bottom:0px"><font color="#000000">I'd like to change frames, but I guess I'm sending just one frame.</font></pre><pre style="margin-top:0px;margin-bottom:0px"><font color="#000000">Also, I can't find an example from ITK to access each frame. If I can't set a pipeline so I can do it from VTK, maybe I can read a slice in ITK when I need it and pass that frame through the connector and update.</font></pre><pre style="margin-top:0px;margin-bottom:0px"><font color="#000000"><br></font></pre><pre style="margin-top:0px;margin-bottom:0px"><font color="#000000">Maybe I shouldn't use an itk::ImageFileReader, I don't know.</font></pre><pre style="margin-top:0px;margin-bottom:0px"><span style="color:rgb(0,0,0)"><br></span></pre></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-08-29 1:52 GMT+02:00 Matt McCormick <span dir="ltr"><<a href="mailto:matt.mccormick@kitware.com" target="_blank">matt.mccormick@kitware.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Marcos,<br>
<br>
Are you calling ->Update() on connector?<br>
<br>
Matt<br>
<div><div class="h5"><br>
On Fri, Aug 28, 2015 at 7:37 PM, Marcos <<a href="mailto:fotosentido@gmail.com">fotosentido@gmail.com</a>> wrote:<br>
> Hi,<br>
><br>
> I'm using itk::ImageToVTKImageFilter to connect itk::ImageFileReader with<br>
> vtkImageViewer2.<br>
><br>
> I can visualize my image in QVTKWidget.<br>
><br>
> I don't know if I'm reading correctly with ITK to pass that to VTK:<br>
><br>
> I'd like to access every frame, but vtkImageViewer2::getMaxSlice() is<br>
> returning 0 every time.<br>
><br>
> I'm connecting the pipeline with:<br>
><br>
> imageData->DeepCopy(connector->GetOutput());<br>
><br>
> imageViewer->SetInputData(imageData);<br>
><br>
><br>
><br>
> Any ideas?<br>
><br>
> Thanks.<br>
><br>
</div></div>> _____________________________________<br>
> Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
><br>
> Visit other Kitware open-source projects at<br>
> <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
><br>
> Kitware offers ITK Training Courses, for more information visit:<br>
> <a href="http://www.kitware.com/products/protraining.php" rel="noreferrer" target="_blank">http://www.kitware.com/products/protraining.php</a><br>
><br>
> Please keep messages on-topic and check the ITK FAQ at:<br>
> <a href="http://www.itk.org/Wiki/ITK_FAQ" rel="noreferrer" target="_blank">http://www.itk.org/Wiki/ITK_FAQ</a><br>
><br>
> Follow this link to subscribe/unsubscribe:<br>
> <a href="http://public.kitware.com/mailman/listinfo/insight-users" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/insight-users</a><br>
><br>
</blockquote></div><br></div>