cmu-ci-lab / MitsubaToFRenderer

Mitsuba time-of-flight renderer.
54 stars 22 forks source link

Error when compiling on Ubuntu 16.04 #2

Closed chaoranzhang closed 5 years ago

chaoranzhang commented 5 years ago

Hi, I tried to compile it on my Ubuntu 16 system, however, the compilation fail due to the following error.

/usr/include/eigen3/Eigen/src/Core/SelfCwiseBinaryOp.h:19:28: required from ‘Derived& Eigen::DenseBase::operator=(const Scalar&) [with Derived = Eigen::Matrix<DScalar1<float, Eigen::Matrix<float, 1, 7> >, 3, 1, 0, 3, 1>; Eigen::DenseBase::Scalar = DScalar1<float, Eigen::Matrix<float, 1, 7> >]’ src/integrators/misc/motion.cpp:471:7: required from here /usr/include/eigen3/Eigen/src/Core/functors/AssignmentFunctors.h:88:102: error: no match for ‘operator=’ (operand types are ‘DScalar1<float, Eigen::Matrix<float, 1, 7> >’ and ‘const DScalar1<float, Eigen::Matrix<float, 1, 7> >’) EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void assignCoeff(DstScalar& a, const SrcScalar& b) const { a = b; } ^ In file included from src/integrators/misc/motion.cpp:21:0: include/mitsuba/core/autodiff.h:252:19: note: candidate: DScalar1<_Scalar, _Gradient>& DScalar1<_Scalar, _Gradient>::operator=(const Scalar&) [with _Scalar = float; _Gradient = Eigen::Matrix<float, 1, 7>; DScalar1<_Scalar, _Gradient>::Scalar = float] inline DScalar1& operator*=(const Scalar &v) { ^ include/mitsuba/core/autodiff.h:252:19: note: no known conversion for argument 1 from ‘const DScalar1<float, Eigen::Matrix<float, 1, 7> >’ to ‘const Scalar& {aka const float&}’ scons: *** [build/release/integrators/misc/motion.os] Error 1 scons: building terminated because of errors.

chaoranzhang commented 5 years ago

I followed the "INSTALL.txt", and the "scons" command report the error.

AdithyaPediredla commented 5 years ago

Dear Chaoranzhang:

Thank you for the question.

Can you please reinstall and link Eigen and make sure that all the steps worked correctly.

By the way, if you are not going to use motion integrator (to simulate motion blur in your simulations), you can disable the motion integrator alone (as it is the one causing the problems) by commenting line 21 (plugins += env.SharedLibrary('motion', ['misc/motion.cpp'])) of src/integrators/SConscript.

Please let me know how it goes.

Regards, Adithya

chaoranzhang commented 5 years ago

Dear Chaoranzhang:

Thank you for the question.

Can you please reinstall and link Eigen and make sure that all the steps worked correctly.

By the way, if you are not going to use motion integrator (to simulate motion blur in your simulations), you can disable the motion integrator alone (as it is the one causing the problems) by commenting line 21 (plugins += env.SharedLibrary('motion', ['misc/motion.cpp'])) of src/integrators/SConscript.

Please let me know how it goes.

Regards, Adithya

Thanks for your advice, the Mitsuba has been compiled successfully after re-install the Eigen3

AdithyaPediredla commented 5 years ago

I am glad that worked.

I am closing the issue now. Please report any other problem you face.