VivoQuant 6.4.0
Loading...
Searching...
No Matches
SliceViewControl Class Reference

Description

Manipulate and control the display within the slice view.

viewport_id: Uniquely identifies a viewport pane used to render a view into the data. For example: Slice View has 3 Viewport IDs where as TileView and MultiView can have many more. The ID corresponds to the position of the view in the list of views. Arguments taking a Data ID, plane or crop style accept either an enumeration value or its integer value (see Enumerations).

See also VQ.controller() to obtain this object.

Public Member Functions

void setNumber (int dims[3])
 Set ranges for the slice view axes. If the current position is invalid in the new ranges, the position will be recentered.
int getMax (VQ.Plane plane)
 Get the maximum index of a slice in a given plane of view.
int getPos (int id, VQ.Plane a)
 Get the index of the slice currently open in the view (usually shown by a crosshair.).
int getPos (VQ.Plane a)
 Get the index of the slice currently open in the view (usually shown by a crosshair.).
void setPos (VQ.Plane plane, int pos, int viewport_id)
 Set a single slice coordinate in a plane for the given Viewport ID.
void setPos (VQ.Plane plane, int pos)
 Set a single slice coordinate in a plane for the current Viewport ID (See viewport_id for details).
float getIntensity (int viewport_id, VQ.DataID data_id) const
 Get the intensity of the view.
float getIntensity (VQ.DataID data_id)
 Get the intensity of the view for the given Data ID in the current Viewport ID (See viewport_id for details).
void setIntensity (VQ.DataID data_id, float intensity, int viewport_id)
 Set intensity component for a given Data and Viewport ID.
void setIntensity (VQ.DataID data_id, float intensity)
 Set intensity component for a Data ID in the current Viewport ID (See viewport_id for details).
bool getActive (int viewport_id, VQ.DataID data_id) const
 Return whether the given data ID is active (visible) for the provided Viewport ID.
bool getActive (VQ.DataID data_id)
 Return whether the given data ID is active (visible) for the current Viewport ID (See viewport_id for details).
void setActive (VQ.DataID data_id, bool visible, int viewport_id)
 Sets the visibility of a dataset for the specified Data and Viewport ID.
void setActive (VQ.DataID data_id, bool visible)
 Sets the visibility of a dataset for the specified ID for the current Viewport ID (See viewport_id for details). If Link Views is checked, it will be applied to all.
bool getShowROIs (int viewport_id)
 Returns whether ROIs are shown for the given Viewport ID (See viewport_id for details).
bool getShowROIs ()
 Returns whether ROIs are shown for the current Viewport ID (See viewport_id for details).
void setShowROIs (bool toShow, int viewport_id)
 Show/hide ROIs for the specified Viewport ID.
bool getShowAnnotations (int viewport_id)
 Returns whether annotations are shown for the given Viewport ID.
bool getShowAnnotations ()
 Returns whether annotations are shown for the current Viewport ID (See viewport_id for details).
void setShowAnnotations (bool toShow, int id)
 Show/hide annotations for all datasets.
auto getCropStyle (int viewport_id) -> VQ.CropView
 Returns the crop style for the given Viewport ID.
auto getCropStyle () -> VQ.CropView
 Returns the crop style (VQ.CropView) for the current Viewport ID (See viewport_id for details).
void setCropStyle (VQ.CropView style, int id)
 Set the crop style for all datasets.
bool getShowFiducials (int viewport_id)
 Returns whether fiducials are shown for the given Viewport ID.
bool getShowFiducials ()
 Returns whether fiducials are shown for the current Viewport ID (See viewport_id for details).
void setShowFiducials (bool toEnable, int viewport_id)
 Sets whether fiducials should be displayed for the given Viewport ID.
void setShowFiducials (bool toEnable)
 Sets whether fiducials should be displayed for the current Viewport ID (See viewport_id for details).
bool getLinkedState ()
 Returns whether view states are linked between viewports.

Member Function Documentation

◆ getActive() [1/2]

bool getActive ( int viewport_id,
VQ.DataID data_id ) const
inline

Return whether the given data ID is active (visible) for the provided Viewport ID.

Parameters
viewport_idViewport index. See viewport_id for details.
data_idA value of VQ.DataID (e.g. VQ.DataID.Input1)
Returns
Whether the given Data and Viewport is active.

◆ getActive() [2/2]

bool getActive ( VQ.DataID data_id)
inline

Return whether the given data ID is active (visible) for the current Viewport ID (See viewport_id for details).

Parameters
data_idA value of VQ.DataID (e.g. VQ.DataID.Input1)
Returns
Whether the given Data is active in the current viewport.

◆ getCropStyle()

auto getCropStyle ( int viewport_id) -> VQ.CropView

Returns the crop style for the given Viewport ID.

Parameters
viewport_idViewport index. See viewport_id for details.
Returns
A value of #VQ.CropView (e.g. VQ.CropView.DASHED)

◆ getIntensity() [1/2]

float getIntensity ( int viewport_id,
VQ.DataID data_id ) const
inline

Get the intensity of the view.

Parameters
viewport_idViewport index. See viewport_id for details.
data_idA value of VQ.DataID (e.g. VQ.DataID.Input1)
Returns
The intensity of the view for the data specified.

◆ getIntensity() [2/2]

float getIntensity ( VQ.DataID data_id)
inline

Get the intensity of the view for the given Data ID in the current Viewport ID (See viewport_id for details).

Parameters
data_idA value of VQ.DataID (e.g. VQ.DataID.Input1)
Returns
The intensity of the view.

◆ getMax()

int getMax ( VQ.Plane plane)
inline

Get the maximum index of a slice in a given plane of view.

Parameters
planeA value of VQ.Plane (e.g. VQ.Plane.Sagittal)
Returns
The maximum slice number available for view

◆ getPos() [1/2]

int getPos ( int id,
VQ.Plane a )

Get the index of the slice currently open in the view (usually shown by a crosshair.).

Parameters
idViewport index. See viewport_id for details.
aA value of VQ.Plane (e.g. VQ.Plane.Sagittal)
Returns
The slice index of the slice currently open for the viewport in the plane specified.

◆ getPos() [2/2]

int getPos ( VQ.Plane a)
inline

Get the index of the slice currently open in the view (usually shown by a crosshair.).

Parameters
aA value of VQ.Plane (e.g. VQ.Plane.Sagittal)
Returns
The slice index of the slice currently open in the plane specified.

◆ getShowAnnotations()

bool getShowAnnotations ( int viewport_id)

Returns whether annotations are shown for the given Viewport ID.

Parameters
viewport_idViewport index. See viewport_id for details.

◆ getShowFiducials()

bool getShowFiducials ( int viewport_id)

Returns whether fiducials are shown for the given Viewport ID.

Parameters
viewport_idViewport index. See viewport_id for details.

◆ getShowROIs()

bool getShowROIs ( int viewport_id)

Returns whether ROIs are shown for the given Viewport ID (See viewport_id for details).

Parameters
viewport_idViewport index. See viewport_id for details.

◆ setActive() [1/2]

void setActive ( VQ.DataID data_id,
bool visible )
inline

Sets the visibility of a dataset for the specified ID for the current Viewport ID (See viewport_id for details). If Link Views is checked, it will be applied to all.

Parameters
data_idA value of VQ.DataID (e.g. VQ.DataID.Input1)
visibleWhether the dataset should be visible (true) or hidden (false).

◆ setActive() [2/2]

void setActive ( VQ.DataID data_id,
bool visible,
int viewport_id )
inline

Sets the visibility of a dataset for the specified Data and Viewport ID.

Parameters
data_idA value of VQ.DataID (e.g. VQ.DataID.Input1)
visibleWhether the dataset should be visible (true) or hidden (false).
viewport_idViewport index. If Link Views is checked, it will be applied to all. See viewport_id for details.

◆ setCropStyle()

void setCropStyle ( VQ.CropView style,
int id )

Set the crop style for all datasets.

Parameters
styleA value of VQ.CropView (e.g. VQ.CropView.DASHED)
idNot used

◆ setIntensity() [1/2]

void setIntensity ( VQ.DataID data_id,
float intensity )
inline

Set intensity component for a Data ID in the current Viewport ID (See viewport_id for details).

Parameters
data_idA value of VQ.DataID (e.g. VQ.DataID.Input1)
intensityNew intensity value (0..1 float)

◆ setIntensity() [2/2]

void setIntensity ( VQ.DataID data_id,
float intensity,
int viewport_id )
inline

Set intensity component for a given Data and Viewport ID.

Parameters
data_idA value of VQ.DataID (e.g. VQ.DataID.Input1)
intensityNew intensity value (0..1 float)
viewport_idViewport index. If Link Views is checked, intensity will be applied to all. See viewport_id for details.

◆ setNumber()

void setNumber ( int dims[3])

Set ranges for the slice view axes. If the current position is invalid in the new ranges, the position will be recentered.

Parameters
dimsthe number of voxels along each image dimension

◆ setPos() [1/2]

void setPos ( VQ.Plane plane,
int pos )
inline

Set a single slice coordinate in a plane for the current Viewport ID (See viewport_id for details).

Parameters
planeA value of VQ.Plane (e.g. VQ.Plane.Sagittal)
posNew slice position.

◆ setPos() [2/2]

void setPos ( VQ.Plane plane,
int pos,
int viewport_id )

Set a single slice coordinate in a plane for the given Viewport ID.

Parameters
planeA value of VQ.Plane (e.g. VQ.Plane.Sagittal)
posNew slice position.
viewport_idViewport index. If Link Views is checked, it will be applied to all. See viewport_id for details.

◆ setShowAnnotations()

void setShowAnnotations ( bool toShow,
int id )

Show/hide annotations for all datasets.

Parameters
toShowWhether the annotations should be visible (true) or hidden (false).
idNot used.

◆ setShowFiducials() [1/2]

void setShowFiducials ( bool toEnable)
inline

Sets whether fiducials should be displayed for the current Viewport ID (See viewport_id for details).

Parameters
toEnableIf true, fiducials will be shown; if false, they will be hidden.

◆ setShowFiducials() [2/2]

void setShowFiducials ( bool toEnable,
int viewport_id )

Sets whether fiducials should be displayed for the given Viewport ID.

Parameters
toEnableIf true, fiducials will be shown; if false, they will be hidden.
viewport_idViewport index. If Link Views is checked, it will be applied to all. See viewport_id for details.

◆ setShowROIs()

void setShowROIs ( bool toShow,
int viewport_id )

Show/hide ROIs for the specified Viewport ID.

Parameters
toShowWhether the ROIs should be visible (true) or hidden (false).
viewport_idViewport index. If Link Views is checked, it will be applied to all. See viewport_id for details.