OFFIS DCMTK
Version 3.6.0
|
Interface class to DICOM data management (dcmdata). More...
Public Member Functions | |
DiDocument (const char *filename, const unsigned long flags=0, const unsigned long fstart=0, const unsigned long fcount=0) | |
constructor, open a DICOM file More... | |
DiDocument (DcmObject *object, const E_TransferSyntax xfer, const unsigned long flags=0, const unsigned long fstart=0, const unsigned long fcount=0) | |
constructor, use a given DcmObject More... | |
virtual | ~DiDocument () |
destructor | |
int | good () const |
check whether current document is valid More... | |
DcmObject * | getDicomObject () const |
get current DICOM object (dataset) More... | |
DcmDataset * | getDataset () const |
get current DICOM dataset More... | |
unsigned long | getFrameStart () const |
get first frame to be processed More... | |
unsigned long | getFrameCount () const |
get number of frames to be processed More... | |
unsigned long | getFlags () const |
get configuration flags More... | |
E_TransferSyntax | getTransferSyntax () const |
get transfer syntax of the DICOM dataset More... | |
const char * | getPhotometricInterpretation () const |
get photometric interpretation (color model). More... | |
DcmPixelData * | getPixelData () const |
get pixel data object More... | |
OFBool | isCompressed () const |
check whether pixel data only exist in compressed format More... | |
DcmElement * | search (const DcmTagKey &tag, DcmObject *obj=NULL) const |
search for given tag More... | |
int | search (const DcmTagKey &tag, DcmStack &stack) const |
search for given tag and put result(s) on a stack More... | |
unsigned long | getVM (const DcmTagKey &tag) const |
get value multiplicity (VM) of given tag More... | |
unsigned long | getValue (const DcmTagKey &tag, Uint16 &returnVal, const unsigned long pos=0, DcmObject *item=NULL, const OFBool allowSigned=OFFalse) const |
get value of given tag (Uint16) More... | |
unsigned long | getValue (const DcmTagKey &tag, Sint16 &returnVal, const unsigned long pos=0) const |
get value of given tag (Sint16) More... | |
unsigned long | getValue (const DcmTagKey &tag, Uint32 &returnVal, const unsigned long pos=0) const |
get value of given tag (Uint32) More... | |
unsigned long | getValue (const DcmTagKey &tag, Sint32 &returnVal, const unsigned long pos=0) const |
get value of given tag (Sint32) More... | |
unsigned long | getValue (const DcmTagKey &tag, double &returnVal, const unsigned long pos=0) const |
get value of given tag (double) More... | |
unsigned long | getValue (const DcmTagKey &tag, const Uint16 *&returnVal, DcmObject *item=NULL) const |
get value of given tag (Uint16 array) More... | |
unsigned long | getValue (const DcmTagKey &tag, const char *&returnVal, DcmObject *item=NULL) const |
get value of given tag (const char *) More... | |
unsigned long | getValue (const DcmTagKey &tag, OFString &returnVal, const unsigned long pos=0, DcmObject *item=NULL) const |
get value of given tag (OFString) More... | |
unsigned long | getSequence (const DcmTagKey &tag, DcmSequenceOfItems *&seq) const |
get sequence of given tag More... | |
![]() | |
void | addReference () |
add a reference. More... | |
void | removeReference () |
remove a reference. More... | |
Static Public Member Functions | |
static unsigned long | getElemValue (const DcmElement *elem, Uint16 &returnVal, const unsigned long pos=0, const OFBool allowSigned=OFFalse) |
get value of given element (Uint16) More... | |
static unsigned long | getElemValue (const DcmElement *elem, const Uint16 *&returnVal) |
get value of given element (Uint16 array) More... | |
static unsigned long | getElemValue (const DcmElement *elem, const char *&returnVal) |
get value of given element (const char *) More... | |
static unsigned long | getElemValue (const DcmElement *elem, OFString &returnVal, const unsigned long pos=0) |
get value of given element (OFString) More... | |
Protected Member Functions | |
void | convertPixelData () |
convert pixel data to uncompressed representation (if required) | |
![]() | |
DiObjectCounter () | |
constructor. More... | |
virtual | ~DiObjectCounter () |
destructor | |
Private Member Functions | |
DiDocument (const DiDocument &) | |
DiDocument & | operator= (const DiDocument &) |
Private Attributes | |
DcmObject * | Object |
reference to DICOM dataset (in memory) | |
DcmFileFormat * | FileFormat |
reference to DICOM fileformat (read from file, maybe NULL) | |
DcmPixelData * | PixelData |
reference to pixel data object | |
E_TransferSyntax | Xfer |
transfer syntax used for reading the dataset | |
unsigned long | FrameStart |
first frame to be processed | |
unsigned long | FrameCount |
number of frames to be processed | |
unsigned long | Flags |
configuration flags | |
OFString | PhotometricInterpretation |
photometric interpretation (color model) | |
Interface class to DICOM data management (dcmdata).
NB: This is an internal class of module dcmimgle/dcmimage. Please do not use it for accessing DICOM data structures. Instead use the classes and functions provided by dcmdata (e.g. class DcmFileFormat, DcmItem).
DiDocument::DiDocument | ( | const char * | filename, |
const unsigned long | flags = 0 , |
||
const unsigned long | fstart = 0 , |
||
const unsigned long | fcount = 0 |
||
) |
constructor, open a DICOM file
filename | the DICOM file |
flags | configuration flags (only stored for later use) |
fstart | first frame to be processed (only stored for later use) |
fcount | number of frames (only stored for later use) |
DiDocument::DiDocument | ( | DcmObject * | object, |
const E_TransferSyntax | xfer, | ||
const unsigned long | flags = 0 , |
||
const unsigned long | fstart = 0 , |
||
const unsigned long | fcount = 0 |
||
) |
constructor, use a given DcmObject
object | pointer to DICOM data structures |
xfer | transfer syntax |
flags | configuration flags (only stored for later use) |
fstart | first frame to be processed (only stored for later use) |
fcount | number of frames (only stored for later use) |
|
inline |
get current DICOM dataset
Definition at line 124 of file didocu.h.
References Object.
Referenced by DiInputPixelTemplate< T1, T2 >::convert().
|
inline |
|
static |
get value of given element (Uint16)
elem | element where the value is stored |
returnVal | reference to the storage area for the resulting value |
pos | position in muti-valued elements (starting with 0) |
allowSigned | also allow signed value (Sint16) if true |
Referenced by isCompressed().
|
static |
get value of given element (Uint16 array)
elem | element where the value is stored |
returnVal | reference to the storage area for the resulting value |
|
static |
get value of given element (const char *)
elem | element where the value is stored |
returnVal | reference to the storage area for the resulting value |
|
static |
get value of given element (OFString)
elem | element where the value is stored |
returnVal | reference to the storage area for the resulting value |
pos | position in muti-valued elements (starting with 0) |
|
inline |
get configuration flags
Definition at line 151 of file didocu.h.
References Flags.
Referenced by DiInputPixelTemplate< T1, T2 >::convert().
|
inline |
get number of frames to be processed
Definition at line 142 of file didocu.h.
References FrameCount.
|
inline |
get first frame to be processed
Definition at line 133 of file didocu.h.
References FrameStart.
|
inline |
get photometric interpretation (color model).
Please note that this is the color model of the decompressed image which might deviate from the color model of the original compressed image.
Definition at line 171 of file didocu.h.
References OFString::c_str(), and PhotometricInterpretation.
Referenced by DiInputPixelTemplate< T1, T2 >::convert().
|
inline |
get pixel data object
Definition at line 180 of file didocu.h.
References PixelData.
Referenced by DiInputPixelTemplate< T1, T2 >::convert(), and DiInputPixelTemplate< T1, T2 >::DiInputPixelTemplate().
unsigned long DiDocument::getSequence | ( | const DcmTagKey & | tag, |
DcmSequenceOfItems *& | seq | ||
) | const |
get sequence of given tag
tag | tag to search for |
seq | reference to the storage area for the resulting value |
Referenced by isCompressed().
|
inline |
unsigned long DiDocument::getValue | ( | const DcmTagKey & | tag, |
Uint16 & | returnVal, | ||
const unsigned long | pos = 0 , |
||
DcmObject * | item = NULL , |
||
const OFBool | allowSigned = OFFalse |
||
) | const |
get value of given tag (Uint16)
tag | tag to search for |
returnVal | reference to the storage area for the resulting value |
pos | position in muti-valued elements (starting with 0) |
item | element in the dataset where the search should start (default: root) |
allowSigned | also allow signed value (Sint16) if true |
Referenced by isCompressed().
unsigned long DiDocument::getValue | ( | const DcmTagKey & | tag, |
Sint16 & | returnVal, | ||
const unsigned long | pos = 0 |
||
) | const |
get value of given tag (Sint16)
tag | tag to search for |
returnVal | reference to the storage area for the resulting value |
pos | position in muti-valued elements (starting with 0) |
unsigned long DiDocument::getValue | ( | const DcmTagKey & | tag, |
Uint32 & | returnVal, | ||
const unsigned long | pos = 0 |
||
) | const |
get value of given tag (Uint32)
tag | tag to search for |
returnVal | reference to the storage area for the resulting value |
pos | position in muti-valued elements (starting with 0) |
unsigned long DiDocument::getValue | ( | const DcmTagKey & | tag, |
Sint32 & | returnVal, | ||
const unsigned long | pos = 0 |
||
) | const |
get value of given tag (Sint32)
tag | tag to search for |
returnVal | reference to the storage area for the resulting value |
pos | position in muti-valued elements (starting with 0) |
unsigned long DiDocument::getValue | ( | const DcmTagKey & | tag, |
double & | returnVal, | ||
const unsigned long | pos = 0 |
||
) | const |
get value of given tag (double)
tag | tag to search for |
returnVal | reference to the storage area for the resulting value |
pos | position in muti-valued elements (starting with 0) |
unsigned long DiDocument::getValue | ( | const DcmTagKey & | tag, |
const Uint16 *& | returnVal, | ||
DcmObject * | item = NULL |
||
) | const |
get value of given tag (Uint16 array)
tag | tag to search for |
returnVal | reference to the storage area for the resulting value |
item | element in the dataset where the search should start (default: root) |
unsigned long DiDocument::getValue | ( | const DcmTagKey & | tag, |
const char *& | returnVal, | ||
DcmObject * | item = NULL |
||
) | const |
get value of given tag (const char *)
tag | tag to search for |
returnVal | reference to the storage area for the resulting value |
item | element in the dataset where the search should start (default: root) |
unsigned long DiDocument::getValue | ( | const DcmTagKey & | tag, |
OFString & | returnVal, | ||
const unsigned long | pos = 0 , |
||
DcmObject * | item = NULL |
||
) | const |
get value of given tag (OFString)
tag | tag to search for |
returnVal | reference to the storage area for the resulting value |
pos | position in muti-valued elements (starting with 0) |
item | element in the dataset where the search should start (default: root) |
unsigned long DiDocument::getVM | ( | const DcmTagKey & | tag | ) | const |
get value multiplicity (VM) of given tag
tag | tag to be searched |
Referenced by isCompressed().
|
inline |
|
inline |
check whether pixel data only exist in compressed format
Definition at line 189 of file didocu.h.
References convertPixelData(), getElemValue(), getSequence(), getValue(), getVM(), DcmXfer::isEncapsulated(), search(), and Xfer.
DcmElement* DiDocument::search | ( | const DcmTagKey & | tag, |
DcmObject * | obj = NULL |
||
) | const |
search for given tag
tag | tag to search for |
obj | element in the dataset where the search should start (default: root) |
Referenced by isCompressed().
search for given tag and put result(s) on a stack
tag | tag to search for |
stack | stack where the result(s) should be stored |