ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Maybe a Small Bug in ReadTag
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

jwest

Brazil
67 Posts

Posted - May 30 2016 :  22:16:33  Show Profile  Reply
Hi, Mr Nigel,

I am trying read a DICOMDIR file.

To read it correctly, I derived a new component from TIEDicomTags class and I am working with it now.

I had to do a fix in ReadTag function to read SQ nested items. For sample,
if I had 6 items in my SQ tag, only the first was been read.

May be my fix can be useful for DICOM images also.

function TDicomReadContext.ReadTag(tags: TIEDicomTags): boolean;
....
.....
 if vr = dvSQ then
      begin
        // read sequence of tags (Children)
        lpos := Stream.Position;
        Children := TObjectList.Create();
        //// look for "Item tag"
        //while (Stream.Position < lpos + datasize) or (datasize <= 0) do  -->I did a fix to
        while (Stream.Position <= lpos + datasize) or (datasize <= 0) do  --        begin

xequte

38947 Posts

Posted - May 31 2016 :  21:13:13  Show Profile  Reply
Thanks, implemented in the latest beta.

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: