Skip to content

jmannau/cs-cpu-bug

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cornerstone.js CPU Rendering Bug Reproduction

This repository contains a minimal reproduction case for a bug that occurs when using CPU rendering in Cornerstone.js 3D with the .setDisplayArea method.

Bug Description

If Cornerstone3D (latest, v4.3.x at the time of writing) is used with CPU rendering, an error is thrown when calling viewport.setDisplayArea.

See file://./src/cornerstoneUtils.js line 85 for the relevant code.

If CPU rendering is enabled, calling viewport.setDisplayArea results in the following error:

StackViewport.js:812 Uncaught TypeError: Cannot destructure property 'focalPoint' of 'cameraInterface' as it is undefined.
    at StackViewport.setCameraCPU (StackViewport.js:812:17)
    at StackViewport.setDisplayArea (Viewport.js:391:14)
    at initializeCornerstone (cornerstoneUtils.js:61:12)
    at async cs-cpu.js:5:18

Setup Instructions

  1. Clone the repository:

  2. Install dependencies:

    npm install
  3. Start the development server:

    npm run dev
  4. Open the test pages:

    • Navigate to http://localhost:5173/c3d-gpu.html for default rendering with GPU enabled
    • Navigate to http://localhost:5173/c3d-cpu.html for CPU rendering

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published