Can't seem to display anything

Started by
1 comment, last by Xycaleth 9 years, 8 months ago

Hello! I've recently moved my programming environment to a new PC, and the code I was working on before seems to have stopped rendering much of anything. All it seems to render now is a single, white point in the center of the screen. I'm using the Win32 API instead of a windowing library, so it's very possible that I forgot something somewhere in the code (or perhaps my archiving software decided to rollback a .cpp file).

[redacted]

Advertisement

How simple a fix this was...

Apparently, when using commas to separate the elements in the array of strings representing the shader source, the shaders don't actually compile (even though glGetShaderiv(foo) says it does). That was a waste of time.

Apparently, when using commas to separate the elements in the array of strings representing the shader source, the shaders don't actually compile (even though glGetShaderiv(foo) says it does). That was a waste of time.

You need to provide the correct count to glShaderSource :) The second argument is the number of elements (strings) you have in your string array.

This topic is closed to new replies.

Advertisement