cornerstonejs / cornerstone3D

Cornerstone is a set of JavaScript libraries that can be used to build web-based medical imaging applications. It provides a framework to build radiology applications such as the OHIF Viewer.
https://cornerstonejs.org
MIT License
584 stars 298 forks source link

[Bug] Can not decode some JPEG 2000 Lossless compression Dicom image with @cornerstonejs/dicom-image-loader #1057

Open tuvm opened 9 months ago

tuvm commented 9 months ago

Describe the Bug

The library @cornerstonejs/dicom-image-loader might could not decode some JPEG 2000 lossless compression Dicom image. I got the these messages on worker: image

Steps to Reproduce

  1. Open the image with cornerstone3d, I get the error as above. Link to dicom file: https://github.com/tuvm/dicoms/blob/main/dicom2_anon.dcm
  2. Try to use the cornerstone-wado-image-loader library, the image is decoded and display well.

The current behavior

I think there is an issue inside the decoder but I am not familiar with c++. Could you help to resolve it? Thanks.

The expected behavior

Hope the new lib can decode the image.

OS

Ubuntu

Node version

18.12.1

Browser

Chrome Version 111.0.5563.64 (Official Build) (64-bit)

tuvm commented 9 months ago

Hi @sedghi, please help me check this issue. Thanks.

sedghi commented 9 months ago

Try the latest codec and see if it works https://www.npmjs.com/package/@cornerstonejs/codec-openjpeg

tuvm commented 9 months ago

I am using version 1.2.2, I see the new version 1.2.3 but it could not be download. Might be a publishing issue.

sedghi commented 9 months ago

what error does it give

tuvm commented 9 months ago

image I can not download it. Just click to the version 1.2.3. Yarn or npm still get ver 1.2.2 although dependency is set to 1.2.3

tuvm commented 9 months ago

Successfull download ver 1.2.3 but it still could not decode the image. image

aodong8808 commented 4 months ago

image Has anyone solved this problem? Version 1.2.4 still exists,

sedghi commented 2 weeks ago

is this still an issue after Cornerstone3D 2.0 release?

sedghi commented 1 week ago

Can you check the latest OHIF viewer, which now includes Cornerstone 3D 2.0?

Here are the migration guides:

Try OHIF locally: https://viewer-dev.ohif.org/localbasic
Try Cornerstone3D 2.0 locally: https://www.cornerstonejs.org/live-examples/local.html

https://docs.ohif.org/migration-guide/3p8-to-3p9/