Derelict2 openGL3 issues

2012-04-20 Thread Stephen Jones
David suggested I start a new thread rather than asking on an old existing one (probably wants to get rid of me). So what I have done is created the most parred back, hello world type program that could run under the GL3 enforcement policies dictated by Derelict2. Fixed function pipeline is out

Re: Derelict2 openGL3 issues

2012-04-21 Thread David
Am 21.04.2012 01:16, schrieb Stephen Jones: glBufferData(GL_ARRAY_BUFFER, v.length * GL_FLOAT.sizeof, &v, GL_STATIC_DRAW); Error spotted! This has to be: glBufferData(GL_ARRAY_BUFFER, v.length * float.sizeof, v.ptr, GL_STATIC_DRAW); float.sizeof is just cosmetic, the important thing

Re: Derelict2 openGL3 issues

2012-04-21 Thread David
glVertexAttribPointer(0, 4, GL_FLOAT, GL_FALSE, 0, null);//is this right casting a void pointer for 0 offset? I do it like this: cast(void*)OFFSET; e.g. cast(void*)12;

Re: Derelict2 openGL3 issues

2012-04-21 Thread Stephen Jones
On Saturday, 21 April 2012 at 11:02:51 UTC, David wrote: glVertexAttribPointer(0, 4, GL_FLOAT, GL_FALSE, 0, null);//is this right casting a void pointer for 0 offset? I do it like this: cast(void*)OFFSET; e.g. cast(void*)12; Thankyou David. Just to complete the code for those who follow: it

Re: Derelict2 openGL3 issues

2012-04-21 Thread David
Am 21.04.2012 23:49, schrieb Stephen Jones: On Saturday, 21 April 2012 at 11:02:51 UTC, David wrote: glVertexAttribPointer(0, 4, GL_FLOAT, GL_FALSE, 0, null);//is this right casting a void pointer for 0 offset? I do it like this: cast(void*)OFFSET; e.g. cast(void*)12; Thankyou David. Just to

Re: Derelict2 openGL3 issues

2012-04-24 Thread Denis Shelomovskij
One day I'll finish my OpenGL wrapper for D. It will give you better abilities in creating OpenGL 3 contexts than most C++ frameworks (SDL, GLFW etc.) and, I hope, will get rid of passing pointers to functions. It will be done soon after I'll finish Scintilla wrapper for D. And it will be don

Re: Derelict2 openGL3 issues

2012-04-30 Thread Stephen Jones
On Tuesday, 24 April 2012 at 08:45:44 UTC, Denis Shelomovskij wrote: One day I'll finish my OpenGL wrapper for D. It will give you better abilities in creating OpenGL 3 contexts than most C++ frameworks (SDL, GLFW etc.) and, I hope, will get rid of passing pointers to functions. It will be do