MeVisLab Toolbox Reference
ml::DirectDicomImportDPLTagValueProvider Class Reference

An DPL::TagValueProvider class for the DirectDicomImport module. More...

#include <mlDirectDicomImportDPLTagValueProvider.h>

Inheritance diagram for ml::DirectDicomImportDPLTagValueProvider:

Classes

struct  HardOverwriteTag
 Simple structure of a tag id and a string which overwrites this tag value. More...
 

Public Member Functions

 DirectDicomImportDPLTagValueProvider (DPL::Logger &logger, DirectDicomImportImporterBase &importer, const std::vector< HardOverwriteTag > &hardOverwriteTags)
 Constructs a new TagValueProviderExample with the base directory. More...
 
void setAllowSortingAccordingToDimensionIndexValues (const std::string &allowMode)
 Determines whether or how the DimensionIndexValue tag value can be used instead of a missing ImagePositionPatient tag. More...
 
const std::string & setAllowSortingAccordingToDimensionIndexValues () const
 Returns the value set by setAllowSortingAccordingToDimensionIndexValues. More...
 
void setWorkaroundImageOrientationPatientTag (const std::string &workaroundValue)
 The default ImageOrientationPatient tag to be used instead of a non existing one for the case that an ImagePositionPatient tag exists. More...
 
const std::string & getWorkaroundImageOrientationPatientTag () const
 Returns the value set by setWorkaroundImageOrientationPatientTag. More...
 
const ConstantStringgetFrameName () const
 The frame name from which the recent tag was retrieved. More...
 
DPL::TagValue getTagValue (const DPL::FrameId fullFilePath, const DPL::TagInfo &tagInfo, DPL::ErrorInfo *error=nullptr) const override
 Retrieves the value for the tag in the specified DICOM file. More...
 

Detailed Description

An DPL::TagValueProvider class for the DirectDicomImport module.

It looks up DICOM information from files in the file system using the DCMTree library to perform the DICOM lookups. Also, any file with a valid DICOM tree is cached for faster lookups in later calls.

Definition at line 55 of file mlDirectDicomImportDPLTagValueProvider.h.

Constructor & Destructor Documentation

◆ DirectDicomImportDPLTagValueProvider()

ml::DirectDicomImportDPLTagValueProvider::DirectDicomImportDPLTagValueProvider ( DPL::Logger &  logger,
DirectDicomImportImporterBase importer,
const std::vector< HardOverwriteTag > &  hardOverwriteTags 
)

Constructs a new TagValueProviderExample with the base directory.

Parameters
loggerInstance to which messages can be sent.
importerThe importer for which the DICOM tags shall be provided (used for interruption checks).
hardOverwriteTagsPair list of tag ids and values to replace original tag values by other ones.

Member Function Documentation

◆ getFrameName()

const ConstantString& ml::DirectDicomImportDPLTagValueProvider::getFrameName ( ) const

The frame name from which the recent tag was retrieved.

◆ getTagValue()

DPL::TagValue ml::DirectDicomImportDPLTagValueProvider::getTagValue ( const DPL::FrameId  fullFilePath,
const DPL::TagInfo &  tagInfo,
DPL::ErrorInfo *  error = nullptr 
) const
override

Retrieves the value for the tag in the specified DICOM file.

Parameters
fullFilePathThe name of the file specified as a FrameId type.
tagInfoTag information object, should be valid and contain the id of the tag to look up.
errorThe error information object which is set to information codes about the argument errors or about the find state of the requested tags.
Returns
a TagValue object representing the retrieved value of the tag in the file, or an invalid TagValue object if the tag was not found.

◆ getWorkaroundImageOrientationPatientTag()

const std::string& ml::DirectDicomImportDPLTagValueProvider::getWorkaroundImageOrientationPatientTag ( ) const

Returns the value set by setWorkaroundImageOrientationPatientTag.

◆ setAllowSortingAccordingToDimensionIndexValues() [1/2]

const std::string& ml::DirectDicomImportDPLTagValueProvider::setAllowSortingAccordingToDimensionIndexValues ( ) const

Returns the value set by setAllowSortingAccordingToDimensionIndexValues.

◆ setAllowSortingAccordingToDimensionIndexValues() [2/2]

void ml::DirectDicomImportDPLTagValueProvider::setAllowSortingAccordingToDimensionIndexValues ( const std::string &  allowMode)

Determines whether or how the DimensionIndexValue tag value can be used instead of a missing ImagePositionPatient tag.

Currently only "Auto" and "Off" are valid modes.

◆ setWorkaroundImageOrientationPatientTag()

void ml::DirectDicomImportDPLTagValueProvider::setWorkaroundImageOrientationPatientTag ( const std::string &  workaroundValue)

The default ImageOrientationPatient tag to be used instead of a non existing one for the case that an ImagePositionPatient tag exists.

This is a workaround for buggy data sets, because normally both should be available as pair. Default is "" which means that no replacement takes place.


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