Discussion Forum for OFFIS DICOM Tools - For registration, send email with desired user name to the OFFIS DICOM team
It is currently Mon, 2018-10-22, 18:18

All times are UTC + 1 hour

Post new topic Reply to topic  [ 1 post ] 
Author Message
PostPosted: Wed, 2012-09-05, 22:16 

Joined: Mon, 2012-05-21, 08:37
Posts: 9
Is it possible to use DcmItem::findAndGetString() and related functions with a private tag (declared with a DcmTag object) that is defined with the upper byte left as empty in the data dictionary?

E.g., its entry in private.dic looks like:
(2005,"Philips MR Imaging DD 001",0a)

In the dicom data the creator and data tags could look like:
(2005,0010) "Philips MR Imaging DD 001"
(2005,100a) "data!"

(2005,0014) "Philips MR Imaging DD 001"
(2005,140a) "data!"

What I've gleaned from other posts and the how-to doc, here's what I've got:

 DcmDataDictionary &dict = dcmDataDict.wrlock();
 dict.addEntry(new DcmDictEntry(0x2005, 0x0d, EVR_FL, "InvertedRescaleIntercept, 1, 1, "private", OFTrue, "Philips MR Imaging 001");
DcmTag my_tag(0x2005, 0x0d, "Philips MR Imaging 001");
DcmDataset *ds = ...
const char *my_string;
ds->findAndGetString(my_tag, my_string);

This does not work: it simply cannot find the tag.
As a potentially related problem looking at my_tag in the above example, the dictionary look-up fails, so, my_tag doesn't have a VR associated with it.

So is this designed to work this way, or do I have to examine the dataset, looking for the creator codes for the private tag groups and create the my_tag object above dynamically based on which tag element number is used for the creator code?

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1 post ] 

All times are UTC + 1 hour

Who is online

Users browsing this forum: Google [Bot] and 1 guest

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group