Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何检查是否vtkPolyData有点数据或单元数据或没有?
vtkPolyData
在 Python 中,您可以执行以下操作:
poly.GetPointData().GetNumberOfArrays() poly.GetCellData().GetNumberOfArrays()
在 C++ 中,您可以类似地执行以下操作:
poly->GetPointData()->GetNumberOfArrays() poly->GetCellData()->GetNumberOfArrays()
请注意,vtkPolyData 可以同时具有点和单元数据。