Skip to content

Interface: SingleSliceViewerOptions ​

Defined in: src/display/SingleSliceViewer.ts:64

Options for creating a SingleSliceViewer

Properties ​

width? ​

ts
optional width?: number;

Defined in: src/display/SingleSliceViewer.ts:68

Width of the viewer in pixels


height? ​

ts
optional height?: number;

Defined in: src/display/SingleSliceViewer.ts:73

Height of the viewer in pixels


showCrosshair? ​

ts
optional showCrosshair?: boolean;

Defined in: src/display/SingleSliceViewer.ts:78

Show crosshair overlay


showSlider? ​

ts
optional showSlider?: boolean;

Defined in: src/display/SingleSliceViewer.ts:83

Show slice navigation slider


initialCoord? ​

ts
optional initialCoord?: number[];

Defined in: src/display/SingleSliceViewer.ts:88

Initial coordinate to display (world coordinates in mm)


showIntensityReadout? ​

ts
optional showIntensityReadout?: boolean;

Defined in: src/display/SingleSliceViewer.ts:98

Add an intensity-readout layer to the view.

Known issue: nothing currently feeds the layer pointer positions, so the readout stays blank. Build a readout from SingleSliceViewer.onPointerMove instead (the Composable Views guide describes its coordinate fields).

Default ​

ts
false

showOrientationLabels? ​

ts
optional showOrientationLabels?: boolean;

Defined in: src/display/SingleSliceViewer.ts:104

Show orientation labels (L/R/A/P/S/I) at slice edges

Default ​

ts
false

orientationLabelOptions? ​

ts
optional orientationLabelOptions?: OrientationLabelOptions;

Defined in: src/display/SingleSliceViewer.ts:110

Styling for the orientation labels (font size, color, margin, outline). Only used when showOrientationLabels is true.


enableDepthEnhancement? ​

ts
optional enableDepthEnhancement?: boolean;

Defined in: src/display/SingleSliceViewer.ts:118

Enable depth-enhanced viewing with blur and parallax effects. When true, adjacent slices are rendered with blur and shift based on cursor position to provide depth cues.

Default ​

ts
false

depthEnhancementOptions? ​

ts
optional depthEnhancementOptions?: DepthEnhancedOptions;

Defined in: src/display/SingleSliceViewer.ts:123

Options for depth-enhanced viewing (only used if enableDepthEnhancement is true)

Released under the MIT License.