Hi, David,<br><br>I thought vtkResliceViewer provides the method SliceScrollOnMouseWheelOn() which support DICOM slice switching according to the mouse wheel forward or backward. If we don't use vtkResliceViewer, what class do you use for displaying the three 2D views of DICOM supporting reslice?<br><div><br>Thanks<br>Liu Peng<br></div>
 <span>
 </span>
<br>      在2016-03-20,"David Gobbi" <david.gobbi@gmail.com> 写道:
        <blockquote id="isReplyContent" style="padding-left:1ex; margin: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
        -----原始邮件-----<br>
        <b>发件人:</b>"David Gobbi" <david.gobbi@gmail.com> <br>
        <b>发送时间:</b>2016年03月20日 星期日<br>
        <b>收件人:</b>"Liu_tj" <tjlp@netease.com><br>
        <b>抄送:</b>"vtkusers" <vtkusers@vtk.org><br>
        <b>主题:</b>Re: [vtkusers] Error "The interactor must be set prior to enabling the widget" using vtkResliceImageViewer<br>
<br><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Sun, Mar 20, 2016 at 8:52 AM, Liu_tj <span dir="ltr"><<a href="mailto:tjlp@netease.com" target="_blank">tjlp@netease.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>Hi, VTK guys,</div><div><br></div><div>I am using Activiz VTK 7.0 for my C# application. I try to use vtkResliceImageViewer to display DICOM axial, coronal or saggital view. The vtkRenderWindow is defined in a WPF user control. When I run my application, I get this error reported:</div><div><br></div><div><div>ERROR: In ..\..\..\VTK-7.0\Interaction\Widgets\vtkAbstractWidget.cxx, line 118</div><div>vtkResliceCursorWidget (0000000025A638B0): The interactor must be set prior to enabling the widget</div><div><br></div><div>ERROR: In ..\..\..\VTK-7.0\Interaction\Widgets\vtkAbstractWidget.cxx, line 118</div><div>vtkResliceCursorWidget (0000000025A638B0): The interactor must be set prior to enabling the widget</div><div><br></div><div>Below is my code. Do I miss any step?</div></div></blockquote><div><br></div><div>I don't use vtkResliceImageViewer, but my guess is that since you call SetRenderWindow(), you should also call SetRenderer() and SetupInteractor().</div><div><br></div><div>You can get the renderer from the render window with GetRenderer(), but you will probably have to create your own interactor.</div><div><br></div><div> - David</div><div> </div></div></div></div>
</blockquote><br><br><span title="neteasefooter"><p> </p></span>