hanayik / niivue

a WebGL2 based NIFTI volume viewer.
https://hanayik.github.io/niivue
BSD 3-Clause "New" or "Revised" License
11 stars 7 forks source link

add Niivue property for mm and vox coordinates #90

Closed hanayik closed 3 years ago

hanayik commented 3 years ago

something like:

// make new Niivue instance in UI code/component
let niivue = new Niivue()

// implement some mouse move event (.e.g. onclick)
// within the callback you could call something like this:

mm = niivue.loc.mm // [mm, mm, mm]

vox = niivue.loc.vox // [vox, vox, vox]

// then set a UI element string to show mm, or vox values to the user.