Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes Eigen quaternion member access #52

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

brgrp
Copy link

@brgrp brgrp commented Apr 16, 2021

Ubuntu 20.04 - Eigen 3.3.7

I encountered the same problem on Ubuntu 20.04. In my case, I could build the library by changing:

        .def("x", (double (Eigen::Quaterniond::*) () const) &Eigen::Quaterniond::x)
        .def("y", (double (Eigen::Quaterniond::*) () const) &Eigen::Quaterniond::y)
        .def("z", (double (Eigen::Quaterniond::*) () const) &Eigen::Quaterniond::z)
        .def("w", (double (Eigen::Quaterniond::*) () const) &Eigen::Quaterniond::w)

in g2opy/python/core/eigen_types.h to:

        .def("x", [](const Eigen::Quaterniond& q) { return q.x(); })
        .def("y", [](const Eigen::Quaterniond& q) { return q.y(); })
        .def("z", [](const Eigen::Quaterniond& q) { return q.z(); })
        .def("w", [](const Eigen::Quaterniond& q) { return q.w(); })

Originally posted by @koide3 in #46 (comment)

Ubuntu 20.04 - Eigen 3.3.7
@Ali007788
Copy link

Hello @codegrafix,

I just tried your solution to build the library on Ubuntu 20.04 - Eigen 3.3.7. I got the steps till 99%, but it still doesn't work!
Do you have any idea how to solve it?

thanks

@miquelmassot
Copy link

This solution works on Ubuntu 20.04 in WSL2 with stock Eigen 3.3.7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants