[Dcmlib] Bug in ComputeRLEInfo

jean-michel.rouet at philips.com jean-michel.rouet at philips.com
Tue Nov 16 12:00:08 CET 2004


Hi all,

Ok so the error I got was not about the nbRleSegments... I did not pay 
attention enough to the Dicom pdf...
Nevertheless the following code still suffers from a slight problem:

rleSegmentOffsetTable is declared as a 15 long array, and the filling loop 
(the one with ReadInt32) goes from index 1 to 15 included.

>>       uint32_t rleSegmentOffsetTable[15];
>>       for( int k = 1; k <= 15; k++ )
>>       {
>>          rleSegmentOffsetTable[k] = ReadInt32();
>>       }

If you start at index 1 and end at 15, then the rleSegmentOffsetTable 
should be allocated as a 16 long array and not 15, so that 
rleSegmentOffsetTable[15] is defined.

>> TestReadWriteReadCompare was always failing on acuson RLE encoded 
images.
>This is surely platteform dependant, because
>gdcmbin/bin/gdcmTests TestReadWriteReadCompare
>runs smoothly on my fedora core 2.
>Additionaly on today's dashboard
>http://public.kitware.com/dashboard.php?name=public
>the only place were TestReadWriteReadCompare fails is on DarwinG5-g++
>http://public.kitware.com/Public/Sites/midworld.kitwarein/GDCM-DarwinG5-g++/2004
>1115-0830-Experimental/Test.html
>but the ACUSON files are not the culprit ones:
>http://public.kitware.com/Public/Sites/midworld.kitwarein/GDCM-DarwinG5-g++/2004
>1115-0830-Experimental/Results/__Test_TestReadWriteReadCompare.html
>
>Hummmmmmmm, what is going wrong here ?

I still cannot answer that question... It seems that my Visual Studio 7.1 
causes a lot of problems with gdcm...

JM

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.creatis.insa-lyon.fr/pipermail/dcmlib/attachments/20041116/741bef3b/attachment.html>


More information about the Dcmlib mailing list