Medical Imaging Interaction Toolkit  2016.11.0
Medical Imaging Interaction Toolkit
mitkTbssRoiImageSource.cpp
Go to the documentation of this file.
1 /*===================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center,
6 Division of Medical and Biological Informatics.
7 All rights reserved.
8 
9 This software is distributed WITHOUT ANY WARRANTY; without
10 even the implied warranty of MERCHANTABILITY or FITNESS FOR
11 A PARTICULAR PURPOSE.
12 
13 See LICENSE.txt or http://www.mitk.org for details.
14 
15 ===================================================================*/
16 
17 #ifndef __MITK_NRRD_TBSSROI_VOLUMES_IO_FACTORY_CPP__
18 #define __MITK_NRRD_TBSSROI_VOLUMES_IO_FACTORY_CPP__
19 
20 #include "mitkTbssRoiImageSource.h"
21 #include "mitkTbssRoiImage.h"
22 
23 
25 {
26  // Create the output. We use static_cast<> here because we know the default
27  // output must be of type DiffusionImage
29  = static_cast<mitk::TbssRoiImage*>(this->MakeOutput(0).GetPointer());
30 
31  Superclass::SetNumberOfRequiredOutputs(1);
32  Superclass::SetNthOutput(0, output.GetPointer());
33 }
34 
35 
36 itk::DataObject::Pointer mitk::TbssRoiImageSource::MakeOutput ( DataObjectPointerArraySizeType /*idx*/ )
37 {
38  return OutputType::New().GetPointer();
39 }
40 
41 
43 {
44  itkDebugMacro("MakeOutput(" << name << ")");
45  if( this->IsIndexedOutputName(name) )
46  {
47  return this->MakeOutput( this->MakeIndexFromOutputName(name) );
48  }
49  return static_cast<itk::DataObject *>(OutputType::New().GetPointer());
50 }
51 
52 
53 
55 {
56  return static_cast<OutputType*>
57  (this->ProcessObject::GetOutput(idx));
58 }
59 
60 #endif //__MITK_NRRD_TBSS_VOULMES_IO_FACTORY_CPP__
itk::DataObject::DataObjectIdentifierType DataObjectIdentifierType
itk::SmartPointer< Self > Pointer
this class encapsulates diffusion volumes (vectorimages not yet supported by mitkImage) ...
Base of all data objects.
Definition: mitkBaseData.h:39
OutputType * GetOutput()
Get the output data of this image source object.
virtual itk::DataObject::Pointer MakeOutput(DataObjectPointerArraySizeType idx) override
static itkEventMacro(BoundingShapeInteractionEvent, itk::AnyEvent) class MITKBOUNDINGSHAPE_EXPORT BoundingShapeInteractor Pointer New()
Basic interaction methods for mitk::GeometryData.