JPEG2000 compression rate is not obeyed
Owner's note: The issue subject has changed. Please jump to: https://github.com/Efferent-Health/fo-dicom.Codecs/issues/81#issuecomment-2270736377
Previous description:
Hi @cbeltran1306 This issue doesn't seems to be fixed. I am using the latest version 5.14.2 the sample image and code are as below
DicomFile dicomFile = await DicomFile.OpenAsync("inputfilepath"); var codecParams = new FellowOakDicom.Imaging.NativeCodec.DicomJpeg2000Params { Rate = 20}; DicomFile compressed = dicomFile.Clone(DicomTransferSyntax.JPEG2000Lossy, codecParams); await compressed.SaveAsync("outfilepath");
It would be great help if you can take a look. Thanks
Originally posted by @kundanashish in https://github.com/Efferent-Health/fo-dicom.Codecs/issues/24#issuecomment-2245979878
Hi @kundanashish the latest version is 5.14.4 (https://www.nuget.org/packages/fo-dicom.Codecs/5.14.4). I've tested this dicom file without problems.
Hi @cbeltran1306
Thanks for pointing it out.
Looks like 5.14.4 is able to convert the file. But I see the compression issue rate is not obeyed
I want quality to be 20. Am I missing something. Thanks
Actually previously we were using this https://github.com/dcm4che/dcm4che/blob/master/dcm4che-tool/dcm4che-tool-dcm2dcm/README.md
passing -Q as 20 resulting the quality to be 20
Hello @kundanashish, this issue has been solved. Please use the latest nuget version 5.14.5 (https://www.nuget.org/packages/fo-dicom.Codecs/5.14.5)
@cbeltran1306 Yeah it did thanks a lot for support