Closed mvieth closed 1 week ago
One addition: there currently seem to be some constraints regarding which point types can be removed from/need to be present in PCL_XYZ_POINT_TYPES
and PCL_NORMAL_POINT_TYPES
(depending on which PCL modules are built, and whether tests are built or not). Perhaps we can improve this in a future pull request. Currently, in my tests, PCL_NORMAL_POINT_TYPES=(pcl::Normal)(pcl::PointNormal)
and PCL_XYZ_POINT_TYPES=(pcl::PointXYZ)(pcl::PointXYZI)(pcl::PointXYZL)(pcl::PointXYZRGB)(pcl::PointXYZRGBA)(pcl::PointXYZRGBL)(pcl::PointNormal)(pcl::PointXYZINormal)(pcl::PointXYZLNormal)(pcl::PointXYZRGBNormal)(pcl::PointWithRange)
seem to work.
…instantiated
Previously, users could only choose between all types, some types ("core types" although it is not transparent which types these are), and no types (
PCL_NO_PRECOMPILE
).PCL_XYZ_POINT_TYPES
andPCL_NORMAL_POINT_TYPES
are now configurable via CMake (these only take effect ifPCL_ONLY_CORE_POINT_TYPES
andPCL_NO_PRECOMPILE
are OFF). This enables users on all platforms and compilers to reduce PCL compile times and library size. Additionally, for users of MSVC or MINGW,PCL_ONLY_CORE_POINT_TYPES
is now ON by default and not statically added to the definitions in CMakeLists.txt. I believe this is behaviour is more transparent, and these users now have the option to setPCL_ONLY_CORE_POINT_TYPES
to OFF and choose the instantiated types viaPCL_XYZ_POINT_TYPES
andPCL_NORMAL_POINT_TYPES
instead. However one of these two ways to reduce the set of instantiations must be used on Windows to avoid the linker errorfatal error LNK1189: library limit of 65535 objects exceeded
when trying to link the features library.Fixes https://github.com/PointCloudLibrary/pcl/issues/5928