11 for(
int i = 0; i < (int)
inputs_.size(); i++) {
25 for(
int i = 0; i < (int)inputPaths.size(); i++) {
27 string const extension
28 = inputPaths[i].substr(inputPaths[i].find_last_of(
'.') + 1);
30 if(extension ==
"vti") {
32 }
else if(extension ==
"vtp") {
34 }
else if(extension ==
"vtu") {
35 ret = load<vtkXMLUnstructuredGridReader>(
39 msg <<
"[ttkProgramBase] Unknown input extension `" << extension <<
"' :("
57 for(
int i = 0; i <
vtkWrapper_->GetNumberOfOutputPorts(); i++) {
61 if((
vtkWrapper_->GetOutput(i)->GetDataObjectType() == VTK_IMAGE_DATA)) {
64 save<vtkXMLImageDataWriter>(i);
67 if((
vtkWrapper_->GetOutput(i)->GetDataObjectType() == VTK_POLY_DATA)) {
70 save<vtkXMLPolyDataWriter>(i);
74 == VTK_UNSTRUCTURED_GRID)) {
77 save<vtkXMLUnstructuredGridWriter>(i);
std::vector< vtkSmartPointer< vtkXMLPolyDataReader > > polyDataReaders_
int execute() override
Set the arguments of your ttk module and execute it here.
std::vector< vtkSmartPointer< vtkXMLImageDataReader > > imageDataReaders_
int load(const std::string &fileName, std::vector< vtkSmartPointer< vtkReaderClass > > &readerList)
vtkDataSetAlgorithm * vtkWrapper_
std::vector< vtkSmartPointer< vtkXMLUnstructuredGridReader > > unstructuredGridReaders_
int save() const override
Save the output(s) of the TTK module.
std::vector< vtkDataSet * > inputs_
int printErr(const std::string &msg, const debug::LineMode &lineMode=debug::LineMode::NEW, std::ostream &stream=std::cerr) const