14 #include <vtkRenderer.h> 15 #include <vtkFloatArray.h> 16 #include <vtkPlaneSource.h> 17 #include <vtkPointData.h> 18 #include <vtkTriangleFilter.h> 19 #include <vtkStripper.h> 20 #include <vtkImageData.h> 21 #include <vtkLookupTable.h> 39 mSharedOpenGLContext(context)
54 for (
unsigned i=0; i<mProxy.size(); ++i)
62 reportWarning(
"Slices3DRep::setImages: No input images (in ViewGroup)");
65 for (
unsigned i=0; i<mProxy.size(); ++i)
67 mProxy[i]->setImages(images);
68 mProxy[i]->getSliceProxy()->setDefaultCenter(images[0]->get_rMd().coord(images[0]->boundingBox().center()));
75 sliceProxy->initializeFromPlane(plane,
false,
true, 150, 0.25);
76 sliceProxy->setAlwaysUseDefaultCenter(
true);
79 current->setSliceProxy(sliceProxy);
80 current->setTargetSpaceToR();
82 mProxy.push_back(current);
87 for (
unsigned i=0; i<mProxy.size(); ++i)
88 mProxy[i]->getSliceProxy()->setTool(tool);
93 for (
unsigned i=0; i<mProxy.size(); ++i)
94 view->getRenderer()->AddActor(mProxy[i]->getActor());
99 for (
unsigned i=0; i<mProxy.size(); ++i)
100 view->getRenderer()->RemoveActor(mProxy[i]->getActor());
void setShaderPath(QString path)
static SliceProxyPtr create(PatientModelServicePtr dataManager)
Slices3DRep(SharedOpenGLContextPtr context)
static boost::shared_ptr< REP > wrap_new(REP *object, QString uid)
boost::shared_ptr< class View > ViewPtr
virtual void removeRepActorsFromViewRenderer(ViewPtr view)
boost::shared_ptr< class SharedOpenGLContext > SharedOpenGLContextPtr
boost::shared_ptr< class Slices3DRep > Slices3DRepPtr
void reportWarning(QString msg)
boost::shared_ptr< class PatientModelService > PatientModelServicePtr
Default implementation of Rep.
boost::shared_ptr< class Texture3DSlicerProxy > Texture3DSlicerProxyPtr
static Slices3DRepPtr New(SharedOpenGLContextPtr context, const QString &uid)
void setImages(std::vector< ImagePtr > images)
virtual void addRepActorsToViewRenderer(ViewPtr view)
void setTool(ToolPtr tool)
void addPlane(PLANE_TYPE plane, PatientModelServicePtr dataManager)
static Texture3DSlicerProxyPtr New(SharedOpenGLContextPtr context)
Namespace for all CustusX production code.
boost::shared_ptr< class Tool > ToolPtr