I’m a beginner programming in OpenGL. I need to create a POB (pixel Object Buffer), at time of compilation it has no errors, but at time of execution it presents a segmentation failure, my code is:
unsigned int width = 256;
unsigned int height = 256;
unsigned int size=widthheight4*sizeof(float);
GLuint vbo;
First thing to do is to set a breakpoint at your first printf and check that glGenBuffers is non-zero. You can also check “if (GLEW_ARB_vertex_buffer_object)” to make sure that your 3D card actually does support VBOs (which is what you are creating here).