ImFusion Web SDK

EmbindModule

Properties

PropertyTypeDescription
AlgorithmList{ }List of Algorithms as returned e.g. from compatibleAlgorithms
AlgorithmStatusConstant{ Unknown: "Unknown"; Success: "Success"; Error: "Error"; InvalidInput: "InvalidInput"; IncompleteInput: "IncompleteInput"; OutOfMemoryHost: "OutOfMemoryHost"; OutOfMemoryGPU: "OutOfMemoryGPU"; UnsupportedGPU: "UnsupportedGPU"; UnknownAction: "UnknownAction"; AbortedByUser: "AbortedByUser"; }Algorithm Status
AlgorithmStatusConstant.Unknown"Unknown"Returned before compute has been called or when algorithm does not implement status interface.
AlgorithmStatusConstant.Success"Success"Computation was successful
AlgorithmStatusConstant.Error"Error"Generic catch all error status
AlgorithmStatusConstant.InvalidInput"InvalidInput"Some input arguments do not meet the requirements
AlgorithmStatusConstant.IncompleteInput"IncompleteInput"Not all required input has been set
AlgorithmStatusConstant.OutOfMemoryHost"OutOfMemoryHost"Insufficient main memory, e.g. a std::bad_alloc
AlgorithmStatusConstant.OutOfMemoryGPU"OutOfMemoryGPU"Insufficient memory on the GPU
AlgorithmStatusConstant.UnsupportedGPU"UnsupportedGPU"This should be returned when for instance the OpenGL version is not high enough or CUDA/OpenCL is not available
AlgorithmStatusConstant.UnknownAction"UnknownAction"This is returned by runAction if an action with the requested id does not exist
AlgorithmStatusConstant.AbortedByUser"AbortedByUser"User canceled execution
Algorithm{ }An Algorithm instance as returned by e.g. compatibleAlgorithms
EasingCurve{ Linear: "Linear"; InCubic: "InCubic"; OutCubic: "OutCubic"; InOutCubic: "InOutCubic"; Sinusoid: "Sinusoid"; }Easing curve for animations
EasingCurve.Linear"Linear"Constant velocity
EasingCurve.InCubic"InCubic"Cubic function accelerating from zero velocity
EasingCurve.OutCubic"OutCubic"Cubic function decelerating to zero velocity
EasingCurve.InOutCubic"InOutCubic"Cubic function accelerating from zero velocity until halfway, then decelerating to zero velocity
EasingCurve.Sinusoid"Sinusoid"Sinusoid acceleration from zero velocity until halfway, then sinusoid deceleration to zero velocity
Animation{ }An Animation as returned by MainModule#runAnimation or MainModule#runLoopedAnimation. Can be used to cancel an animation early.
AnnotationType{ Unknown: "Unknown"; LineSegment: "LineSegment"; Rectangle: "Rectangle"; Angle: "Angle"; }Enumeration of available annotation types.
AnnotationType.Unknown"Unknown"-
AnnotationType.LineSegment"LineSegment"-
AnnotationType.Rectangle"Rectangle"-
AnnotationType.Angle"Angle"-
AnnotationEvent{ CreationFinished: "CreationFinished"; CreationAborted: "CreationAborted"; Modified: "Modified"; }Enumeration of annotation lifecycle events.
AnnotationEvent.CreationFinished"CreationFinished"-
AnnotationEvent.CreationAborted"CreationAborted"-
AnnotationEvent.Modified"Modified"-
Annotation{ }An annotation.
AnnotationModel{ }Container class holding all annotations. Annotations have unique IDs and each belongs to a dataset.
Brush{ }Class that allows enabling/disabling and setting options for the Brush.
CameraMode{ Perspective: "Perspective"; Orthographic: "Orthographic"; }Intrinsic projection mode of a Camera.
CameraMode.Perspective"Perspective"Perspective projection based on principal point and focal length (FOV).
CameraMode.Orthographic"Orthographic"Orthographic projection based on principal point and frustum size.
Camera{ fromVectors: Camera; }Models the extrinsic (position/orientation) and intrinsic (projection) parameters of a camera. See VolumeView#setCamera
Camera.fromVectorsCamera-
DataKind{ UNKNOWN: "UNKNOWN"; IMAGE: "IMAGE"; VOLUME: "VOLUME"; IMAGESET: "IMAGESET"; VOLUMESET: "VOLUMESET"; IMAGESTREAM: "IMAGESTREAM"; VOLUMESTREAM: "VOLUMESTREAM"; POINTSET: "POINTSET"; SURFACE: "SURFACE"; TRACKINGSTREAM: "TRACKINGSTREAM"; TRACKINGDATA: "TRACKINGDATA"; TREE: "TREE"; TENSOR: "TENSOR"; POLYDATASTREAM: "POLYDATASTREAM"; STEREOIMAGESET: "STEREOIMAGESET"; STEREOIMAGESTREAM: "STEREOIMAGESTREAM"; VOLUMETRICMESH: "VOLUMETRICMESH"; }Kinds of data.
DataKind.UNKNOWN"UNKNOWN"Unknown or unspecified
DataKind.IMAGE"IMAGE"2D image
DataKind.VOLUME"VOLUME"3D volume
DataKind.IMAGESET"IMAGESET"Set of 2D images
DataKind.VOLUMESET"VOLUMESET"Set of 3D volumes, i.e. 3D+t or 4D data
DataKind.IMAGESTREAM"IMAGESTREAM"Stream of 2D images
DataKind.VOLUMESTREAM"VOLUMESTREAM"Stream of 3D volumes
DataKind.POINTSET"POINTSET"Set of points
DataKind.SURFACE"SURFACE"Surface / mesh data
DataKind.TRACKINGSTREAM"TRACKINGSTREAM"Stream of tracking data
DataKind.TRACKINGDATA"TRACKINGDATA"Instance of TrackingSequence class
DataKind.TREE"TREE"Instance of Tree class
DataKind.TENSOR"TENSOR"An arbitrary-dimensional array of floating point data
DataKind.POLYDATASTREAM"POLYDATASTREAM"Stream of point clouds or meshes
DataKind.STEREOIMAGESET"STEREOIMAGESET"Set of paired stereo images
DataKind.STEREOIMAGESTREAM"STEREOIMAGESTREAM"Stream of paired stereo images
DataKind.VOLUMETRICMESH"VOLUMETRICMESH"Volumetric unstructured grid / tetrahedral mesh
DataModality{ NA: "NA"; XRAY: "XRAY"; CT: "CT"; MRI: "MRI"; ULTRASOUND: "ULTRASOUND"; VIDEO: "VIDEO"; NM: "NM"; OCT: "OCT"; LABEL: "LABEL"; DISTANCE: "DISTANCE"; }Image modalities of data.
DataModality.NA"NA"Not applicable
DataModality.XRAY"XRAY"2D X-Ray based data
DataModality.CT"CT"X-Ray Computed Tomography
DataModality.MRI"MRI"Magnetic Resonance Imaging (MRI)
DataModality.ULTRASOUND"ULTRASOUND"Ultrasound image data
DataModality.VIDEO"VIDEO"Video / optical image data
DataModality.NM"NM"Nuclear Medicine (SPECT or PET)
DataModality.OCT"OCT"Optical Coherence Tomography
DataModality.LABEL"LABEL"Labeling data/label map
DataModality.DISTANCE"DISTANCE"Distance map
Data{ }A dataset held by the Web SDK.
PixelType{ Byte: "Byte"; UByte: "UByte"; Short: "Short"; UShort: "UShort"; Int: "Int"; UInt: "UInt"; Float: "Float"; Double: "Double"; HFloat: "HFloat"; }Pixel/voxel data type
PixelType.Byte"Byte"-
PixelType.UByte"UByte"-
PixelType.Short"Short"-
PixelType.UShort"UShort"-
PixelType.Int"Int"-
PixelType.UInt"UInt"-
PixelType.Float"Float"-
PixelType.Double"Double"-
PixelType.HFloat"HFloat"-
ImageDescriptorComparison{ Everything: "Everything"; IgnorePixelType: "IgnorePixelType"; IgnoreWidth: "IgnoreWidth"; IgnoreHeight: "IgnoreHeight"; IgnoreSlices: "IgnoreSlices"; IgnoreDimensions: "IgnoreDimensions"; IgnoreChannels: "IgnoreChannels"; IgnoreSpacing: "IgnoreSpacing"; IgnoreShiftScale: "IgnoreShiftScale"; }Bitflag enumeration to be used with ImageDescriptor::isApprox() to select which aspects of the descriptor should be compared.
ImageDescriptorComparison.Everything"Everything"-
ImageDescriptorComparison.IgnorePixelType"IgnorePixelType"-
ImageDescriptorComparison.IgnoreWidth"IgnoreWidth"-
ImageDescriptorComparison.IgnoreHeight"IgnoreHeight"-
ImageDescriptorComparison.IgnoreSlices"IgnoreSlices"-
ImageDescriptorComparison.IgnoreDimensions"IgnoreDimensions"-
ImageDescriptorComparison.IgnoreChannels"IgnoreChannels"-
ImageDescriptorComparison.IgnoreSpacing"IgnoreSpacing"-
ImageDescriptorComparison.IgnoreShiftScale"IgnoreShiftScale"-
ImageDescriptor{ (): ImageDescriptor; (pixelType: PixelType, width: number, height: number, slices: number, channels: number): ImageDescriptor; (pixelType: PixelType, dimensions: vec3i, channels: number): ImageDescriptor; }Struct describing the essential properties of an image. The ImFusion framework distinguishes two main image pixel value domains, which are indicated by the shift and scale parameters of this image descriptor. - Original pixel value domain: Pixel values are the same as in their original source (e.g. when loaded from a file). Same as the storage pixel value domain if the image's scale is 1 and the shift is 0 - Storage pixel value domain: Pixel values as they are stored in a MemImage. The user may decide to apply such a rescaling in order to better use the available limits of the underlying type. The following conversion rules apply: OV = (SV / scale) - shift SV = (OV + shift) * scale
ImageDescriptorWorldComparison{ Everything: "Everything"; IgnorePixelType: "IgnorePixelType"; IgnoreWidth: "IgnoreWidth"; IgnoreHeight: "IgnoreHeight"; IgnoreSlices: "IgnoreSlices"; IgnoreDimensions: "IgnoreDimensions"; IgnoreChannels: "IgnoreChannels"; IgnoreSpacing: "IgnoreSpacing"; IgnoreShiftScale: "IgnoreShiftScale"; IgnoreMatrix: "IgnoreMatrix"; }Bitflag enumeration to be used with isApprox() to select which aspects of the descriptor should be compared.
ImageDescriptorWorldComparison.Everything"Everything"-
ImageDescriptorWorldComparison.IgnorePixelType"IgnorePixelType"-
ImageDescriptorWorldComparison.IgnoreWidth"IgnoreWidth"-
ImageDescriptorWorldComparison.IgnoreHeight"IgnoreHeight"-
ImageDescriptorWorldComparison.IgnoreSlices"IgnoreSlices"-
ImageDescriptorWorldComparison.IgnoreDimensions"IgnoreDimensions"-
ImageDescriptorWorldComparison.IgnoreChannels"IgnoreChannels"-
ImageDescriptorWorldComparison.IgnoreSpacing"IgnoreSpacing"-
ImageDescriptorWorldComparison.IgnoreShiftScale"IgnoreShiftScale"-
ImageDescriptorWorldComparison.IgnoreMatrix"IgnoreMatrix"-
ImageDescriptorWorld{ (): ImageDescriptorWorld; (sharedImage: Image): ImageDescriptorWorld; (desc: ImageDescriptor, matrixToWorld: mat4): ImageDescriptorWorld; }Convenience struct extending an ImageDescriptor to also include a matrix describing the image orientation in world coordinates. This struct can be useful for describing the geometrical properties of an image without need to hold the (heavy) image content.
ImageInfoPatientSex{ Unknown: "Unknown"; Male: "Male"; Female: "Female"; Other: "Other"; }Gender of the patient
ImageInfoPatientSex.Unknown"Unknown"-
ImageInfoPatientSex.Male"Male"-
ImageInfoPatientSex.Female"Female"-
ImageInfoPatientSex.Other"Other"-
ImageInfoLaterality{ Unknown: "Unknown"; Left: "Left"; Right: "Right"; }Laterality of (paired) body part examined
ImageInfoLaterality.Unknown"Unknown"-
ImageInfoLaterality.Left"Left"-
ImageInfoLaterality.Right"Right"-
ImageInfoAnatomicalOrientationType{ Unknown: "Unknown"; Biped: "Biped"; Quadruped: "Quadruped"; }DICOM Anatomical Orientation Type
ImageInfoAnatomicalOrientationType.Unknown"Unknown"-
ImageInfoAnatomicalOrientationType.Biped"Biped"-
ImageInfoAnatomicalOrientationType.Quadruped"Quadruped"-
ImageInfo{ }DataComponent storing general information on the image origin. Modeled after the DICOM patient-study-series hierarchy, it stores information on the patient, study and series the data set belongs to.
Image{ fromTypedArray: Image | null; }Image shared on multiple devices
Image.fromTypedArrayImage | null-
SharedImageSet() => SharedImageSetSet of images independent of their storage location. This class is the main high-level container for image data consisting of one or multiple images or volumes.
SharedImageSetList() => SharedImageSetList-
FileFormat{ nifti: "nifti"; png: "png"; imf: "imf"; dicom: "dicom"; zip: "zip"; graphml: "graphml"; obj: "obj"; ply: "ply"; stl: "stl"; off: "off"; }Supported file formats.
FileFormat.nifti"nifti"NIfTI image, optionally gzip-compressed.
FileFormat.png"png"PNG image.
FileFormat.imf"imf"ImFusion data container.
FileFormat.dicom"dicom"DICOM.
FileFormat.zip"zip"ZIP archive.
FileFormat.graphml"graphml"GraphML graph.
FileFormat.obj"obj"Wavefront OBJ surface mesh.
FileFormat.ply"ply"PLY polygon mesh.
FileFormat.stl"stl"STL triangle mesh.
FileFormat.off"off"OFF or COFF polygon mesh.
DataModel{ }Observable collection of datasets with unique names.
IntegerList() => IntegerListWrapper for a C++ vector of integers.
LabelConfigMap() => LabelConfigMapWrapper for a C++ map of number to [LabelConfig]LabelConfig.
View{ }A single rendering view (e.g. single anatomical plane) that is hosted inside a Display.
RenderMode{ DRR: "DRR"; MIP: "MIP"; IsoSurface: "IsoSurface"; UnshadedDVR: "UnshadedDVR"; PhongDVR: "PhongDVR"; GlobalIllumDVR: "GlobalIllumDVR"; Unknown: "Unknown"; }Enumeration of built-in render modes for the VolumeView.
RenderMode.DRR"DRR"Digitally reconstructed radiograph.
RenderMode.MIP"MIP"Maximum intensity projection.
RenderMode.IsoSurface"IsoSurface"Iso-surface rendering.
RenderMode.UnshadedDVR"UnshadedDVR"Direct Volume Rendering without any shading.
RenderMode.PhongDVR"PhongDVR"Direct Volume Rendering with local Phong shading.
RenderMode.GlobalIllumDVR"GlobalIllumDVR"Direct Volume Rendering with global illumination shading.
RenderMode.Unknown"Unknown"Unknown render mode (e.g. a custom renderer).
VolumeViewResetOption{ Everything: "Everything"; Camera: "Camera"; ClipPlane: "ClipPlane"; }Options for VolumeView.reset.
VolumeViewResetOption.Everything"Everything"-
VolumeViewResetOption.Camera"Camera"-
VolumeViewResetOption.ClipPlane"ClipPlane"-
SliceBlendingMode{ Default: "Default"; Color: "Color"; Checkerboard: "Checkerboard"; DistanceToBorder: "DistanceToBorder"; }Enumeration of the blending modes available for rendering multiple images.
SliceBlendingMode.Default"Default"Default alpha blending
SliceBlendingMode.Color"Color"Automatic color blending depending on modality (either SingleColor or DualColor blending mode)
SliceBlendingMode.Checkerboard"Checkerboard"Checkerboard blending
SliceBlendingMode.DistanceToBorder"DistanceToBorder"Per-pixel blending based on distance to image border
SliceInterpolationMode{ NearestNeighbor: "NearestNeighbor"; LinearInterpolation: "LinearInterpolation"; CubicInterpolation: "CubicInterpolation"; }Interpolation mode during rendering
SliceInterpolationMode.NearestNeighbor"NearestNeighbor"Nearest neighbor interpolation
SliceInterpolationMode.LinearInterpolation"LinearInterpolation"Linear interpolation
SliceInterpolationMode.CubicInterpolation"CubicInterpolation"Cubic interpolation
SliceView{ }A 2D MPR View.
VolumeView{ }A Volumetric 3D View.
ViewList() => ViewListWrapper of a C++ array of Views.
DisplayOptions2d{ }Configures the display options for 2D slice rendering of images. Window/level parameters are defined in original pixel value domain (e.g. Hounsfield Units). Conversion of pixel values to display intensities is performed using the LINEAR_EXACT VOI LUT function as described in section C.11.2.1.3.2 of the DICOM standard. See http://dicom.nema.org/medical/dicom/current/output/chtml/part03/sect_C.11.2.html#sect_C.11.2.1.3
DisplayOptions3d{ }Configures the display options for 3D volume rendering of images. Window/level parameters are defined in original pixel value domain (e.g. Hounsfield Units). Conversion of pixel values to display intensities is performed using the LINEAR_EXACT VOI LUT function as described in section C.11.2.1.3.2 of the DICOM standard. See http://dicom.nema.org/medical/dicom/current/output/chtml/part03/sect_C.11.2.html#sect_C.11.2.1.3
DisplayLayoutMode{ Auto: "Auto"; Rows: "Rows"; FocusPlusStack: "FocusPlusStack"; FocusPlusRows: "FocusPlusRows"; }Enumeration of available layouting modes for DisplayAutoLayouter#setLayoutMode.
DisplayLayoutMode.Auto"Auto"Automatically chooses one between Rows or FocusPlusStack mode based on the visible views.
DisplayLayoutMode.Rows"Rows"Arranges all views in a grid-like fashion with up to 2 rows.
DisplayLayoutMode.FocusPlusStack"FocusPlusStack"Shows a large focus view and vertically stacks all other views to the right.
DisplayLayoutMode.FocusPlusRows"FocusPlusRows"Shows a large focus view and uses the Rows layout on the right for the other views.
DisplayAutoLayouter{ }This class facilitates the layouting of Views inside a Display by encapsulating logic to generate layouts for dynamic view configurations based on a customizable set of layouting algorithms.
RadiologyViewGroup{ }Class representing a set of views typically available in radiology workstations.
OverlayType{ NoOverlays: "NoOverlays"; FullscreenButton: "FullscreenButton"; ViewOrderButton: "ViewOrderButton"; DataSelectionButton: "DataSelectionButton"; PatientInfo: "PatientInfo"; HorizontalScale: "HorizontalScale"; VerticalScale: "VerticalScale"; OrientationMesh: "OrientationMesh"; Histogram: "Histogram"; PixelInfo: "PixelInfo"; FpsCounter: "FpsCounter"; OffscreenIndicator: "OffscreenIndicator"; AllOverlays: "AllOverlays"; }Enumeration to select default overlays to add to a view.
OverlayType.NoOverlays"NoOverlays"No overlays are shown.
OverlayType.FullscreenButton"FullscreenButton"Button to maximize/minimize the view; requires DisplayAutoLayouter.
OverlayType.ViewOrderButton"ViewOrderButton"Button to move the view to a different position in the view layout; requires DisplayAutoLayouter.
OverlayType.DataSelectionButton"DataSelectionButton"Button to select the visible data from the DataModel.
OverlayType.PatientInfo"PatientInfo"Text overlay showing patient information.
OverlayType.HorizontalScale"HorizontalScale"Horizontal ruler overlay showing the image scale; only applicable to SliceViews.
OverlayType.VerticalScale"VerticalScale"Vertical ruler overlay showing the image scale; only applicable to SliceViews.
OverlayType.OrientationMesh"OrientationMesh"Overlay showing the orientation of the shown data (e.g. in form of a cube).
OverlayType.Histogram"Histogram"Shows the intensity distribution of the shown image as histogram; only applicable to SliceViews.
OverlayType.PixelInfo"PixelInfo"Shows image pixel information underneath the mouse pointer; only applicable to SliceViews.
OverlayType.FpsCounter"FpsCounter"Shows an estimate of the frames per second of the renderer.
OverlayType.OffscreenIndicator"OffscreenIndicator"Dynamic overlay showing data that is outside of the current view area; only applicable to SliceViews.
OverlayType.AllOverlays"AllOverlays"Enables all overlays.
OrientationMeshType{ Cube: "Cube"; Head: "Head"; Body: "Body"; CubeQuadruped: "CubeQuadruped"; }Enumeration of available meshes to show in the OrientationOverlay
OrientationMeshType.Cube"Cube"Shows a cube where the faces have the letters A/P/L/R/F/H
OrientationMeshType.Head"Head"Shows a depiction of a human head
OrientationMeshType.Body"Body"Shows a depiction of a human body
OrientationMeshType.CubeQuadruped"CubeQuadruped"Shows a cube where the faces have the letters D/V/LE/RT/RC/CD
RadiologyViewOverlays{ }Helper class to create and manage ViewOverlays commonly shown in radiology workstations.
Display{ }Class representing the main render area.
StringList() => StringList-
GraphDimension{ Dimension2D: "Dimension2D"; Dimension3D: "Dimension3D"; }Spatial dimensionality of a Graph.
GraphDimension.Dimension2D"Dimension2D"The graph is planar and is only shown in 2D views.
GraphDimension.Dimension3D"Dimension3D"The graph is three-dimensional and is only shown in 3D views.
GraphType{ Directed: "Directed"; Undirected: "Undirected"; }The type of a Graph.
GraphType.Directed"Directed"-
GraphType.Undirected"Undirected"-
Graph(options: { type?: GraphType; dimension?: GraphDimension; }) => GraphData representing a (potentially directed) graph. A graph is guaranteed to have several invariants enforced: - In undirected graphs, for each edge (i, j), there is the edge (j, i) in the graph. - Each node has a fixed number of features (see GraphNode.features). - Each edge has a fixed number of features (see GraphEdge.features). These invariants ensure that: - Deleting a node is O(log(N)) (assuming some fixed number of edges per node). - Features can be accessed by index, and are guaranteed to exist. Self-loops are allowed.
GraphDisplayOptions{ }GraphDisplayOptions provides an object for configuring the rendering of the corresponding Graph in the different views.
AlignedBox{ (): AlignedBox; (point: vec3): AlignedBox; (lowerLeftFront: vec3, upperRightBack: vec3): AlignedBox; }Class representing an axis aligned rectangular cuboid in 3D space. The coordinate convention for this class is bottom <= top, left <= right, front <= back, all of which are enforced in the constructor. A default-constructed AlignedBox is considered "invalid" and represented by both lowerLeftFront() and upperRightBack() being NaN. Use isValid() to easily check for this.
GlViewState{ }Encapsulates the OpenGL view state defined by the viewport, a projection matrix and a model-view matrix.
GlObject{ implement: CustomGlObject; extend: any; }Abstract base class for a renderable OpenGL object that can be hosted in a GlView.
GlObject.implementCustomGlObject-
GlObject.extendany-
CustomGlObject{ }-
MenuItemList() => MenuItemListWrapper of a C++ array of MenuItems.
Menu() => MenuRepresents a hierarchical menu of actions used to describe menu bars, context menus, or popup menus. A menu is formed by a list of items, where each item is either a clickable action (MenuItem#isAction), a divider separating groups (MenuItem#isSeparator) of related actions, or a recursive submenu of the same form (MenuItem#isSubmenu).
MenuItem{ }A menu item is either an action, a separator, or a recursive submenu.
MenuAction{ }Represents an item inside a Menu where a callback function is called when user clicks on it. Besides the default appearance it can also be of checkable type where an underlying boolean state is toggled through the action (usually indicated by a checkmark icon), or of radio type where multiple actions comprise an enumeration of possible values of which only one can be selected (usually indicated by a radio button icon). By convention, a group of exclusive options is formed by the set of adjacent actions of this type where there is no Separator in-between.
MenuSeparator{ }-
MeshVertexNormalWeighting{ Uniform: "Uniform"; Angle: "Angle"; Area: "Area"; NelsonMax: "NelsonMax"; }Weighting schemes for averaging normals of faces around a vertex to obtain vertex normals
MeshVertexNormalWeighting.Uniform"Uniform"Face normals are weighted uniformly (no actual weighting is applied)
MeshVertexNormalWeighting.Angle"Angle"Face normals are weighted by the triangle's interior angle at the vertex
MeshVertexNormalWeighting.Area"Area"Face normals are weighted by the triangle's area
MeshVertexNormalWeighting.NelsonMax"NelsonMax"Face normals are weighted as proposed by Nelson Max in "Weights for Computing Vertex Normals from Facet Normals", Journal of Graphics Tools, 4(2) (1999) by the sine of the angle between the two edges sharing the vertex divided by the product of the lengths of the two edges
Mesh{ create: Mesh; }Subclass of Data that represents a surface mesh.
Mesh.createMesh-
MeshDisplayOptions{ }MeshDisplayOptions provides an object for configuring the rendering/appearance of the corresponding Mesh in the different views.
ExamplePropertiesUI{ }-
TransferFunctionMode{ Keypoint: "Keypoint"; LUT: "LUT"; }Representation used by a TransferFunction.
TransferFunctionMode.Keypoint"Keypoint"-
TransferFunctionMode.LUT"LUT"-
TransferFunction{ }1D transfer function for classification during rendering. A 1D transfer function describes a mapping from image intensities to the optical properties of color and opacity. In this implementation, the transfer function is either described by a set of tissues - each consisting of a set of key points - or a look-up-table (LUT). Both image intensities and colors are defined in normalized [0..1] space. The windowing is defined in original pixel value domain (e.g. Hounsfield units).

Methods

MethodDescription
installAnimationBackend()Install Emscripten Animation Backend as the global backend (installed by default).
enableAnimations()Globally enable/disable animations
annotationModel()Returns the global annotation model instance.
brush()Returns a struct containing the brush and painter objects.
compatibleAlgorithms()Return a list of Algorithms compatible with the given Data array.
runAnimation()Run an animation with the specified duration and easing curve
runLoopedAnimation()Run a looped animation with the specified duration and easing curve
getLabelConfigs()Returns the known label configurations for the given label map.
setLabelConfigs()Sets the label configurations for the given label map.
setDefaultLabelConfig()Sets the default label configuration for the given pixel value.
removeLabelConfig()Removes the label configuration for the given pixel value.
dataModel()Returns the global data model instance.
getImage()Returns the first SharedImageSet matching the given kind and modality from the given data array.
getImages()Returns all SharedImageSets matching the given kind and modality from the given data array.
longPressDetectionConfig()
display()Returns the global display instance.
save()Saves the data to an ImFusionFile buffer
getLabelConfig()Returns the label configuration for the given pixel value if it exists.
setLabelConfig()Sets the label configuration for the given pixel value.
init()Initializes the ImFusion Web SDK.
createExamplePropertiesUI()
setDpiScale()Sets the global DPI scaling factor that should be used by DPI-sensitive OpenGL renderings.
dpiScale()Returns the global DPI scaling factor that is used by DPI-sensitive OpenGL rendering.

installAnimationBackend()

ts
installAnimationBackend(): void;

Install Emscripten Animation Backend as the global backend (installed by default).

Returns

void


enableAnimations()

ts
enableAnimations(enabled: boolean): void;

Globally enable/disable animations

Parameters

ParameterType
enabledboolean

Returns

void


annotationModel()

ts
annotationModel(): AnnotationModel;

Returns the global annotation model instance.

Returns

AnnotationModel


brush()

ts
brush(): Brush;

Returns a struct containing the brush and painter objects.

Returns

Brush


compatibleAlgorithms()

ts
compatibleAlgorithms(selectedData: Data[]): AlgorithmList;

Return a list of Algorithms compatible with the given Data array.

Parameters

ParameterTypeDescription
selectedDataData[]Only algorithms compatible with this Data array are returned.

Returns

AlgorithmList

The list of compatible Algorithms


runAnimation()

ts
runAnimation(
   updateFunction: (t: number) => void,
   durationInMS?: number,
   easingCurve?: EasingCurve,
   stringId?: EmbindString): Animation;

Run an animation with the specified duration and easing curve

Parameters

ParameterTypeDescription
updateFunction(t: number) => voidCallback that will receive interpolated t values in the range [0.0,1.0]. Use the t value to drive your animation.
durationInMS?numberDuration in milliseconds of the animation
easingCurve?EasingCurveEasing curve that is used for the animation
stringId?EmbindStringString identifier of sufficient uniqueness that is used when dispatching a new annotation to prevent multiple concurrent animations with the same ID

Returns

Animation


runLoopedAnimation()

ts
runLoopedAnimation(
   updateFunction: (t: number) => void,
   durationInMS?: number,
   easingCurve?: EasingCurve,
   stringId?: EmbindString): Animation;

Run a looped animation with the specified duration and easing curve

Parameters

ParameterTypeDescription
updateFunction(t: number) => voidCallback that will receive interpolated t values in the range [0.0,1.0] (repeating after each loop iteration). Use the t value to drive your animation.
durationInMS?numberDuration in milliseconds of the animation
easingCurve?EasingCurveEasing curve that is used for the animation
stringId?EmbindStringString identifier of sufficient uniqueness that is used when dispatching a new annotation to prevent multiple concurrent animations with the same ID

Returns

Animation


getLabelConfigs()

ts
getLabelConfigs(labelMap: SharedImageSet | null): LabelConfigMap;

Returns the known label configurations for the given label map.

Parameters

ParameterTypeDescription
labelMapSharedImageSet | nullMust have modality DataModality "LABEL".

Returns

LabelConfigMap

Map of label value to LabelConfig.


setLabelConfigs()

ts
setLabelConfigs(labelMap: SharedImageSet | null, configs: LabelConfigMap): void;

Sets the label configurations for the given label map.

Parameters

ParameterTypeDescription
labelMapSharedImageSet | nullMust have modality DataModality "LABEL".
configsLabelConfigMapMap of label value to [LabelConfig]LabelConfig.

Returns

void


setDefaultLabelConfig()

ts
setDefaultLabelConfig(labelMap: SharedImageSet | null, pixelValue: number): void;

Sets the default label configuration for the given pixel value.

Parameters

ParameterTypeDescription
labelMapSharedImageSet | nullMust have modality DataModality "LABEL".
pixelValuenumberThe pixel value to set the default label configuration for.

Returns

void


removeLabelConfig()

ts
removeLabelConfig(labelMap: SharedImageSet | null, pixelValue: number): void;

Removes the label configuration for the given pixel value.

Parameters

ParameterTypeDescription
labelMapSharedImageSet | nullMust have modality DataModality "LABEL".
pixelValuenumberThe pixel value to remove the label configuration for.

Returns

void


dataModel()

ts
dataModel(): DataModel;

Returns the global data model instance.

Returns

DataModel


getImage()

ts
getImage(
   data: Data[],
   kind?: DataKind,
   modality?: DataModality): SharedImageSet | null;

Returns the first SharedImageSet matching the given kind and modality from the given data array. DataKind "UNKNOWN" matches all kinds and DataModality "NA" matches all modalities.

Parameters

ParameterTypeDescription
dataData[]Array of datasets to search.
kind?DataKind-
modality?DataModality-

Returns

SharedImageSet | null


getImages()

ts
getImages(
   data: Data[],
   kind?: DataKind,
modality?: DataModality): HandleArray<SharedImageSet>;

Returns all SharedImageSets matching the given kind and modality from the given data array. DataKind "UNKNOWN" matches all kinds and DataModality "NA" matches all modalities.

Parameters

ParameterTypeDescription
dataData[]Array of datasets to search.
kind?DataKind-
modality?DataModality-

Returns

HandleArray<SharedImageSet>


longPressDetectionConfig()

ts
longPressDetectionConfig(): LongPressDetectionConfig;

Returns

LongPressDetectionConfig


display()

ts
display(): Display;

Returns the global display instance.

Returns

Display


save()

ts
save(data: Data[]): Uint8Array;

Saves the data to an ImFusionFile buffer

Parameters

ParameterType
dataData[]

Returns

Uint8Array

JS-owned ImFusionFile buffer


getLabelConfig()

ts
getLabelConfig(labelMap: SharedImageSet | null, pixelValue: number): LabelConfig | undefined;

Returns the label configuration for the given pixel value if it exists.

Parameters

ParameterTypeDescription
labelMapSharedImageSet | nullMust have modality DataModality "LABEL".
pixelValuenumberThe pixel value to get the label configuration for.

Returns

LabelConfig | undefined


setLabelConfig()

ts
setLabelConfig(
   labelMap: SharedImageSet | null,
   pixelValue: number,
   config: LabelConfig): void;

Sets the label configuration for the given pixel value.

Parameters

ParameterTypeDescription
labelMapSharedImageSet | nullMust have modality DataModality "LABEL".
pixelValuenumberThe pixel value to set the label configuration for.
configLabelConfigThe label configuration to set.

Returns

void


init()

ts
init(licenseToken?: EmbindString): void;

Initializes the ImFusion Web SDK. Must be called at the very beginning.

Parameters

ParameterTypeDescription
licenseToken?EmbindStringOptional license token.

Returns

void


createExamplePropertiesUI()

ts
createExamplePropertiesUI(): ExamplePropertiesUI;

Returns

ExamplePropertiesUI


setDpiScale()

ts
setDpiScale(dpiScale: number): void;

Sets the global DPI scaling factor that should be used by DPI-sensitive OpenGL renderings. This scaling factor is usually the product of a user defined scaling and the pixel ratio of the underlying device (e.g. retina displays).

Parameters

ParameterType
dpiScalenumber

Returns

void


dpiScale()

ts
dpiScale(): number;

Returns the global DPI scaling factor that is used by DPI-sensitive OpenGL rendering.

Returns

number

On this page