Medical Imaging Interaction Toolkit  2018.04.99-3ec0dd08
Medical Imaging Interaction Toolkit
mitk::DICOMImageBlockDescriptor Class Reference

Output descriptor for DICOMFileReader. More...

#include <mitkDICOMImageBlockDescriptor.h>

Inheritance diagram for mitk::DICOMImageBlockDescriptor:
Collaboration diagram for mitk::DICOMImageBlockDescriptor:

Public Types

typedef std::map< DICOMTagPath, std::string > AdditionalTagsMapType
 
typedef std::function< mitk::BaseProperty::Pointer(const DICOMCachedValueLookupTable &) > TagLookupTableToPropertyFunctor
 

Public Member Functions

 DICOMImageBlockDescriptor ()
 
 ~DICOMImageBlockDescriptor () override
 
 DICOMImageBlockDescriptor (const DICOMImageBlockDescriptor &other)
 
DICOMImageBlockDescriptoroperator= (const DICOMImageBlockDescriptor &other)
 
void SetImageFrameList (const DICOMImageFrameList &framelist)
 List of frames that constitute the mitk::Image (DICOMImageFrames) More...
 
const DICOMImageFrameListGetImageFrameList () const
 List of frames that constitute the mitk::Image (DICOMImageFrames) More...
 
void SetMitkImage (Image::Pointer image)
 The 3D mitk::Image that is loaded from the DICOM files of a DICOMImageFrameList. More...
 
Image::Pointer GetMitkImage () const
 the 3D mitk::Image that is loaded from the DICOM files of a DICOMImageFrameList More...
 
ReaderImplementationLevel GetReaderImplementationLevel () const
 Reader's capability to appropriately load this set of frames. More...
 
void SetReaderImplementationLevel (const ReaderImplementationLevel &level)
 Reader's capability to appropriately load this set of frames. More...
 
void SetProperty (const std::string &key, BaseProperty *value)
 Key-value store describing aspects of the image to be loaded. More...
 
BasePropertyGetProperty (const std::string &key) const
 Key-value store describing aspects of the image to be loaded. More...
 
std::string GetPropertyAsString (const std::string &) const
 Convenience function around GetProperty() More...
 
void SetFlag (const std::string &key, bool value)
 Convenience function around SetProperty() More...
 
bool GetFlag (const std::string &key, bool defaultValue) const
 Convenience function around GetProperty() More...
 
void SetIntProperty (const std::string &key, int value)
 Convenience function around SetProperty() More...
 
int GetIntProperty (const std::string &key, int defaultValue) const
 Convenience function around GetProperty() More...
 
BaseProperty::ConstPointer GetConstProperty (const std::string &propertyKey, const std::string &contextName="", bool fallBackOnDefaultContext=true) const override
 Get property by its key. More...
 
std::vector< std::string > GetPropertyKeys (const std::string &contextName="", bool includeDefaultContext=false) const override
 Query keys of existing properties. More...
 
std::vector< std::string > GetPropertyContextNames () const override
 Query names of existing contexts. More...
 
PixelSpacingInterpretation GetPixelSpacingInterpretation () const
 Describe how the mitk::Image's pixel spacing should be interpreted. More...
 
void GetDesiredMITKImagePixelSpacing (ScalarType &spacingXinMM, ScalarType &spacingYinMM) const
 Describe the correct x/y pixel spacing of the mitk::Image (which some readers might need to adjust after loading) More...
 
void SetTiltInformation (const GantryTiltInformation &info)
 Describe the gantry tilt of the acquisition. More...
 
const GantryTiltInformation GetTiltInformation () const
 Describe the gantry tilt of the acquisition. More...
 
void SetSOPClassUID (const std::string &uid)
 SOP Class UID of this set of frames. More...
 
std::string GetSOPClassUID () const
 SOP Class UID of this set of frames. More...
 
std::string GetSOPClassUIDAsName () const
 SOP Class as human readable name (e.g. "CT Image Storage") More...
 
int GetNumberOfTimeSteps () const
 
int GetNumberOfFramesPerTimeStep () const
 
void SetTagCache (DICOMTagCache *privateCache)
 
void SetAdditionalTagsOfInterest (const AdditionalTagsMapType &tagMap)
 Set a list of DICOMTagPaths that specifiy all DICOM-Tags that will be copied into the property of the mitk::Image. More...
 
void SetTagLookupTableToPropertyFunctor (TagLookupTableToPropertyFunctor)
 Set a functor that defines how the slice-specific tag-values are stored in a Property. More...
 
void Print (std::ostream &os, bool filenameDetails) const
 Print information about this image block to given stream. More...
 
- Public Member Functions inherited from mitk::IPropertyProvider
virtual ~IPropertyProvider ()
 

Static Public Member Functions

static DICOMTagList GetTagsOfInterest ()
 

Detailed Description

Output descriptor for DICOMFileReader.

As a result of analysis by a mitk::DICOMFileReader, this class describes the properties of a single mitk::Images that could be loaded by the file reader.

The descriptor contains the following information:

  • the mitk::Image itself. This will be nullptr after analysis and only be present after actual loading.
  • a list of frames (mostly: filenames) that went into composition of the mitk::Image.
  • an assessment of the reader's ability to load this set of files (ReaderImplementationLevel)
  • this can be used for reader selection when one reader is able to load an image with correct colors and the other is able to produce only gray values, for example
  • description of aspects of the image. Mostly a key-value list implemented by means of mitk::PropertyList.
  • for specific keys and possible values, see documentation of specific readers.
Note
an mitk::Image may both consist of multiple files (the "old" DICOM way) or a mitk::Image may be described by a single DICOM file or even only parts of a DICOM file (the newer multi-frame DICOM classes). To reflect this DICOMImageFrameList describes a list of frames from different or a single file.

Described aspects of an image are:

  • whether pixel spacing is meant to be in-patient or on-detector (mitk::PixelSpacingInterpretation)
  • details about a possible gantry tilt (intended for use by file readers, may be hidden later)

Definition at line 77 of file mitkDICOMImageBlockDescriptor.h.

Member Typedef Documentation

◆ AdditionalTagsMapType

Type specifies additional tags of interest. Key is the tag path of interest. The value is an optional user defined name for the property that should be used to store the tag value(s). Empty value is default and will imply to use the found DICOMTagPath as property name.

Definition at line 170 of file mitkDICOMImageBlockDescriptor.h.

◆ TagLookupTableToPropertyFunctor

Constructor & Destructor Documentation

◆ DICOMImageBlockDescriptor() [1/2]

mitk::DICOMImageBlockDescriptor::DICOMImageBlockDescriptor ( )

◆ ~DICOMImageBlockDescriptor()

mitk::DICOMImageBlockDescriptor::~DICOMImageBlockDescriptor ( )
override

◆ DICOMImageBlockDescriptor() [2/2]

mitk::DICOMImageBlockDescriptor::DICOMImageBlockDescriptor ( const DICOMImageBlockDescriptor other)

Member Function Documentation

◆ GetConstProperty()

BaseProperty::ConstPointer mitk::DICOMImageBlockDescriptor::GetConstProperty ( const std::string &  propertyKey,
const std::string &  contextName = "",
bool  fallBackOnDefaultContext = true 
) const
overridevirtual

Get property by its key.

Parameters
[in]propertyKeyKey of property.
[in]contextNameOptional, default is empty string (default context). Search in specified context.
[in]fallBackOnDefaultContextOptional, default is true. Also search in default context if property was not found in given context.
Returns
Found property, nullptr otherwise.

Implements mitk::IPropertyProvider.

◆ GetDesiredMITKImagePixelSpacing()

void mitk::DICOMImageBlockDescriptor::GetDesiredMITKImagePixelSpacing ( ScalarType spacingXinMM,
ScalarType spacingYinMM 
) const

Describe the correct x/y pixel spacing of the mitk::Image (which some readers might need to adjust after loading)

◆ GetFlag()

bool mitk::DICOMImageBlockDescriptor::GetFlag ( const std::string &  key,
bool  defaultValue 
) const

Convenience function around GetProperty()

◆ GetImageFrameList()

const DICOMImageFrameList& mitk::DICOMImageBlockDescriptor::GetImageFrameList ( ) const

List of frames that constitute the mitk::Image (DICOMImageFrames)

◆ GetIntProperty()

int mitk::DICOMImageBlockDescriptor::GetIntProperty ( const std::string &  key,
int  defaultValue 
) const

Convenience function around GetProperty()

◆ GetMitkImage()

Image::Pointer mitk::DICOMImageBlockDescriptor::GetMitkImage ( ) const

the 3D mitk::Image that is loaded from the DICOM files of a DICOMImageFrameList

◆ GetNumberOfFramesPerTimeStep()

int mitk::DICOMImageBlockDescriptor::GetNumberOfFramesPerTimeStep ( ) const

return the number of frames that constitute one timestep.

◆ GetNumberOfTimeSteps()

int mitk::DICOMImageBlockDescriptor::GetNumberOfTimeSteps ( ) const

Convinience method that returns the property timesteps

◆ GetPixelSpacingInterpretation()

PixelSpacingInterpretation mitk::DICOMImageBlockDescriptor::GetPixelSpacingInterpretation ( ) const

Describe how the mitk::Image's pixel spacing should be interpreted.

◆ GetProperty()

BaseProperty* mitk::DICOMImageBlockDescriptor::GetProperty ( const std::string &  key) const

Key-value store describing aspects of the image to be loaded.

◆ GetPropertyAsString()

std::string mitk::DICOMImageBlockDescriptor::GetPropertyAsString ( const std::string &  ) const

Convenience function around GetProperty()

◆ GetPropertyContextNames()

std::vector<std::string> mitk::DICOMImageBlockDescriptor::GetPropertyContextNames ( ) const
overridevirtual

Query names of existing contexts.

Returns
List of context names.

Implements mitk::IPropertyProvider.

◆ GetPropertyKeys()

std::vector<std::string> mitk::DICOMImageBlockDescriptor::GetPropertyKeys ( const std::string &  contextName = "",
bool  includeDefaultContext = false 
) const
overridevirtual

Query keys of existing properties.

Parameters
[in]contextNameOptional, default is empty string (default context). Search in specified context.
[in]includeDefaultContextOptional, default is false. Include default context.
Returns
List of property keys.

Implements mitk::IPropertyProvider.

◆ GetReaderImplementationLevel()

ReaderImplementationLevel mitk::DICOMImageBlockDescriptor::GetReaderImplementationLevel ( ) const

Reader's capability to appropriately load this set of frames.

◆ GetSOPClassUID()

std::string mitk::DICOMImageBlockDescriptor::GetSOPClassUID ( ) const

SOP Class UID of this set of frames.

◆ GetSOPClassUIDAsName()

std::string mitk::DICOMImageBlockDescriptor::GetSOPClassUIDAsName ( ) const

SOP Class as human readable name (e.g. "CT Image Storage")

◆ GetTagsOfInterest()

static DICOMTagList mitk::DICOMImageBlockDescriptor::GetTagsOfInterest ( )
static

◆ GetTiltInformation()

const GantryTiltInformation mitk::DICOMImageBlockDescriptor::GetTiltInformation ( ) const

Describe the gantry tilt of the acquisition.

◆ operator=()

DICOMImageBlockDescriptor& mitk::DICOMImageBlockDescriptor::operator= ( const DICOMImageBlockDescriptor other)

◆ Print()

void mitk::DICOMImageBlockDescriptor::Print ( std::ostream &  os,
bool  filenameDetails 
) const

Print information about this image block to given stream.

◆ SetAdditionalTagsOfInterest()

void mitk::DICOMImageBlockDescriptor::SetAdditionalTagsOfInterest ( const AdditionalTagsMapType tagMap)

Set a list of DICOMTagPaths that specifiy all DICOM-Tags that will be copied into the property of the mitk::Image.

This method can be used to specify a list of DICOM-tags that shall be available after the loading. The value in the tagMap is an optional user defined name for the property key that should be used when storing the property). Empty value is default and will imply to use the found DICOMTagPath as property key. By default the content of the DICOM tags will be stored in a StringLookupTable on the mitk::Image. This behaviour can be changed by setting a different TagLookupTableToPropertyFunctor via SetTagLookupTableToPropertyFunctor().

◆ SetFlag()

void mitk::DICOMImageBlockDescriptor::SetFlag ( const std::string &  key,
bool  value 
)

Convenience function around SetProperty()

◆ SetImageFrameList()

void mitk::DICOMImageBlockDescriptor::SetImageFrameList ( const DICOMImageFrameList framelist)

List of frames that constitute the mitk::Image (DICOMImageFrames)

◆ SetIntProperty()

void mitk::DICOMImageBlockDescriptor::SetIntProperty ( const std::string &  key,
int  value 
)

Convenience function around SetProperty()

◆ SetMitkImage()

void mitk::DICOMImageBlockDescriptor::SetMitkImage ( Image::Pointer  image)

The 3D mitk::Image that is loaded from the DICOM files of a DICOMImageFrameList.

◆ SetProperty()

void mitk::DICOMImageBlockDescriptor::SetProperty ( const std::string &  key,
BaseProperty value 
)

Key-value store describing aspects of the image to be loaded.

◆ SetReaderImplementationLevel()

void mitk::DICOMImageBlockDescriptor::SetReaderImplementationLevel ( const ReaderImplementationLevel level)

Reader's capability to appropriately load this set of frames.

◆ SetSOPClassUID()

void mitk::DICOMImageBlockDescriptor::SetSOPClassUID ( const std::string &  uid)

SOP Class UID of this set of frames.

◆ SetTagCache()

void mitk::DICOMImageBlockDescriptor::SetTagCache ( DICOMTagCache privateCache)

◆ SetTagLookupTableToPropertyFunctor()

void mitk::DICOMImageBlockDescriptor::SetTagLookupTableToPropertyFunctor ( TagLookupTableToPropertyFunctor  )

Set a functor that defines how the slice-specific tag-values are stored in a Property.

This method sets a functor that is given a StringLookupTable that contains the values of one DICOM tag mapped to the slice index. The functor is supposed to store these values in an mitk Property.

By default, the StringLookupTable is stored in a StringLookupTableProperty except if all values are identical. In this case, the unique value is stored only once in a StringProperty.

◆ SetTiltInformation()

void mitk::DICOMImageBlockDescriptor::SetTiltInformation ( const GantryTiltInformation info)

Describe the gantry tilt of the acquisition.


The documentation for this class was generated from the following file: