SMILX  1.01
Typedefs | Enumerations | Functions
milxModelApp.cxx File Reference

A swiss-army knife of model/surface processing. This application implements single/batch processing of models with various processing options found in the SMILI library.You are able to smooth, align, decimate etc. a number of surfaces easily via the commandline with this application (use –help). This application uses the milxModel class to do all processing. More...

#include <vector>
#include <tclap/CmdLine.h>
#include <vtkSmartPointer.h>
#include <vtkPolyData.h>
#include <vtkMultiThreader.h>
#include <vtkPolyDataCollection.h>
#include <vtkTransformCollection.h>
#include <milxFile.h>
#include <milxModel.h>

Go to the source code of this file.

Typedefs

typedef std::vector< std::string >::iterator stringiterator
 

Enumerations

enum  operations {
  none = 0, convert, duplicate, cat,
  split, scale, decimate, smooth,
  laplacian, thresholdscalars, flip, diffscalars,
  copyscalars, diffscalarspairs, statscalars, removescalars,
  mse, procrustes, icp, clip,
  voxelise, orient, flat, none = 0,
  info, convert, print, csv,
  none = 0, info, convert, labelinfo,
  rescale, invert, relabel, smooth,
  bilateral, median, gradmag, laplacian,
  distancemap, threshold, Otsu, crop,
  mask, resample, match, checker,
  add, diff, mean, merge,
  cast, flip, none = 0, convert,
  duplicate, cat, split, scale,
  decimate, smooth, laplacian, thresholdscalars,
  clip, flip, diffscalars, copyscalars,
  diffscalarspairs, statscalars, removescalars, mse,
  procrustes, icp
}
 

Functions

int main (int argc, char *argv[])
 

Detailed Description

A swiss-army knife of model/surface processing. This application implements single/batch processing of models with various processing options found in the SMILI library.

You are able to smooth, align, decimate etc. a number of surfaces easily via the commandline with this application (use –help). This application uses the milxModel class to do all processing.

Usage: Concatenate surfaces

$ milxModelApp *.vtk --cat -o initial.vtk

Split surfaces based on knowledge of known components of that surface

milxModelApp --split combined_new_weights.vtk --component Atlas_MRI_surface_R_ace.vtk --component Atlas_MRI_surface_R_fem.vtk -p split_ 

Copy scalars from atlas mesh to other meshes in directory and output to another directory with same names

milxModelApp --scalarcopy focus_atlases/focus_bladder_atlas.vtk results/bladder/asm_bladder_*.vtk -p results_scalars/bladder/

Clip meshes in directory keeping only parts with value of 1 and output to another directory with same names

milxModelApp --clip 1 results_scalars/bladder/asm_bladder_*.vtk -p results_clipped/bladder/

Compute scalars stats (mean, variance etc. per point) of meshes in directory and output single mesh (of first mesh) with stats as arrays in mesh

milxModelApp --scalarstats Hausdorff/bladder/bladder__*.vtk -o bladder_stats.vtk

Definition in file milxModelApp.cxx.

Function Documentation

◆ main()

int main ( int  argc,
char *  argv[] 
)

Program Info

Process Arguments

Optional

Clamped Optional

Switches

XOR Switches

Mandatory

Add argumnets

XOR args

Parse the argv array.

Get the value parsed by each arg.

Setup ITK Threads

Display operation

Partition list into two if option given

Open files

Geometric transforms potentially associated with the 'collection' item (e.g. with –icp).

Operate

Todo:
leak here?

Write result

Definition at line 71 of file milxModelApp.cxx.