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

Is another version of OpenMesh used? #8

Open
yosun opened this issue Jan 28, 2022 · 2 comments
Open

Is another version of OpenMesh used? #8

yosun opened this issue Jan 28, 2022 · 2 comments

Comments

@yosun
Copy link

yosun commented Jan 28, 2022

Hi - I downloaded OpenMesh 6.3 but this error occurs when I run make:

/home/ubuntu/c/HairNet_DataSetGeneration/Hair_generate_convdata_and_imgs/HairHelper.h:15:38: fatal error: OpenMesh/Core/IO/MeshIO.hh: No such file or directory

HairNet_DataSetGeneration/Hair_generate_convdata_and_imgs/build$ cmake ..
-- Found OpenCV: /usr/local (found version "4.2.0") 
-- Configuring done
-- Generating done
-- Build files have been written to: /home/ubuntu/c/HairNet_DataSetGeneration/Hair_generate_convdata_and_imgs/build
ubuntu@ip-172-31-28-83:~/c/HairNet_DataSetGeneration/Hair_generate_convdata_and_imgs/build$ make
[ 20%] Building CXX object CMakeFiles/Hair_generate_convdata_and_imgs.dir/main.cpp.o
In file included from /home/ubuntu/c/HairNet_DataSetGeneration/Hair_generate_convdata_and_imgs/TrainingDataGenerator.h:15:0,
                 from /home/ubuntu/c/HairNet_DataSetGeneration/Hair_generate_convdata_and_imgs/main.cpp:14:
/home/ubuntu/c/HairNet_DataSetGeneration/Hair_generate_convdata_and_imgs/HairHelper.h:15:38: fatal error: OpenMesh/Core/IO/MeshIO.hh: No such file or directory
compilation terminated.
CMakeFiles/Hair_generate_convdata_and_imgs.dir/build.make:75: recipe for target 'CMakeFiles/Hair_generate_convdata_and_imgs.dir/main.cpp.o' failed
make[2]: *** [CMakeFiles/Hair_generate_convdata_and_imgs.dir/main.cpp.o] Error 1
CMakeFiles/Makefile2:82: recipe for target 'CMakeFiles/Hair_generate_convdata_and_imgs.dir/all' failed
make[1]: *** [CMakeFiles/Hair_generate_convdata_and_imgs.dir/all] Error 2
Makefile:90: recipe for target 'all' failed
make: *** [all] Error 2
@catid
Copy link

catid commented Feb 2, 2022

Build instructions that worked for me on Ubuntu 20:

sudo apt install freeglut3-dev libglew-dev libglfw3-dev libopencv-dev libglm-dev


OpenMesh docs:

https://www.graphics.rwth-aachen.de/media/openmesh_static/Daily-Builds/Doc/a05901.html

OpenMesh install:

git clone --recursive https://gitlab.vci.rwth-aachen.de:9000/OpenMesh/OpenMesh.git

cd OpenMesh
mkdir build
cd build
cmake ..
make -j8
sudo make install

Should install to /usr/local/lib/


Fixes for HairNet_DataSetGeneration:

Renderer.h: Add #include <random>

CMakeLists.txt:
Replace "/home/yi/OpenMesh-6.3/build/Build/lib/libOpenMeshCore.so" with "/usr/local/lib/libOpenMeshCore.a"
Replace "/home/yi/OpenMesh-6.3/build/Build/lib/libOpenMeshTools.so" with "/usr/local/lib/libOpenMeshTools.a"
Replace "${GLFW3_LIBRARY}" with "glfw"
Replace "${GLEW_LIBRARY}" with "${GLEW_LIBRARIES}"

@yosun
Copy link
Author

yosun commented Feb 27, 2022

~/HairNet_DataSetGeneration/HairNet_DataSetGeneration/Hair_generate_convdata_and_imgs/build$ make -j8
[ 20%] Linking CXX executable Hair_generate_convdata_and_imgs
CMakeFiles/Hair_generate_convdata_and_imgs.dir/main.cpp.o: In function visualize_and_save_hair_orient(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, int)': main.cpp:(.text+0x93a): undefined reference to glfwInit'
main.cpp:(.text+0x949): undefined reference to glfwWindowHint' main.cpp:(.text+0x958): undefined reference to glfwWindowHint'
main.cpp:(.text+0x967): undefined reference to glfwWindowHint' main.cpp:(.text+0x976): undefined reference to glfwWindowHint'
main.cpp:(.text+0x985): undefined reference to glfwWindowHint' main.cpp:(.text+0x9a4): undefined reference to glfwCreateWindow'
main.cpp:(.text+0x9ba): undefined reference to glfwMakeContextCurrent' main.cpp:(.text+0x1035): undefined reference to glfwSwapBuffers'
main.cpp:(.text+0x168e): undefined reference to glfwPollEvents' main.cpp:(.text+0x1a64): undefined reference to glfwTerminate'
collect2: error: ld returned 1 exit status
CMakeFiles/Hair_generate_convdata_and_imgs.dir/build.make:164: recipe for target 'Hair_generate_convdata_and_imgs' failed
make[2]: *** [Hair_generate_convdata_and_imgs] Error 1
CMakeFiles/Makefile2:82: recipe for target 'CMakeFiles/Hair_generate_convdata_and_imgs.dir/all' failed
make[1]: *** [CMakeFiles/Hair_generate_convdata_and_imgs.dir/all] Error 2
Makefile:90: recipe for target 'all' failed
make: *** [all] Error 2

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

No branches or pull requests

2 participants