On 28 November 2011 23:24, Kris Thielemans <kris.f.thielem...@gmail.com> wrote: > Hi Andy > > I had a look at why dicominfo doesn't store/dump sequence elements (VR=SQ). > It turns out that this is very easy to fix. In element2value, you have near > the beginning > > // skip "Group Length" tags. note: these are deprecated in DICOM > 2008 > if(tag.GetElement() == (uint16_t)0 || elem->GetByteValue() == NULL) > return DICOM_NOTHING_ASSIGNED; > > However, sequence elements do have NULL GetByteValue(), so they never get > processed by the rest of the function. Modifying this statement to take this > into account fixes this: > > if(tag.GetElement() == (uint16_t)0 || (elem->GetByteValue() == NULL > && vr != gdcm::VR::SQ)) > return DICOM_NOTHING_ASSIGNED; > > With this tiny tweak, the rest of your code works fine. I now get e.g. > RadioPharmaceutical info back which is MATLAB compatible. Great! Shall I > commit this? (Also removing 3 include files that we're not using) > > After this commit, I don't know of any problems with this code anymore. My > application (which was developed for matlab) works fine (but it doesn't use > a lot of dicom fields admittedly). There's presumably a need for some > changes to make this into a real package, but I have no idea about that. > > > Kris Thielemans > Algorithms and Software Consulting Ltd (http://asc.uk.com) > Honorary Lecturer at Imperial College London
excellent. over the last couple of days, I compiled octave 3.4.3 and GDCM 2.0.18 on openSuSE 12.1. The DICOM package did not compile for me. what versions are you using? I have not spent very long on it yet. hopefully, with your fixes, we can make the first release of the dicom package soon. I hope that this will bring in more contributors. -- /* andy buckle */ ------------------------------------------------------------------------------ All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d _______________________________________________ Octave-dev mailing list Octave-dev@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/octave-dev