Giter Site home page Giter Site logo

Comments (6)

pieper avatar pieper commented on August 15, 2024

Hi -

Basically with the cross-compiled dcmtk code you have access to the same utilities that dcmtk provides on a desktop or server system. So you could use dcmodify to change the tag values. It may be easiest to look at the dump example to see how to invoke a dcmtk utility from javascript.

In the 'organize' example, we took the approach of dumping the data and converting to a DOM that we could easily manipulate and then converting back to dicom for output. It's a little convoluted but it does work.

Also, just so you are aware, there is a new version of dcmjs at a very preliminary stage that implements some of the dcmtk-like functionality in pure javascript, so it's much lighter weight and more easily extensible. The new code is not yet ready for prime time, but we hope it is getting closer.

-Steve

from dcmjs.org.

parthmehta17888 avatar parthmehta17888 commented on August 15, 2024

Hi Steve,

Thanks for the update. Please tell me once you done with the newer version of dcmjs. It will be very helpful for me.

Thanks,
PM

from dcmjs.org.

AlexanderKoehn avatar AlexanderKoehn commented on August 15, 2024

Just a note: the organize example does not work anymore, since the dump2dcm tool is not part of https://github.com/commontk/dcmjs.org/blob/gh-pages/javascripts/libs/dcmjs.js.
And unfortunately one can not recompile atm as described here: commontk/dcmjs#17
I will have a look at dcmjs pure js

from dcmjs.org.

pieper avatar pieper commented on August 15, 2024

Thanks for the report - yes, there's a of "mechanism" involved in the cross-compiling where the pure-javascript part can be dead simple. I've been meaning to port the 'organize' functionality but haven't gotten around to it. Would be glad to have help.

from dcmjs.org.

AlexanderKoehn avatar AlexanderKoehn commented on August 15, 2024

Thanks for the report - yes, there's a of "mechanism" involved in the cross-compiling where the pure-javascript part can be dead simple. I've been meaning to port the 'organize' functionality but haven't gotten around to it. Would be glad to have help.

So you would port it using xml2dcm since this is ON or using the new js only dcmjs?

from dcmjs.org.

pieper avatar pieper commented on August 15, 2024

Originally I had planned to use dcm2xml and xml2dcm but it turned out the raw data save/restore path wasn't supported, so I couldn't recreate a valid dicom object with the pixel data. That's why there's the whole dcmdump/dump2dcm workaround. I was glad that it was able to work at all, but for porting I would definitely use the new dcmjs-org version. It's smaller, faster, more logical, etc.

The only real drawback is that it isn't as widely tested as dcmtk and no doubt there are features of dcmtk that are not supported in pure js currently.

from dcmjs.org.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.