Skip to content

Error compiling rgbd #3596

@du-xinyi

Description

@du-xinyi
  • OpenCV => :4.8.1:
  • Operating System / Platform => :ubuntu20.04:
  • Compiler => :g++:

In cmake, select with_opengl=on,my qt version is 6.5.3. The following error occurred at compile time

/usr/bin/ld: CMakeFiles/opencv_rgbd.dir/src/dynafu.cpp.o: in function cv::dynafu::DynaFuImpl<cv::Mat>::DynaFuImpl(cv::kinfu::Params const&)': dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x3ec): undefined reference to glGenRenderbuffersEXT'
/usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x3f9): undefined reference to glBindRenderbufferEXT' /usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x410): undefined reference to glRenderbufferStorageEXT'
/usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x41e): undefined reference to glGenFramebuffersEXT' /usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x42b): undefined reference to glBindFramebufferEXT'
/usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x442): undefined reference to glFramebufferRenderbufferEXT' /usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x450): undefined reference to glGenRenderbuffersEXT'
/usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x45d): undefined reference to glBindRenderbufferEXT' /usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x474): undefined reference to glRenderbufferStorageEXT'
/usr/bin/ld: dynafu.cpp:(.text._ZN2cv6dynafu10DynaFuImplINS_3MatEEC2ERKNS_5kinfu6ParamsE[_ZN2cv6dynafu10DynaFuImplINS_3MatEEC5ERKNS_5kinfu6ParamsE]+0x48b): undefined reference to `glFramebufferRenderbufferEXT'
collect2: error: ld returned 1 exit status
make[2]: *** [modules/rgbd/CMakeFiles/opencv_rgbd.dir/build.make:505: lib/libopencv_rgbd.so.4.8.1] Error 1

Undefined call function is in opencv_contrib/modules/rgbd/src/dynafu.cpp

Activity

changed the title [-]编译rgbd错误[/-] [+]Error compiling rgbd[/+] on Nov 22, 2023
remmel

remmel commented on Jan 26, 2024

@remmel

when calling cmake try to add -DOpenGL_GL_PREFERENCE=LEGACY

jiapei100

jiapei100 commented on May 7, 2024

@jiapei100

Yes.... A straight-forward solution is just to Turn OFF rgbd... Thank you ...

linked a pull request that will close this issue on Jul 15, 2024
asmorkalov

asmorkalov commented on Jul 17, 2024

@asmorkalov
Contributor

I made experiments with Ubuntu 18.04, 20.04 and 24.04. Only Ubuntu 24.04 provides QT6 package (6.4.2). All the combinations were built just fine and passed tests. Looks like your QT build is not complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      Participants

      @jiapei100@remmel@asmorkalov@du-xinyi

      Issue actions

        Error compiling rgbd · Issue #3596 · opencv/opencv_contrib