Use fixed-size Eigen block expressions in FrustumCulling
#2786
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
With the newest version of Eigen, I could not compile PCL
In file included from /usr/local/include/eigen3/Eigen/Core:142:0, from /home/caselitz/software/pcl/common/include/pcl/impl/point_types.hpp:46, from /home/caselitz/software/pcl/common/include/pcl/point_types.h:359, from /home/caselitz/software/pcl/filters/include/pcl/filters/frustum_culling.h:40, from /home/caselitz/software/pcl/filters/include/pcl/filters/impl/frustum_culling.hpp:41, from /home/caselitz/software/pcl/filters/src/frustum_culling.cpp:38: /usr/local/include/eigen3/Eigen/src/Core/Dot.h: In instantiation of ‘typename Eigen::ScalarBinaryOpTraits<typename Eigen::internal::traits<T>::Scalar, typename Eigen::internal::traits<OtherDerived>::Scalar>::ReturnType Eigen::MatrixBase<Derived>::dot(const Eigen::MatrixBase<OtherDerived>&) const [with OtherDerived = Eigen::Block<Eigen::Matrix<float, 4, 1>, -1, -1, false>; Derived = Eigen::Matrix<float, 3, 1>; typename Eigen::ScalarBinaryOpTraits<typename Eigen::internal::traits<T>::Scalar, typename Eigen::internal::traits<OtherDerived>::Scalar>::ReturnType = float]’: /home/caselitz/software/pcl/filters/include/pcl/filters/impl/frustum_culling.hpp:113:24: required from ‘void pcl::FrustumCulling<PointT>::applyFilter(std::vector<int>&) [with PointT = pcl::PointXYZ]’ /home/caselitz/software/pcl/filters/src/frustum_culling.cpp:44:1: required from here /usr/local/include/eigen3/Eigen/src/Core/Dot.h:75:3: error: static assertion failed: YOU_TRIED_CALLING_A_VECTOR_METHOD_ON_A_MATRIX EIGEN_STATIC_ASSERT_VECTOR_ONLY(OtherDerived) ^
This should fix it... replaced Eigen
block (0, 0, 3, 1)
withhead (3)
.