我正在尝试使用基石库显示Dicom Image。我已经使用了来自https://github.com/cornerstonejs/cornerstone/blob/master/example/jsminimal/index.html的the最小示例代码。我所包含的js文件是取自上面同一链接的cornerstone.js和exampleImageIdLoader.js。
<!DOCTYPE HTML>
<html>
<head>
<link href="https://netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css" rel="stylesheet">
</head>
<body>
<div class="container">
<h1>
jsminimal/index.html
</h1>
<h3>This is an example of the minimal use of cornerstone driven by javascript</h3>
<br>
<br>
<h3>In this example, javascript is used to image enable a div.</h3>
<br>
<br>
<div id="dicomImage" style="width:512px;height:512px">
</div>
</div>
</body>
<script src="cornerstone.js"></script>
<script>window.cornerstone || document.write('<script src="https://unpkg.com/cornerstone-core@2.3.0">\x3C/script>')</script>
<script src="exampleImageIdLoader.js"></script>
<script>
const imageId = 'vhf.151.dcm';
const element = document.getElementById('dicomImage');
cornerstone.enable(element);
cornerstone.loadImage(imageId).then(function(image) {
cornerstone.displayImage(element, image);
});
</script>
</html>我面临的错误是:
错误: loadImageFromImageLoader:没有用于imageId cornerstone.js:3361:11的图像加载器
loadImageFromImageLoader文件:/cornerstone.js/cornerstone.js的绝对路径:3361
loadImage文件:/cornerstone.js的绝对路径>/cornerstone.js:3402
file:/ html文件的绝对路径/imageViewer.html:35
发布于 2020-05-30 02:37:01
尝试插入cornerstoneWADOImageLoader。
文档:https://github.com/cornerstonejs/cornerstoneWADOImageLoader
https://stackoverflow.com/questions/59018666
复制相似问题