프로그램 사용/kinect2024. 7. 13. 23:05

귀찮으니 실행은 다음에 해보는 걸로 ㅋ

 

cmake .. -DENABLE_CUDA=OFF
CMake Deprecation Warning at CMakeLists.txt:1 (CMAKE_MINIMUM_REQUIRED):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- using tinythread as threading library
-- Checking for modules 'libva;libva-drm'
--   No package 'libva' found
--   No package 'libva-drm' found
-- Could NOT find TegraJPEG (missing: TegraJPEG_LIBRARIES TegraJPEG_INCLUDE_DIRS TegraJPEG_WORKS) 
CMake Warning (dev) at /home/minimonk/.local/lib/python3.10/site-packages/cmake/data/share/cmake-3.30/Modules/FindOpenGL.cmake:415 (message):
  Policy CMP0072 is not set: FindOpenGL prefers GLVND by default when
  available.  Run "cmake --help-policy CMP0072" for policy details.  Use the
  cmake_policy command to set the policy and suppress this warning.

  FindOpenGL found both a legacy GL library:

    OPENGL_gl_LIBRARY: /usr/lib/x86_64-linux-gnu/libGL.so

  and GLVND libraries for OpenGL and GLX:

    OPENGL_opengl_LIBRARY: /usr/lib/x86_64-linux-gnu/libOpenGL.so
    OPENGL_glx_LIBRARY: /usr/lib/x86_64-linux-gnu/libGLX.so

  OpenGL_GL_PREFERENCE has not been set to "GLVND" or "LEGACY", so for
  compatibility with CMake 3.10 and below the legacy GL library will be used.
Call Stack (most recent call first):
  CMakeLists.txt:269 (FIND_PACKAGE)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Could NOT find OpenCL (missing: OpenCL_LIBRARY OpenCL_INCLUDE_DIR) 
-- Linking with these libraries: 
 /usr/lib/x86_64-linux-gnu/libusb-1.0.so
 pthread
 /usr/lib/x86_64-linux-gnu/libturbojpeg.so.0
 /usr/lib/x86_64-linux-gnu/libglfw.so
 /usr/lib/x86_64-linux-gnu/libGL.so
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE) 
-- Configurating examples
CMake Deprecation Warning at examples/CMakeLists.txt:1 (CMAKE_MINIMUM_REQUIRED):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

  Update the VERSION argument <min> value or use a ...<max> suffix to tell
  CMake that the project does not need compatibility with older versions.


-- Using in-tree freenect2 target
-- Feature list:
--   CUDA    disabled
--   CXX11    disabled
--   Examples    yes
--   OpenCL    no
--   OpenGL    yes
--   OpenNI2    yes
--   TegraJPEG    no
--   Threading    tinythread
--   TurboJPEG    yes
--   VAAPI    no
--   VideoToolbox    no (Apple only)
--   streamer_recorder    disabled
-- Configuring done (0.1s)
-- Generating done (0.0s)
-- Build files have been written to: /home/minimonk/src/libfreenect2/build

 

$ make -j4
[  2%] Building CXX object CMakeFiles/generate_resources_tool.dir/tools/generate_resources.cpp.o
[  5%] Linking CXX executable bin/generate_resources_tool
[  5%] Built target generate_resources_tool
[  8%] Generating resources.inc.h
[ 10%] Building CXX object CMakeFiles/freenect2.dir/src/transfer_pool.cpp.o
[ 13%] Building CXX object CMakeFiles/freenect2.dir/src/event_loop.cpp.o
[ 16%] Building CXX object CMakeFiles/freenect2.dir/src/usb_control.cpp.o
[ 18%] Building CXX object CMakeFiles/freenect2.dir/src/allocator.cpp.o
[ 21%] Building CXX object CMakeFiles/freenect2.dir/src/frame_listener_impl.cpp.o
[ 24%] Building CXX object CMakeFiles/freenect2.dir/src/packet_pipeline.cpp.o
[ 27%] Building CXX object CMakeFiles/freenect2.dir/src/rgb_packet_stream_parser.cpp.o
[ 29%] Building CXX object CMakeFiles/freenect2.dir/src/rgb_packet_processor.cpp.o
[ 32%] Building CXX object CMakeFiles/freenect2.dir/src/depth_packet_stream_parser.cpp.o
[ 35%] Building CXX object CMakeFiles/freenect2.dir/src/depth_packet_processor.cpp.o
[ 37%] Building CXX object CMakeFiles/freenect2.dir/src/cpu_depth_packet_processor.cpp.o
[ 40%] Building CXX object CMakeFiles/freenect2.dir/src/resource.cpp.o
[ 43%] Building CXX object CMakeFiles/freenect2.dir/src/command_transaction.cpp.o
[ 45%] Building CXX object CMakeFiles/freenect2.dir/src/registration.cpp.o
[ 48%] Building CXX object CMakeFiles/freenect2.dir/src/logging.cpp.o
/home/minimonk/src/libfreenect2/src/cpu_depth_packet_processor.cpp: In member function ‘virtual void libfreenect2::CpuDepthPacketProcessor::loadP0TablesFromCommandResponse(unsigned char*, size_t)’:
/home/minimonk/src/libfreenect2/src/cpu_depth_packet_processor.cpp:844:53: warning: taking address of packed member of ‘libfreenect2::protocol::P0TablesResponse’ may result in an unaligned pointer value [-Waddress-of-packed-member]
  844 |     flipHorizontal(Mat(424, 512, p0table->p0table0), impl_->p0_table0);
      |                                            ~~~~~~~~~^~~~~~~~
/home/minimonk/src/libfreenect2/src/cpu_depth_packet_processor.cpp:845:53: warning: taking address of packed member of ‘libfreenect2::protocol::P0TablesResponse’ may result in an unaligned pointer value [-Waddress-of-packed-member]
  845 |     flipHorizontal(Mat(424, 512, p0table->p0table1), impl_->p0_table1);
      |                                            ~~~~~~~~~^~~~~~~~
/home/minimonk/src/libfreenect2/src/cpu_depth_packet_processor.cpp:846:53: warning: taking address of packed member of ‘libfreenect2::protocol::P0TablesResponse’ may result in an unaligned pointer value [-Waddress-of-packed-member]
  846 |     flipHorizontal(Mat(424, 512, p0table->p0table2), impl_->p0_table2);
      |                                            ~~~~~~~~~^~~~~~~~
/home/minimonk/src/libfreenect2/src/cpu_depth_packet_processor.cpp:850:42: warning: taking address of packed member of ‘libfreenect2::protocol::P0TablesResponse’ may result in an unaligned pointer value [-Waddress-of-packed-member]
  850 |     Mat p00(424, 512, p0table->p0table0);
      |                                 ~~~~~~~~~^~~~~~~~
/home/minimonk/src/libfreenect2/src/cpu_depth_packet_processor.cpp:852:38: warning: taking address of packed member of ‘libfreenect2::protocol::P0TablesResponse’ may result in an unaligned pointer value [-Waddress-of-packed-member]
  852 |     Mat(424, 512, p0table->p0table1).copyTo(impl_->p0_table1);
      |                             ~~~~~~~~~^~~~~~~~
/home/minimonk/src/libfreenect2/src/cpu_depth_packet_processor.cpp:853:38: warning: taking address of packed member of ‘libfreenect2::protocol::P0TablesResponse’ may result in an unaligned pointer value [-Waddress-of-packed-member]
  853 |     Mat(424, 512, p0table->p0table2).copyTo(impl_->p0_table2);
      |                             ~~~~~~~~~^~~~~~~~
[ 51%] Building CXX object CMakeFiles/freenect2.dir/src/libfreenect2.cpp.o
[ 54%] Building CXX object CMakeFiles/freenect2.dir/src/tinythread/tinythread.cpp.o
[ 56%] Building CXX object CMakeFiles/freenect2.dir/src/turbo_jpeg_rgb_packet_processor.cpp.o
[ 59%] Building CXX object CMakeFiles/freenect2.dir/src/flextGL.cpp.o
[ 62%] Building CXX object CMakeFiles/freenect2.dir/src/opengl_depth_packet_processor.cpp.o
[ 64%] Linking CXX shared library lib/libfreenect2.so
[ 64%] Built target freenect2
[ 70%] Building CXX object examples/CMakeFiles/Protonect.dir/Protonect.cpp.o
[ 72%] Building CXX object CMakeFiles/freenect2-openni2.dir/src/openni2/ColorStream.cpp.o
[ 72%] Building CXX object examples/CMakeFiles/Protonect.dir/__/src/flextGL.cpp.o
[ 75%] Building CXX object examples/CMakeFiles/Protonect.dir/viewer.cpp.o
[ 78%] Building CXX object CMakeFiles/freenect2-openni2.dir/src/openni2/DepthStream.cpp.o
/home/minimonk/src/libfreenect2/examples/Protonect.cpp: In function ‘int main(int, char**)’:
/home/minimonk/src/libfreenect2/examples/Protonect.cpp:157:7: warning: variable ‘deviceId’ set but not used [-Wunused-but-set-variable]
  157 |   int deviceId = -1;
      |       ^~~~~~~~
[ 81%] Building CXX object CMakeFiles/freenect2-openni2.dir/src/openni2/DeviceDriver.cpp.o
[ 83%] Building CXX object CMakeFiles/freenect2-openni2.dir/src/openni2/IrStream.cpp.o
[ 86%] Building CXX object CMakeFiles/freenect2-openni2.dir/src/openni2/Registration.cpp.o
[ 89%] Linking CXX executable ../bin/Protonect
[ 89%] Built target Protonect
[ 91%] Building CXX object CMakeFiles/freenect2-openni2.dir/src/openni2/Utility.cpp.o
[ 94%] Building CXX object CMakeFiles/freenect2-openni2.dir/src/openni2/VideoStream.cpp.o
[ 97%] Building CXX object CMakeFiles/freenect2-openni2.dir/src/tinythread/tinythread.cpp.o
In file included from /usr/include/string.h:535,
                 from /usr/include/openni2/Linux-x86/OniPlatformLinux-x86.h:34,
                 from /usr/include/openni2/OniPlatform.h:42,
                 from /usr/include/openni2/Driver/OniDriverAPI.h:24,
                 from /home/minimonk/src/libfreenect2/src/openni2/DeviceDriver.cpp:35:
In function ‘char* strncpy(char*, const char*, size_t)’,
    inlined from ‘void Freenect2Driver::Driver::register_uri(std::string)’ at /home/minimonk/src/libfreenect2/src/openni2/DeviceDriver.cpp:404:14:
/usr/include/x86_64-linux-gnu/bits/string_fortified.h:95:34: warning: ‘char* __builtin_strncpy(char*, const char*, long unsigned int)’ specified bound 256 equals destination size [-Wstringop-truncation]
   95 |   return __builtin___strncpy_chk (__dest, __src, __len,
      |          ~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~
   96 |                                   __glibc_objsize (__dest));
      |                                   ~~~~~~~~~~~~~~~~~~~~~~~~~
[100%] Linking CXX shared library lib/libfreenect2-openni2.so
[100%] Built target freenect2-openni2

 

~/src/libfreenect2/build$ tree -L 2 
.
├── CMakeCache.txt
├── CMakeFiles
│   ├── 3.30.0
│   ├── CMakeConfigureLog.yaml
│   ├── CMakeDirectoryInformation.cmake
│   ├── CMakeRuleHashes.txt
│   ├── CMakeScratch
│   ├── Makefile.cmake
│   ├── Makefile2
│   ├── TargetDirectories.txt
│   ├── cmake.check_cache
│   ├── freenect2-openni2.dir
│   ├── freenect2.dir
│   ├── generate_resources_tool.dir
│   ├── install-openni2.dir
│   ├── pkgRedirects
│   └── progress.marks
├── Makefile
├── bin
│   ├── Protonect
│   └── generate_resources_tool
├── cmake_install.cmake
├── doc
│   ├── CMakeFiles
│   ├── Makefile
│   └── cmake_install.cmake
├── examples
│   ├── CMakeFiles
│   ├── Makefile
│   └── cmake_install.cmake
├── freenect2.pc
├── freenect2Config.cmake
├── freenect2ConfigVersion.cmake
├── lib
│   ├── libfreenect2-openni2.so -> libfreenect2-openni2.so.0
│   ├── libfreenect2-openni2.so.0
│   ├── libfreenect2.so -> libfreenect2.so.0.2
│   ├── libfreenect2.so.0.2 -> libfreenect2.so.0.2.0
│   └── libfreenect2.so.0.2.0
├── libfreenect2
│   ├── config.h
│   └── export.h
└── resources.inc.h

15 directories, 28 files

 

bin/Protonect 를 실행하면 스트리밍 된다고 한다.

[링크 : https://www.notaboutmy.life/posts/run-kinect-2-on-ubuntu-20-lts/]

 

소스를 뒤져보니 glfw 라는 접두로 된 녀석을 통해 그리는데, openGL ES와 vulkan으로 그리는 듯?

[링크 : https://www.glfw.org/]

'프로그램 사용 > kinect' 카테고리의 다른 글

libfreenect2 실행 성공..  (0) 2024.07.15
libfreenect2 실행 실패  (0) 2024.07.14
kinect v2 / freenect 실패  (0) 2024.07.09
xbox one S / 기본형?  (0) 2024.06.25
kinect for windows v2 설치  (0) 2024.06.24
Posted by 구차니