Skip to content

shapeworks::StudioMesh

Representation of a single mesh. More...

#include <StudioMesh.h>

Public Functions

Name
StudioMesh()
Constructor.
~StudioMesh()
Destructor.
QString get_dimension_string()
Get the dimensions as a string for display (if loaded from an image)
vtkSmartPointer< vtkPolyData > get_poly_data()
Get the mesh polydata.
vnl_vector< double > get_center_transform()
Get the center transform.
void set_poly_data(vtkSmartPointer< vtkPolyData > poly_data)
Set the poly data directly.
void set_error_message(std::string error_message)
Set the error message.
std::string get_error_message()
Return the error message.
void apply_feature_map(std::string name, ImageType::Pointer image)
Apply a feature map.
void apply_scalars(MeshHandle mesh)
Apply scalars from another mesh, with a transform.
void interpolate_scalars_to_mesh(std::string name, Eigen::VectorXd positions, Eigen::VectorXf scalar_values)
Interpolation scalars at positions to this mesh.
double get_largest_dimension_size()
Return the range of largest axis (e.g. 200 for an object that sits in 100x200x100)
vtkFloatArray * get_or_create_array(std::string name, float default_value)
Get or create and return an array with a given name.
void paint_ffc(double world_pos[], double radius, bool inclusive)
Paint free form constraint.
bool has_ffc_paint()
Does this mesh have free form constraint paint?

Public Attributes

Name
constexpr const char *const FFC_PAINT

Detailed Description

class shapeworks::StudioMesh;

Representation of a single mesh.

The Mesh class represents a single mesh generated from an image file or set of particles. It is responsible for loading the image and generating a mesh from it.

Public Functions Documentation

function StudioMesh

StudioMesh()

Constructor.

function ~StudioMesh

~StudioMesh()

Destructor.

function get_dimension_string

QString get_dimension_string()

Get the dimensions as a string for display (if loaded from an image)

function get_poly_data

vtkSmartPointer< vtkPolyData > get_poly_data()

Get the mesh polydata.

function get_center_transform

vnl_vector< double > get_center_transform()

Get the center transform.

function set_poly_data

void set_poly_data(
    vtkSmartPointer< vtkPolyData > poly_data
)

Set the poly data directly.

function set_error_message

void set_error_message(
    std::string error_message
)

Set the error message.

function get_error_message

std::string get_error_message()

Return the error message.

function apply_feature_map

void apply_feature_map(
    std::string name,
    ImageType::Pointer image
)

Apply a feature map.

function apply_scalars

void apply_scalars(
    MeshHandle mesh
)

Apply scalars from another mesh, with a transform.

function interpolate_scalars_to_mesh

void interpolate_scalars_to_mesh(
    std::string name,
    Eigen::VectorXd positions,
    Eigen::VectorXf scalar_values
)

Interpolation scalars at positions to this mesh.

function get_largest_dimension_size

double get_largest_dimension_size()

Return the range of largest axis (e.g. 200 for an object that sits in 100x200x100)

function get_or_create_array

vtkFloatArray * get_or_create_array(
    std::string name,
    float default_value
)

Get or create and return an array with a given name.

function paint_ffc

void paint_ffc(
    double world_pos[],
    double radius,
    bool inclusive
)

Paint free form constraint.

function has_ffc_paint

bool has_ffc_paint()

Does this mesh have free form constraint paint?

Public Attributes Documentation

variable FFC_PAINT

static constexpr const char *const FFC_PAINT = "ffc_paint";

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