cornerstonejs / cornerstone

JavaScript library to display interactive medical images including but not limited to DICOM
https://docs.cornerstonejs.org/
MIT License
2.04k stars 598 forks source link

Using pixel array data instead of dcm image file? [question] #541

Open AvaHayako opened 3 years ago

AvaHayako commented 3 years ago

Hi, I am modifying a web application that displays .dcm images using Cornerstone. Without changing too much of the implementation, I am exploring the idea of using an hdf5 file to store and access image pixel data, as opposed to using local files of .dcm images.

I'm able to render images from the pixel data without the use of cornerstone, but this isn't ideal as the web app uses cornerstone for displaying image slices and interacting with them (via cornerstone tools).

Does cornerstone have a feature that allows you to input pixel array data instead of an image/image path?

Thanks!

swederik commented 3 years ago

Yes, just write an image loader that grabs the pixel data from the HDF5 file: https://docs.cornerstonejs.org/concepts/image-loaders.html

withHam commented 2 years ago

Will this approach also work for a jpeg2000 file?