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_ffc_mode()
void display_sample(int i)
void display_shape(ShapeHandle shape)
void display_shapes(QVector< QSharedPointer< Shape >> shapes)
void set_selected_point_one(int id)
void set_selected_point_two(int id)
void set_mean(const Eigen::VectorXd & mean)
void reset_camera()
void update_lut()
StudioParticles get_current_shape()
vtkFloatArray * get_current_particle_scalars()
vtkSmartPointer< vtkPolyData > get_current_particle_poly_data()
void handle_new_mesh()
vtkSmartPointer< vtkPolyData > get_current_mesh()
std::vector< vtkSmartPointer< vtkPolyData > > get_current_meshes_transformed()
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(QSharedPointer< Shape > shape, int alignment_domain, int domain)
Request the transform for a given shape and domain.
vtkSmartPointer< vtkTransform > get_transform(QSharedPointer< 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.
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.

Detailed Description

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

void update_viewer_properties()

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

slot handle_feature_range_changed

void handle_feature_range_changed()

slot handle_image_slice_settings_changed

void handle_image_slice_settings_changed()

Public Functions Documentation

function Visualizer

Visualizer(
    Preferences & prefs
)

function ~Visualizer

~Visualizer()

function set_lightbox

void set_lightbox(
    LightboxHandle lightbox
)

set the lightbox

function set_session

void set_session(
    SessionHandle session
)

set the session

function set_center

void set_center(
    bool center
)

turn automatic centering on/off

function get_center

bool get_center()

get centering on/off

function set_alignment_domain

void set_alignment_domain(
    int domain
)

set the alignment domain

function get_alignment_domain

int get_alignment_domain()

get the current alignment domain

function set_show_glyphs

void set_show_glyphs(
    bool show
)

turn on/off glyph display

function set_show_surface

void set_show_surface(
    bool show
)

turn on/off surface display

function display_samples

void display_samples()

update the display using the current settings

function update_samples

void update_samples()

function update_landmarks

void update_landmarks()

function update_planes

void update_planes()

function update_ffc_mode

void update_ffc_mode()

function display_sample

void display_sample(
    int i
)

function display_shape

void display_shape(
    ShapeHandle shape
)

function display_shapes

void display_shapes(
    QVector< QSharedPointer< Shape >> shapes
)

function set_selected_point_one

void set_selected_point_one(
    int id
)

function set_selected_point_two

void set_selected_point_two(
    int id
)

function set_mean

void set_mean(
    const Eigen::VectorXd & mean
)

function reset_camera

void reset_camera()

function update_lut

void update_lut()

function get_current_shape

StudioParticles get_current_shape()

function get_current_particle_scalars

vtkFloatArray * get_current_particle_scalars()

function get_current_particle_poly_data

vtkSmartPointer< vtkPolyData > get_current_particle_poly_data()

function handle_new_mesh

void handle_new_mesh()

function get_current_mesh

vtkSmartPointer< vtkPolyData > get_current_mesh()

function get_current_meshes_transformed

std::vector< vtkSmartPointer< vtkPolyData > > get_current_meshes_transformed()

function get_feature_map

const std::string & get_feature_map() const

Get the currently selected feature map.

function set_uniform_feature_range

void set_uniform_feature_range(
    bool value
)

Set if we are using a uniform feature range.

function get_uniform_feature_range

bool get_uniform_feature_range(
    void 
)

Return if we are using a uniform feature range.

function set_feature_map

void set_feature_map(
    const std::string & feature_map
)

Set the currently selected feature map.

function clear_viewers

void clear_viewers()

clear out the viewers

function reset_feature_range

void reset_feature_range()

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

function get_feature_range

double * get_feature_range()

Get the current feature range.

function get_feature_raw_range

double * get_feature_raw_range()

Get the current raw feature range.

function get_feature_range_valid

bool get_feature_range_valid()

Return if the feature range is valid or not.

function update_feature_range

void update_feature_range(
    double * range
)

Update the feature range with a given range.

function update_feature_range

void update_feature_range(
    double min,
    double max
)

Update the feature range with a given range.

function get_transform

vtkSmartPointer< vtkTransform > get_transform(
    QSharedPointer< Shape > shape,
    int alignment_domain,
    int domain
)

Request the transform for a given shape and domain.

function get_transform

vtkSmartPointer< vtkTransform > get_transform(
    QSharedPointer< 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

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

Set domain opacities.

function get_opacities

std::vector< float > get_opacities()

Get domain opacities.

function get_current_glyph_size

double get_current_glyph_size()

Get the current glyph size.

function handle_ctrl_click

void handle_ctrl_click(
    PickResult result
)

Handle ctrl click.

function redraw

void redraw()

Redraw renderers.

function export_to_pixmap

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

QSize get_render_size()

Return render window size.


Updated on 2022-07-23 at 16:40:07 -0600