Saturday, April 21, 2012

Texture Generation

Well, it turns out that, as I suspected,  the source of my problems was the texture generation after all. I was using the variable GL_R instead of GL_RED when passing float data from my voxel buffer to the shader, which is meant to be used in the context of a texture coordinate rather than color. I'm a bit frustrated that it took me three days to track this bug down... At least I have this knowledge for any future OpenGL projects I might work on.

1 comment:

  1. Lack of type safety is a common problem in OpenGL. People mix up enums all the type.

    ReplyDelete