get DSRWaveformReferenceValue

All other questions regarding DCMTK

Moderator: Moderator Team

Post Reply
Message
Author
ancrou
Posts: 13
Joined: Tue, 2008-07-01, 16:54
Location: Nancy France

get DSRWaveformReferenceValue

#1 Post by ancrou »

Hi,

I've found the function which used the DSRWaveformReferenceValue. Nevertheless I've not found yet, how should I get the DSRWaveformReferenceValue :oops:
The aim of my project is to read DICOM file.

Best regards

Michael Onken
DCMTK Developer
Posts: 2051
Joined: Fri, 2004-11-05, 13:47
Location: Oldenburg, Germany
Contact:

#2 Post by Michael Onken »

Hi,

there is no real tutorial on how to use DCMTK. For reading and writing DICOM files in general, you use functions from the module "dcmdata", which resides in the directory with the same name. It is documented here, including a short code example for reading/writing specific attributes.

The most important class for accessing specific values is DcmItem, whose API is documented here.

Regards,
Michael

ancrou
Posts: 13
Joined: Tue, 2008-07-01, 16:54
Location: Nancy France

#3 Post by ancrou »

Hi Michael,

Thanks for your answer.

I can get the DcmItems (eg: Patient’s Name, Patient ID, ...) . Moreover I can get the DcmSequenceOfItems.
But I cannot get the DSRWaveform. It's sad because there are some functions whose used the waveform (eg: DSRWaveformChannelItem, ...).

So what is the connexion between DSRWaveform and DcmFileFormat.

Best regards,

Anth

Jörg Riesmeier
ICSMED DICOM Services
ICSMED DICOM Services
Posts: 2217
Joined: Fri, 2004-10-29, 21:38
Location: Oldenburg, Germany

#4 Post by Jörg Riesmeier »

Class DSRWaveformReferenceValue is used for DICOM Structured Reporting documents only (see module "dcmsr").
The aim of my project is to read DICOM file.
What exactly do you want to do?

ancrou
Posts: 13
Joined: Tue, 2008-07-01, 16:54
Location: Nancy France

#5 Post by ancrou »

I want to plot the ECG waveform. For that, I need to read the values in (5400,1010) Waveform Data, ...
I tried the following code :

Code: Select all

DcmSequenceOfItems* dseq;
if(fileformat.getDataset()->findAndGetSequence(DCM_WaveformSequence,dseq).good())
But I don't know to use the DcmSequenceOfItems.

Moreover I tried the following code:

Code: Select all

const Uint16* value;
fileformat.getDataset()->findAndGetUint16Array(DCM_WaveformData,value);
:cry: :oops:

Michael Onken
DCMTK Developer
Posts: 2051
Joined: Fri, 2004-11-05, 13:47
Location: Oldenburg, Germany
Contact:

#6 Post by Michael Onken »

Hi,

e. g. you can try that:

Code: Select all

DcmDataset* dset = NULL;
dset = fileformat.getDataset();
DcmItem *item = NULL;
if(dset->findAndGetSequenceItem(DCM_WaveformSequence,item,0).good())
{
 // now item has a pointer to the first item (0) in the Waveform Sequence.
}
Regards,
Michael

Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Bing [Bot] and 1 guest