<html><head></head><body bgcolor="#FFFFFF"><div></div><p class="MsoNormal">Hi,</p><p class="MsoNormal">I asked this last week, but didn't get any response. I haven't been able to solve the problem so thought I'd try the list again.</p><p class="MsoNormal">I am trying to use the reslicing classes, based on the example in Examples\GUI\Qt\FourPaneViewer, although I am not using QT.</p><p class="MsoNormal"> <span class="Apple-style-span">I have this code,</span></p><p class="MsoNormal"></p><p class="MsoNormal">vtkSmartPointer<vtkImageData> image;</p><p class="MsoNormal">// image creation code snipped</p><p class="MsoNormal">auto riw = vtkSmartPointer<vtkResliceImageViewer>::New();</p><p class="MsoNormal">riw->SetRenderWindow(render_window_->GetRenderWindow());</p><p class="MsoNormal">riw->SetupInteractor(vtkSmartPointer<vtkRenderWindowInteractor>::New());</p><p class="MsoNormal">riw->SetResliceCursor(riw[0]->GetResliceCursor());</p><p class="MsoNormal">rep->GetResliceCursorActor()->GetCursorAlgorithm()->SetReslicePlaneNormal(i);</p><p class="MsoNormal">riw->SetInput(image);</p><p class="MsoNormal">riw->SetSliceOrientation(0);</p><p class="MsoNormal">riw->SetResliceModeToAxisAligned();</p><p class="MsoNormal"> </p><p class="MsoNormal">This fails on the penultimate line, the call to SetSliceOrientation(), and seems to be because I have set the Input directly and the library is expecting a pipeline algorithm.</p><p class="MsoNormal">Is this the case, and can anyone please suggest how to overcome this? Is there a pipeline algorithm to feed vtkImageData in a call to SetInputConnection() or is that the wrong route?</p><p class="MsoNormal"> </p><p class="MsoNormal">Here's my call stack; note the inPtr is NULL calling into vtkImageMapperConvertImageScalarsToRGBA() and beyond:</p><p class="MsoNormal"> </p><p class="MsoNormal">vtkRendering.dll!vtkImageMapperShiftScale<double,double>(const double * inPtr=0x00000000, ... Line 487 C++</p><p class="MsoNormal">vtkRendering.dll!vtkImageMapperConvertImageScalarsToRGBA(void * inPtr=0x00000000, ... Line 611 C++</p><p class="MsoNormal">vtkRendering.dll!vtkImageMapperMapColors(void * arg=0x28b16b9c) Line 787 C++</p><p class="MsoNormal">vtkCommon.dll!vtkMultiThreader::SingleMethodExecute() Line 292 C++</p><p class="MsoNormal">vtkRendering.dll!vtkImageMapper3D::MakeTextureData(vtkImageProperty * property=0x28b160c8, vtkImageData * input=0x28b1adb8, ... Line 949 C++</p><p class="MsoNormal">vtkRendering.dll!vtkOpenGLImageSliceMapper::RenderTexturedPolygon(...) Line 276 C++</p><p class="MsoNormal">vtkRendering.dll!vtkOpenGLImageSliceMapper::RecursiveRenderTexturedPolygon(...) Line 150 C++</p><p class="MsoNormal">vtkRendering.dll!vtkOpenGLImageSliceMapper::Render(...) Line 1089 C++</p><p class="MsoNormal">vtkRendering.dll!vtkImageSlice::Render(...) Line 320 C++</p><p class="MsoNormal">vtkRendering.dll!vtkImageSlice::RenderOpaqueGeometry(vtkViewport * viewport=0x28b1baf0) Line 275 C++</p><p class="MsoNormal">vtkRendering.dll!vtkRenderer::UpdateGeometry() Line 630 C++</p><p class="MsoNormal">vtkRendering.dll!vtkOpenGLRenderer::DeviceRender() Line 247 C++</p><p class="MsoNormal">vtkRendering.dll!vtkRenderer::Render() Line 345 C++</p><p class="MsoNormal">vtkRendering.dll!vtkRendererCollection::Render() Line 51 C++</p><p class="MsoNormal">vtkRendering.dll!vtkRenderWindow::DoStereoRender() Line 726 C++</p><p class="MsoNormal">vtkRendering.dll!vtkRenderWindow::DoFDRender() Line 692 C++</p><p class="MsoNormal">vtkRendering.dll!vtkRenderWindow::DoAARender() Line 579 C++</p><p class="MsoNormal">vtkRendering.dll!vtkRenderWindow::Render() Line 392 C++</p><p class="MsoNormal">vtkRendering.dll!vtkImageViewer2::Render() Line 688 C++</p><p class="MsoNormal">vtkWidgets.dll!vtkResliceImageViewer::Render() Line 420 C++</p><p class="MsoNormal">vtkRendering.dll!vtkImageViewer2::SetSliceOrientation(int orientation=0) Line 301 C++</p><p class="MsoNormal"><span class="Apple-style-span">[myapp]</span></p><br>Thanks<div>-- Craig</div><div><br></div></body></html>