Skip to content

shapeworks::Visualizer

Controls display of objects in viewers. More...

#include <Visualizer.h>

Inherits from QObject

Public Slots

Name
void update_viewer_properties()
update viewer properties (e.g. glyph size, quality, etc)
void handle_feature_range_changed()
void handle_image_slice_settings_changed()

Public Functions

Name
Visualizer(Preferences & prefs)
~Visualizer()
void set_lightbox(LightboxHandle lightbox)
set the lightbox
void set_session(SessionHandle session)
set the session
void set_center(bool center)
turn automatic centering on/off
bool get_center()
get centering on/off
void set_alignment_domain(int domain)
set the alignment domain
int get_alignment_domain()
get the current alignment domain
void set_show_glyphs(bool show)
turn on/off glyph display
void set_show_surface(bool show)
turn on/off surface display
void display_samples()
update the display using the current settings
void update_samples()
void update_landmarks()
void update_planes()
void update_paint_mode()
void handle_fill_all_ffc()
void display_sample(int i)
void display_shape(ShapeHandle shape)
void display_shapes(ShapeList shapes)
void set_selected_point_one(int id)
void set_selected_point_two(int id)
void set_mean(const Eigen::VectorXd & mean)
void set_mean_shape(ShapeHandle mean_shape)
ShapeHandle get_mean_shape()
void reset_camera()
void update_lut()
void update_annotations()
Particles get_current_shape()
vtkFloatArray * get_current_particle_scalars()
vtkSmartPointer< vtkPolyData > get_current_particle_poly_data()
void handle_new_mesh()
vtkSmartPointer< vtkPolyData > get_current_mesh(int index, bool clip_constraints)
std::vector< vtkSmartPointer< vtkPolyData > > get_current_meshes_transformed(int index, bool clip_constraints =false)
const std::string & get_feature_map() const
Get the currently selected feature map.
void set_uniform_feature_range(bool value)
Set if we are using a uniform feature range.
bool get_uniform_feature_range(void )
Return if we are using a uniform feature range.
void set_feature_map(const std::string & feature_map)
Set the currently selected feature map.
void clear_viewers()
clear out the viewers
void reset_feature_range()
Reset the feature range (e.g. for a new feature)
double * get_feature_range()
Get the current feature range.
double * get_feature_raw_range()
Get the current raw feature range.
bool get_feature_range_valid()
Return if the feature range is valid or not.
void update_feature_range(double * range)
Update the feature range with a given range.
void update_feature_range(double min, double max)
Update the feature range with a given range.
vtkSmartPointer< vtkTransform > get_transform(std::shared_ptr< Shape > shape, int alignment_domain, int domain)
Request the transform for a given shape and domain.
vtkSmartPointer< vtkTransform > get_transform(std::shared_ptr< Shape > shape, DisplayMode display_mode, int alignment_domain, int domain)
Request the transform for a given shape and domain and display mode.
void set_opacities(std::vector< float > opacities)
Set domain opacities.
std::vector< float > get_opacities()
Get domain opacities.
void set_domain_particle_visibilities(std::vector< bool > visibilities)
Set the per-domain particle visibilities.
std::vector< bool > get_domain_particle_visibilities()
Get the per-domain particle visibilities.
double get_current_glyph_size()
Get the current glyph size.
void handle_ctrl_click(PickResult result)
Handle ctrl click.
void redraw()
Redraw renderers.
QPixmap export_to_pixmap(QSize size, bool transparent_background, bool show_orientation_marker, bool show_color_scale, bool & ready)
Export render window to pixmap.
QSize get_render_size()
Return render window size.
LightboxHandle get_lightbox()

Detailed Description

cpp class shapeworks::Visualizer;

Controls display of objects in viewers.

The Visualizer class maintains state and control over viewer properties. Additionally, it performs all shape-based statistical functions.

Public Slots Documentation

slot update_viewer_properties

cpp void update_viewer_properties()

update viewer properties (e.g. glyph size, quality, etc)

slot handle_feature_range_changed

cpp void handle_feature_range_changed()

slot handle_image_slice_settings_changed

cpp void handle_image_slice_settings_changed()

Public Functions Documentation

function Visualizer

cpp Visualizer( Preferences & prefs )

function ~Visualizer

cpp ~Visualizer()

function set_lightbox

cpp void set_lightbox( LightboxHandle lightbox )

set the lightbox

function set_session

cpp void set_session( SessionHandle session )

set the session

function set_center

cpp void set_center( bool center )

turn automatic centering on/off

function get_center

cpp bool get_center()

get centering on/off

function set_alignment_domain

cpp void set_alignment_domain( int domain )

set the alignment domain

function get_alignment_domain

cpp int get_alignment_domain()

get the current alignment domain

function set_show_glyphs

cpp void set_show_glyphs( bool show )

turn on/off glyph display

function set_show_surface

cpp void set_show_surface( bool show )

turn on/off surface display

function display_samples

cpp void display_samples()

update the display using the current settings

function update_samples

cpp void update_samples()

function update_landmarks

cpp void update_landmarks()

function update_planes

cpp void update_planes()

function update_paint_mode

cpp void update_paint_mode()

function handle_fill_all_ffc

cpp void handle_fill_all_ffc()

function display_sample

cpp void display_sample( int i )

function display_shape

cpp void display_shape( ShapeHandle shape )

function display_shapes

cpp void display_shapes( ShapeList shapes )

function set_selected_point_one

cpp void set_selected_point_one( int id )

function set_selected_point_two

cpp void set_selected_point_two( int id )

function set_mean

cpp void set_mean( const Eigen::VectorXd & mean )

function set_mean_shape

cpp void set_mean_shape( ShapeHandle mean_shape )

function get_mean_shape

cpp ShapeHandle get_mean_shape()

function reset_camera

cpp void reset_camera()

function update_lut

cpp void update_lut()

function update_annotations

cpp void update_annotations()

function get_current_shape

cpp Particles get_current_shape()

function get_current_particle_scalars

cpp vtkFloatArray * get_current_particle_scalars()

function get_current_particle_poly_data

cpp vtkSmartPointer< vtkPolyData > get_current_particle_poly_data()

function handle_new_mesh

cpp void handle_new_mesh()

function get_current_mesh

cpp vtkSmartPointer< vtkPolyData > get_current_mesh( int index, bool clip_constraints )

function get_current_meshes_transformed

cpp std::vector< vtkSmartPointer< vtkPolyData > > get_current_meshes_transformed( int index, bool clip_constraints =false )

function get_feature_map

cpp const std::string & get_feature_map() const

Get the currently selected feature map.

function set_uniform_feature_range

cpp void set_uniform_feature_range( bool value )

Set if we are using a uniform feature range.

function get_uniform_feature_range

cpp bool get_uniform_feature_range( void )

Return if we are using a uniform feature range.

function set_feature_map

cpp void set_feature_map( const std::string & feature_map )

Set the currently selected feature map.

function clear_viewers

cpp void clear_viewers()

clear out the viewers

function reset_feature_range

cpp void reset_feature_range()

Reset the feature range (e.g. for a new feature)

function get_feature_range

cpp double * get_feature_range()

Get the current feature range.

function get_feature_raw_range

cpp double * get_feature_raw_range()

Get the current raw feature range.

function get_feature_range_valid

cpp bool get_feature_range_valid()

Return if the feature range is valid or not.

function update_feature_range

cpp void update_feature_range( double * range )

Update the feature range with a given range.

function update_feature_range

cpp void update_feature_range( double min, double max )

Update the feature range with a given range.

function get_transform

cpp vtkSmartPointer< vtkTransform > get_transform( std::shared_ptr< Shape > shape, int alignment_domain, int domain )

Request the transform for a given shape and domain.

function get_transform

cpp vtkSmartPointer< vtkTransform > get_transform( std::shared_ptr< Shape > shape, DisplayMode display_mode, int alignment_domain, int domain )

Request the transform for a given shape and domain and display mode.

function set_opacities

cpp void set_opacities( std::vector< float > opacities )

Set domain opacities.

function get_opacities

cpp std::vector< float > get_opacities()

Get domain opacities.

function set_domain_particle_visibilities

cpp void set_domain_particle_visibilities( std::vector< bool > visibilities )

Set the per-domain particle visibilities.

function get_domain_particle_visibilities

cpp std::vector< bool > get_domain_particle_visibilities()

Get the per-domain particle visibilities.

function get_current_glyph_size

cpp double get_current_glyph_size()

Get the current glyph size.

function handle_ctrl_click

cpp void handle_ctrl_click( PickResult result )

Handle ctrl click.

function redraw

cpp void redraw()

Redraw renderers.

function export_to_pixmap

cpp QPixmap export_to_pixmap( QSize size, bool transparent_background, bool show_orientation_marker, bool show_color_scale, bool & ready )

Export render window to pixmap.

function get_render_size

cpp QSize get_render_size()

Return render window size.

function get_lightbox

cpp inline LightboxHandle get_lightbox()


Updated on 2026-03-31 at 16:02:10 +0000