-
Notifications
You must be signed in to change notification settings - Fork 315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Render volume feature not working as expected #481
Comments
@sedghi I think this may be related to the cornerstone-wado-image-loader feature, I'm going to put in a fix for this based on our discussion which hopefully solves the above ^ |
try the newest |
upgrade the cornerstone-wado-image-loader |
Yeah, sorry for not clarifying that one, same result also with: "cornerstone-wado-image-loader": "4.10.2", |
can you try latest core? |
Same result with config: "@cornerstonejs/core": "0.36.2",
"@cornerstonejs/streaming-image-volume-loader": "0.15.5",
"@cornerstonejs/tools": "0.55.1",
"@kitware/vtk.js": "26.9.5",
"cornerstone-wado-image-loader": "4.10.2", Steps:
Maybe could be something wrong in the initialization process, here is the config file I'm using for the example: import dicomParser from 'dicom-parser';
import * as cornerstone from '@cornerstonejs/core';
import * as cornerstoneTools from '@cornerstonejs/tools';
import cornerstoneWADOImageLoader from 'cornerstone-wado-image-loader';
window.cornerstone = cornerstone;
window.cornerstoneTools = cornerstoneTools;
export const initCornerstoneWADOImageLoader = () => {
cornerstoneWADOImageLoader.external.cornerstone = cornerstone;
cornerstoneWADOImageLoader.external.dicomParser = dicomParser;
cornerstoneWADOImageLoader.configure({
useWebWorkers: true,
decodeConfig: {
convertFloatPixelDataToInt: false,
},
});
let maxWebWorkers = 1;
if (navigator.hardwareConcurrency) {
maxWebWorkers = Math.min(navigator.hardwareConcurrency, 7);
}
const config = {
maxWebWorkers,
startWebWorkersOnDemand: false,
taskConfiguration: {
decodeTask: {
initializeCodecsOnStartup: false,
strict: false,
},
},
};
cornerstoneWADOImageLoader.webWorkerManager.initialize(config);
};
declare global {
interface Window {
cornerstone: any;
cornerstoneTools: any;
}
} |
It is very strange, does it happen for stackViewport too? |
Yes, it does. Stackviewport code const viewportInput = {
viewportId: viewportId1,
element: currentElement as HTMLDivElement,
type: ViewportType.STACK,
};
const engine = new RenderingEngine(RENDER_ENGINE_ID);
renderingEngine.current = engine;
engine.enableElement(viewportInput);
const viewport = engine.getViewport(viewportInput.viewportId);
if (!('setStack' in viewport)) return;
viewport.setStack(DEFAULT_IMAGE_IDS, 1);
viewport.render(); Working exampleNot working example |
@makinox @sedghi this PR should fix the issue for 16bit data types cornerstonejs/cornerstoneWADOImageLoader#522 |
Subject of the issue
Hello guys, I hope you are having a good day.
I'm testing some
CT
andPT
studies, but the colors do not seem to be ok.With the tool
WindowLevelTool
I realized that the contrast or saturation of the volume were not the problemI'm sharing two series completely anonymized if you want to test this behavior: https://drive.google.com/file/d/1fkLx2A_yJX-6R8JM-U-1Ubg6M4mMVj6z/view?usp=share_link
My environment
Steps to reproduce
Expected behavior
Actual behavior
The volume rendered presents wrong colors
Screen.Recording.2023-03-15.at.10.46.03.AM.mov
Please let me know if you need additional information.
The text was updated successfully, but these errors were encountered: