lindemeier / painty

C++ library for non photorealistic rendering. Includes a paint renderer based on Kubelka Munk equations, stroke based rendering algorithms and artistic image filters.
MIT License
23 stars 2 forks source link

std::bad_cast error in palette_extraction #65

Open iwnlcyan opened 2 months ago

iwnlcyan commented 2 months ago

Hello @lindemeier , I am trying to use the code for solving the weights of base pigments for colors, just built it on an Ubuntu virtual machine.. But when I hope to run with the examples in the repo, using the given measured coefficients, it keeps occuring std::bad_cast error. I'm not sure but seems like it happens after loading the JSON file, in the LoadPalette() in main, but it's still a bad_cast even if I manually define the palette variable with values in the JSON.. I am wondering have you got this issue before? Is it to do with type definition with eigen or something else? image image