Hi all. I want to use Powercrust and PoissonReconstruction in Python. The version of VTK I am using is 9.0.3. I configured VTK_MODULE_ENABLE_VTK_PoissonReconstruction and VTK_MODULE_ENABLE_VTK_Powercrust to WANT in CMake, set up the Python-related values, and generated Powercrust.cp38-win_amd64.pyd and PoissonReconstruction.cp38-win_amd64.pyd in Visual Studio. However, when I used print(dir()) to check, I found that there were no callable methods. I checked the relevant Python wrapper files and they seem incomplete? How can I achieve my goal?Thanks for your help.
For some reason, the CMakeLists.txt
wasn’t set up for wrapping.
Edit Remote/Powercrust/CMakeLists.txt
and modify vtk_module_add_module()
as follows:
vtk_module_add_module(VTK::Powercrust
SOURCES vtkPowerCrustSurfaceReconstruction.cxx
HEADERS vtkPowerCrustSurfaceReconstruction.h
)
The HEADERS
was missing, and without HEADERS
(or, alternatively, CLASSES
), the wrappers cannot be generated.
1 Like