04

VTK6 引入了许多不兼容的变。其中之一是删除vtkDataObject中所有有关管道的方法。其中的两个方法就是GetPipelineInformation() 和 GetExecutive()。这些方法被移到vtkAlgorithm 和vtkExecutive类中。

例子1


vtkDataObject* dobj = algorithm->GetOutput();
vtkExecutive* exec = dobj->GetExecutive();

替换成:

vtkExecutive* exec = algorithm->GetExecutive();

例子2

vtkDataObject* dobj = algorithm->GetOutput();
vtkInformation* info = dobj->GetPipelineInformation();

替换成:

algorithm->GetExecutive()->GetOutputInformation(0 /* port number */);

原文地址:https://www.cnblogs.com/ankier/p/3167982.html