How to use encode #103
Replies: 4 comments
-
Your example code does not use I don't know what format |
Beta Was this translation helpful? Give feedback.
-
HIi @patrickhulce sorry i have updated the code and the link which i am following for the objective, so if you can please loo at the question.... |
Beta Was this translation helpful? Give feedback.
-
This is expected behavior for your example code. You aren't actually using any of the image pixel data from the dicom file. You're explicitly filling a pixel array with all red pixels. |
Beta Was this translation helpful? Give feedback.
-
I'm going to go ahead and convert this issue to a discussion since it appears you are mostly looking for basic usage assistance. Perhaps someone in the community will have the bandwidth to assist you further (or try Stack Overflow where this sort of request has more eager help 😃 ) (Sidenote: I don't know much about dicom format but I would be surprised if they use uncompressed image data. You might want to start there to understand more deeply what dicom-parser is returning to you and how to convert it to raw pixel data. See their docs...
|
Beta Was this translation helpful? Give feedback.
-
Hi, I am trying to get JPEG/PNG image from a Dicom image using Dicom parser.
Initially, i am reading the Dicom file and converting it into raw pixel data
Next after generating raw pixel data, i am trying to save it into an image file and for that i am using writefileSync.
And, the image file is also generated but it is not opening, seems like the generated image is not what i have used as input instead it is coming all red
i am following this this
https://stackoverflow.com/questions/49511099/getting-image-from-dicom-dcm-file-in-node-js
link.Can anyone help me on this
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions