pyomeca / ezc3d

Easy to use C3D reader/writer for C++, Python and Matlab
https://pyomeca.github.io/Documentation/ezc3d/index.html
MIT License
145 stars 46 forks source link

Problem with CMAKE #301

Closed dtakeshita closed 1 year ago

dtakeshita commented 1 year ago

I tried to compile with CMake. But, I get an error when I try to configure on CMake. What does this mean?

cmake
pariterre commented 1 year ago

Hi there! Can you scroll up in the output window at the bottom, the actual error message should be written over there

dtakeshita commented 1 year ago

Sorry I missed the error message. It says like below, but I had installed Visual Studio (Microsoft Visual Studio Community 2022, Version 17.7.6, VisualStudio.17.Release/17.7.6+34221.43). Is there something to do like giving a path for Visual Studio or anything like that? I really need to do this although I am horribly stuck. I really appreciate your help.

CMake Error at CMakeLists.txt:2 (project): Generator

Visual Studio 17 2022

could not find any instance of Visual Studio.

pariterre commented 1 year ago

Hi @dtakeshita !

This issue is a CMake issue, not an ezc3d issue. There are plenty of reasons why CMake won't find Visual Studio on your computer. The most likely is that you have VS, but you forgot to install the C++ compiler that comes with it. You can have a look here (first answer): https://stackoverflow.com/questions/51668676/cmake-visual-studio-15-2017-could-not-find-any-instance-of-visual-studio to get some help!

Also, if you need help compiling thereafter, I suggest this video I made: https://www.youtube.com/watch?v=gWno_NXrITA

That said, if you have never compiled a C++ project, I suspect you are not using ezc3d from C++. If you are using it from Python, I strongly suggest to use the precompiled version on anaconda conda install ezc3d -cconda-forge. Please refer to the documentation to see how!

dtakeshita commented 1 year ago

Thanks for a quick reply. Actually, I would like to use ezc3d from Matlab. In that case, how would you install?

pariterre commented 1 year ago

For Matlab, you will need to compile. The video I provided will help, but you must properly install Visual Studio with C++ compiler first. So both links should help :)

dtakeshita commented 1 year ago

Although the contents of the configure files was different from your video, I managed to use ezc3d on Matlab!!! Your information was very helpful. Thanks a lot!!!