PoseCNN icon indicating copy to clipboard operation
PoseCNN copied to clipboard

GL_SHADER_STORAGE_BUFFER’ was not declared in this scope

Open zuwuwang opened this issue 6 years ago • 5 comments

(poseCNN) cxx@cxx:~/wzw/poseEstimate/poseCNN/lib/synthesize/build$ make Scanning dependencies of target synthesizer [ 25%] Building CXX object CMakeFiles/synthesizer.dir/synthesize.cpp.o In file included from /home/cxx/wzw/third-party/Pangolin/include/pangolin/pangolin.h:33:0, from /home/cxx/wzw/poseEstimate/poseCNN/lib/synthesize/synthesize.hpp:15, from /home/cxx/wzw/poseEstimate/poseCNN/lib/synthesize/synthesize.cpp:1: /home/cxx/wzw/third-party/Pangolin/include/pangolin/gl/gl.h:173:29: error: ‘GL_SHADER_STORAGE_BUFFER’ was not declared in this scope GlShaderStorageBuffer = GL_SHADER_STORAGE_BUFFER ^ In file included from /home/cxx/wzw/third-party/Pangolin/include/pangolin/gl/gl.h:248:0, from /home/cxx/wzw/third-party/Pangolin/include/pangolin/pangolin.h:33, from /home/cxx/wzw/poseEstimate/poseCNN/lib/synthesize/synthesize.hpp:15, from /home/cxx/wzw/poseEstimate/poseCNN/lib/synthesize/synthesize.cpp:1: /home/cxx/wzw/third-party/Pangolin/include/pangolin/gl/gl.hpp: In member function ‘void pangolin::GlTexture::CopyFrom(const pangolin::GlTexture&)’: /home/cxx/wzw/third-party/Pangolin/include/pangolin/gl/gl.hpp:298:40: error: ‘glCopyImageSubData’ was not declared in this scope width, height, 1);

zuwuwang avatar May 29 '18 08:05 zuwuwang

You can comment out this line: /home/cxx/wzw/third-party/Pangolin/include/pangolin/gl/gl.h:173:29

yuxng avatar May 29 '18 20:05 yuxng

@yuxng I also have this problem and what do you mean by comment out? if you mean comment in file gl.h, it will be huge work to do as there are a lot of private function in this file, each one of them will evoke an error, so do you think it might be the reason of wrong version of opengl or pangolin?

Cheren15 avatar Jun 14 '18 21:06 Cheren15

Hi @yuxng, Do you have any solution for the second error : /home/cxx/wzw/third-party/Pangolin/include/pangolin/gl/gl.hpp:298:40: error: ‘glCopyImageSubData’ was not declared in this scope width, height, 1); ?

Also do you know where these errors might come from ? Could it be because I used the wrong Pangolin branch ?

Thanks

TotoLulu94 avatar Jun 26 '18 17:06 TotoLulu94

For those who have this issue, these errors can come from 2 things :

  • Your OpenGL/Glew version isn't recent enough (glCopyImageSubData only implemented for OpenGL version >= 4.1)
  • or, you have at least 2 directories GL and "pangolin/gl/glplatform.h" includes the wrong <GL/glew.h>.

see : https://github.com/stevenlovegrove/Pangolin/issues/268

TotoLulu94 avatar Jun 27 '18 15:06 TotoLulu94

Hi @TotoLulu94 ,so would upgrade opengl version solve this problem? which opengl version is required?

Update: My opengl version is:

OpenGL version string: 4.5.0 NVIDIA 384.130

I still got the same issue above, how to fix this?

Update: Solved this problem by changing the

<GL/glew.h>

in

pangolin/gl/glplatform.h

using

/usr/include/GL/glew.h

which was mentioned in https://github.com/stevenlovegrove/Pangolin/issues/268

liuyunyao1996 avatar Mar 03 '19 13:03 liuyunyao1996