On Sat, 9 May 2009 22:29:51 +0400
dmitry boyarintsev <[email protected]> wrote:
> uses
> ...gl, glext...
>
> ...
> if not Load_GL_version_2_0 then begin
> writeln('OpenGL 2.0 is not supported');
> Halt;
> end;
> ...
This does not work for me. I added it to the Init function of my render engine
(as I know that at this time I have a valid OpenGL context) to no avail. My
code keeps crashing at
this call (in a different unit, so I tried calling Load_GL_version_2_0 there
too, with the same result):
if glIsBufferARB(VertexBuffer)=GL_TRUE then (asmtypes.pas:2212)
The backtrace is not very helpfull for me:
#0 0x0000000000000000 in ?? ()
#1 0x0000000000750491 in CREATEBUFFERS (this=0x7fb7e83cd200)
at asmtypes.pas:2212
So I tried just loading the VBO extension:
if not glext_LoadExtension('GL_ARB_vertex_buffer_object') then begin
writeln('VBO is not supported');
Halt;
end;
Resulting in this:
#0 0x0000000000760a6f in GLEXT_EXTENSIONSUPPORTED (
EXTENSION=0xb39788 'GL_ARB_vertex_buffer_object',
SEARCHIN=0x7f7988ac2320 'GL_ARB_color_buffer_float GL_ARB_depth_texture
GL_ARB_draw_buffers GL_ARB_fragment_program GL_ARB_fragment_program_shadow
GL_ARB_fragment_shader GL_ARB_half_float_pixel GL_ARB_half_float_vertex
GL_ARB'...)
at gllibs/glext.pp:4268
#1 0x000000000076c7f3 in LOAD_GL_ARB_VERTEX_BUFFER_OBJECT ()
at gllibs/glext.pp:7591
#2 0x00000000007736c3 in GLEXT_LOADEXTENSION (
EXT=0xb2d788 'GL_ARB_vertex_buffer_object') at gllibs/glext.pp:9509
This is on Ubuntu 9.04 64-bit.
My card and driver support OpenGL Version 2.1.2, so that is not the problem.
Anyone any ideas?
--
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
A: Top-posting.
Q: What is the most annoying thing in e-mail?
_______________________________________________
fpc-pascal maillist - [email protected]
http://lists.freepascal.org/mailman/listinfo/fpc-pascal