Can anyone give me a link to the nvsdk cvs, + some directions…
Also any pointers on getting started with the newest features (shaders programs etc) would helpful. I’ve done a lot with standard OpenGL, but am now ready to start playing with the advanced features.
OK, now that I have it, how do I get everything to build. I had tried this a while ago, and needed some work arounds. I expected it to be working out-of-the-box by now…
The thing that I had to do before was comment out a bunch of the extensions in gl.h. I tryied this, and I still get lots of errors. Any other things that need to be changed?
I noticed some files were being included, but they do not exist in the tree:
ie. #include <nv_math.h>
This gets the makefile to build the *.cpp files for the build.
After that is fixed the jpeg libs seem to break. Here’s the output from the broken (BROKEN) build
make[2]: Entering directory /usr/home/jamie/nvsdk/OpenGL/src/libs/nv_util' g++ -DUNIX -Wall -g -I../../../include/glh -I../../../include/shared -I../../../include/nv_util/ -I../../../include/ -I../../../include/unzip -c nv_jpeg.cpp In file included from /usr/include/c++/3.2/bits/localefwd.h:50, from /usr/include/c++/3.2/ios:48, from /usr/include/c++/3.2/ostream:45, from /usr/include/c++/3.2/iostream:45, from ../../../include/jpeg/jconfig.h:3, from ../../../include/jpeg/jpeglib.h:30, from nv_jpeg.cpp:17: /usr/include/c++/3.2/bits/functexcept.h:40: previous declaration ofvoid
std::__throw_bad_exception()’ with C++ linkage
/usr/include/c++/3.2/bits/functexcept.h:40: conflicts with new declaration with
C linkage
/usr/include/c++/3.2/bits/functexcept.h:44: previous declaration of void std::__throw_bad_alloc()' with C++ linkage /usr/include/c++/3.2/bits/functexcept.h:44: conflicts with new declaration with C linkage /usr/include/c++/3.2/bits/functexcept.h:48: previous declaration ofvoid
std::__throw_bad_cast()’ with C++ linkage
/usr/include/c++/3.2/bits/functexcept.h:48: conflicts with new declaration with
C linkage
/usr/include/c++/3.2/bits/functexcept.h:51: previous declaration of `void
std::__throw_bad_typeid()’ with C++ linkage
Move the original ones from /usr/include/GL to a safe place.
Move the new ones to /usr/include/GL
Modify src/tools/nvparse/Makefile…
I just changed the (MAIN) libnvparse.a target to not depend on (OBJS).
Added a bunch of “#include <cctype>” to files in src/tools/nvparse.
Pacthed /usr/include/GL/glx.h to this:
301 #ifndef GLX_GLXEXT_LEGACY
302 #define GLX_GLXEXT_PROTOTYPES
303 #include <GL/glxext.h>
304
305 #else
This define seems to be necessary, but isn’t defined anywhere. Can someone with more knowledge of GLX_GLXEXT_PROTOTYPE give an explanation?
Patched /usr/include/GL/glut.h to not redefine APIENTRY. (Also located somewhere in nvsdk-includes, under glh/GL I think.)
Patched top of nvsdk/OpenGL/include/jpeg/jconfig.h to:
//#include <stdio.h>
//#include <stdlib.h>
//#include <iostream.h>
//#include <string.h>
//#include <stdarg.h>
//#include <math.h>
//#include <malloc.h>
//#include <string.h> #ifdef _WIN32
This gets rid of your jpeg problem.
Patched nvsdk/OpenGL/src/libs/paramgl/paramgl.cpp to:
*** 130,140 ****
int i = (y - start_y) / separation;
Thanks for the reply. That did fix a bunch of things. I’m still working through some issues though.
After seeing the state of the SDK, it looks like this thing really is not supported. When the first Linux build came out, there were only a couple of things that needed to be fixed to get it to compile – that was OK because it had just come out. Now, much later, the whole thing seems to have fallen appart. I would have expected it to have gotten better…
Any NVidia people here?
I was working with the SDK, and have been putting off using the CG compiler until later. I was under the impression that they were both supported, and being developed. Now I’m wondering if the CG compiler is better supported one, and the SDK is being left by the wayside.
Regarding step 8: Should it have been “cvs co -kb nvsdk/SDK”?
Whichever I try, I get:
ssh: connect to address 209.213.198.12 port 22: Connection timed out
cvs [checkout aborted]: end of file from server (consult above messages if any)
The errors above is because GLX_GLXEXT_PROTOTYPES isn’t defined. I have “solved” this by hacking my <GL/glx.h> to define this if GLX_GLXEXT_LEGACY isn’t defined:
Is this the proper way to do it? I don’t think so, since hacking header files doesn’t seem to be a good idea. There should be an “official” correct version of the header file, as there is for glext.h and glxext.h, namely http://oss.sgi.com/projects/ogl-sample/sdk.html.
Hope this helps, and that someone who knows how to do this correctly wuold please explain it to me
The new one seems to work now, with the same fixes that the old one needed. Comment out all of the ext arb nv etc. defines in gl.h and glx.h, I also had to install the fftw library for one of the demos to work. This is very cool. I guess that NVidia is supporting the SDK + linux