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
 RLE encoding for DICOM images
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

yeohray2

Malaysia
100 Posts

Posted - Nov 08 2022 :  03:52:26  Show Profile  Reply
After saving DICOM images using RLE encoding, I sometimes cannot display those saved images in ImageEn.

The issue with my saved images is that RLE stream size for the RLE high bytes is larger compared to the RLE stream size for the low bytes. Thus, when reading the low bytes, the existing check:

if imageLength div 2 + Stream.Position > Stream.Size then
begin
Progress.Aborting^ := true;
exit;
end;

will always trigger.

Is it safe to change the check to this instead, which takes into account the bytes already read for the RLE high bytes?

if Stream.Position + (ImageLength - Stream.Position + base + idxArray[0] ) > Stream.Size ...

Thanks.

Ray


xequte

38182 Posts

Posted - Nov 10 2022 :  14:44:22  Show Profile  Reply
Hi Ray

Can you email us your sample files and the steps to reproduce this?

Nigel
Xequte Software
www.imageen.com
Go to Top of Page

yeohray2

Malaysia
100 Posts

Posted - Nov 10 2022 :  19:24:25  Show Profile  Reply
Hi Nigel,

I've sent the files to you via email, as I cannot share the images publicly. Thanks.

Ray
Go to Top of Page

xequte

38182 Posts

Posted - Nov 14 2022 :  21:55:19  Show Profile  Reply
Please email me for a fix for this.

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