Comments (10)
@kuehlc are you making sure the server has the appropriate CORS headers set? Do you have a snippet/example?
from cornerstonewebimageloader.
@dannyrb The call is to the same code server side as the one that works with the same image in an older version of the project. The only difference that I can tell is the version of cornerstone. Are you asking for a snippet of the server side code, or which part do you want to see?
from cornerstonewebimageloader.
@dannyrb when I've looked at the dev tools for the return, the headers are the same for the one that works. They both allow for CORS. The blob for the one that doesn't work never finishes being created, so it doesn't show. It fails during cornerstone.loadImage call.
from cornerstonewebimageloader.
@dannyrb Were you able to see the example links from my first comment where it works in the old, but not the new, and how the same link that works in the old one doesn't work in the rawgit page? I don't want to rush you or anything. I get that this is an open source project. I just want to make sure what I posted was clear enough so you could see the issue.
from cornerstonewebimageloader.
@kuehlc, using the default JPEG image, I see these return headers:
Using your provided link, I see the following headers:
You can either match the response, or create a new loader that works with the response your API is using.
I do see where the application at the RSNA domain is successfully using the API endpoint in question, but because the source is minified, I'm not sure if they're doing any extra magic to decode the response.
It does look like both the web and wado image loaders are registered, and an older version of the libraries is being used. I don't believe any changes to the web image loader would have broken the the response parsing; to my knowledge, it's expected jpeg/png response for years.
from cornerstonewebimageloader.
@dannyrb So you're saying you believe that the working RSNA link is using JavaScript to manipulate the response? Thanks for the answer. I'll look more into these.
from cornerstonewebimageloader.
@dannyrb We found that they modified how they were handling the response as you mentioned. I'm going to modify the php. Does load image just expect the base64 string back directly, or what does it want? I'm looking at the code for the loadImage, but the answer is evading me for some reason for how the blob is created. Thanks in advance.
from cornerstonewebimageloader.
After this, I'll close the ticket.
from cornerstonewebimageloader.
Create Image is where the magic happens: https://github.com/cornerstonejs/cornerstoneWebImageLoader/blob/master/src/createImage.js#L57-L79
from cornerstonewebimageloader.
Okay, thank you.
from cornerstonewebimageloader.
Related Issues (20)
- ment
- 0.7.2 tag should be deleted HOT 1
- Add loadFileRequest and fileManager infrastructure HOT 2
- issues when loading a png (corruption?) HOT 2
- Associating image metaData HOT 2
- Readme includes instructions for building/running w/ Grunt, but project appears to use webpack HOT 1
- Package import issue HOT 4
- Cannot display PNG image HOT 4
- Loading from relative paths HOT 4
- 404 of cornerstoneWebImageLoader HOT 3
- Applying Filters on Images loaded HOT 1
- wen WebImageLoader wwwc not correct work HOT 1
- metaDataProvider imagePlaneModule get pixelSpacing
- Remove reference to dist/ from readme.md HOT 2
- Reference line functionality not working
- can this work with cornerstoneTools 4.x.x
- PNG colormap example
- IE 11 InvalidStateError when setting xhr.responseType.
- Version Issue HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cornerstonewebimageloader.