Skip to content

Minimal (WebGL2 only)

Minimal Voxels (WebGL2 only)

examples/vox.min.webgl2.htmlOpen full pageSource

Code

vox.min.webgl2.js
import NiiVue from '@niivue/niivue/webgl2'
const gl1 = document.getElementById('gl1')
const nv1 = new NiiVue()
await nv1.attachToCanvas(gl1)
await nv1.loadVolumes([{ url: '/volumes/mni152.nii.gz' }])