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
589 stars 299 forks source link

[Feature Request] Add LoaderOptions support for nifti-volume-loader #1403

Open frank-msft opened 4 months ago

frank-msft commented 4 months ago

What feature or change would you like to see made?

dicom-image-loader supports LoaderOptions, which allow the application to specify HTTP headers for authentication. This feature request is to add LoaderOptions to nifti-volume-loader to support authentication.

Why should we prioritize this feature?

nifti-volume-loader will be able to support OAuth2 authorization header to access images.

Authorization: Bearer 0b79bab50daca910b000d4f1a2b675d604257e42

sedghi commented 4 months ago

I agree that we should add it. Could you take the lead on this? Since we don't use Cornerstone WADO for loading, perhaps the cornerstone.init function should accept new parameters like beforeSend or something similar to what we do in the WADO loader.