Derelict, SDL, and OpenGL3: Triangle Tribulations
DarthCthulhu via Digitalmars-d-learn
digitalmars-d-learn at puremagic.com
Tue Aug 11 23:33:37 PDT 2015
On Wednesday, 12 August 2015 at 05:26:33 UTC, JN wrote:
> You need a vertex and a fragment shader. You can't render
> anything in OGL3 without shaders.
>
I thought that was the case, but the tutorial I was looking at
didn't have any shaders at that point. I added a shader program.
> Also, you seem to be confusing Vertex Array Objects and Vertex
> Buffer Objects. You are creating a VBO and try to bind it as a
> VAO. You should put a glGenVertexArrays somewhere there.
Aha! Yes, that's it, thanks! Once I understood the difference
between VAO and VBOs, it was easy to fix. Thanks!
On Wednesday, 12 August 2015 at 05:35:30 UTC, Mike Parker wrote:
> On Wednesday, 12 August 2015 at 03:32:47 UTC, DarthCthulhu
> wrote:
>>
>> So, any ideas what I'm doing wrong?
>
> Too much to list. I suggest you get going with a good tutorial.
> One of the best I've seen is by Anton Gerdelan [1]. The four
> basic tutorials he has on his site will be enough to get you up
> and running. He used to have a lot more there, but he's
> published them all in a book. Even though there are numerous
> free resources online, I think Anton's ebook is well worth the
> ~$9.00 you pay for it. His tutorials are quite detailed and do
> a lot more than showing you a bunch of code to copy and paste.
> Work your way through that book and you'll know your way around
> well enough to do what you need to do for any basic OpenGL
> renderer.
On Wednesday, 12 August 2015 at 05:54:13 UTC, Mike Parker wrote:
> On Wednesday, 12 August 2015 at 05:35:30 UTC, Mike Parker wrote:
>
>> One of the best I've seen is by Anton Gerdelan [1]. The four
>
> [1] http://antongerdelan.net/opengl/index.html
Thanks very much for the resource! I had already looked at about
a dozen different OGL3.x tutorials online, but this was the one
which clicked for me. I'll definitely look into getting his book.
Thanks again!
More information about the Digitalmars-d-learn
mailing list