Closed Luomin1993 closed 6 years ago
Hi, this seems to be a problem of GLSL compilation which is independent of xworld3d itself. Can you try compiling a small standalone GLSL program with OpenGL?
Specifically, in RoboSchool "roboschool/cpp-household/render-simple.cpp" where "simple_texturing.vert.glsl" is compiled:
219 program_tex = GLShaderProgram::load_program(
220 "simple_texturing.vert.glsl",
221 "",
222 "simple_texturing.frag.glsl");
You can take this code block to a small standalone program and test it.
Ok,thanks,Now I'm trying to recompile the project XWorld, When the make run at compiling the roboschool part, I meet "cannot find -lOpenGL" I find " LIBS =-L/usr/lib64 -lm -lOpenGL" in the Makefile.... How can I get the -lOpenGL( I only have -lGL -lGLU )
You can try replacing -lOpenGL with -lGL. libOpenGL.so contains the core functions for OpenGL, which is cleaner than libGL.so
Please tell me how can I get the "libOpenGL.so", I can't find thar by searching...
Because I get bellow when I try replacing -lOpenGL with -lGL:
among which test_xworld3d: gl_context.cpp:37: virtual void SimpleRender::GLContext::print_info(): Assertion `glGetString(GL_VERSION)' failed.
Weird. If you reach that point, EGL context should have been created without error and you should be able to get GL_VERSION string.
Can you tell us a bit more about your environment, .e.g., graphics drivers, results of locate libEGL
.
libOpenGL.so is not something you can download and install. Recent Nvidia drivers usually come with one. If you want, you can use libglvnd to generate libOpenGL.so.
Oh,thanks, finally I find the libOpenGL.so in the -L/usr/lib/nvidia-384 and I recompile that but when I run './test_xworld3d.sh' I got no Graphic or 3D Windows but only some text output:
[EGL] Detected 1 devices, among which I0905 14:01:30.182032 28026 teacher.cpp:170] Task group XWorld3DNav sentences: 709383 I0905 14:01:30.182063 28026 teacher.cpp:172] Total: 709383 I0905 14:01:33.494665 28026 test_xworld3d.cpp:55] -0.01 I0905 14:01:33.510579 28026 test_xworld3d.cpp:55] -0.01 I0905 14:01:33.527221 28026 test_xworld3d.cpp:55] -0.01 ... I0905 14:01:35.072829 28026 test_xworld3d.cpp:55] -0.01 I0905 14:01:35.088318 28026 test_xworld3d.cpp:55] -0.01 I0905 14:01:35.088397 28026 teacher.cpp:184] === XWorld3DNavTargetAvoid === I0905 14:01:35.088403 28026 teacher.cpp:184] === XWorld3DNavTargetNear === I0905 14:01:35.088409 28026 teacher.cpp:184] === XWorld3DNavTarget === I0905 14:01:35.088414 28026 teacher.cpp:184] === XWorld3DNavTargetBetween === I0905 14:01:35.088420 28026 teacher.cpp:184] === XWorld3DNavTargetDirection === I0905 14:01:35.088428 28026 test_xworld3d.cpp:60] total reward -1 WorldImpl destructor
So is this normal??
Yes, it means the example runs successfully.
By default, show_screen
is turned off. You can turn it on here,
Thank you for your patience. It has been successfully run :)
OK when I run ./test_xworld3d.sh I got: ERROR::SHADER::COMPILATION_FAILED: simple_texturing.vert.glsl
ERROR::SHADER::PROGRAM::LINKING_FAILED ERROR::SHADER::PROGRAM::LINKING_FAILED
I find it seems like to be a .glsl file loading error,but How Can I Fix It????
Thanks