I'm baffled. I bought an ATI card, and glCreateProgramObjectARB() always returns zero, yet other shader applications work fine. I have no idea what could be wrong, but this is holding up my engine. The error is easily reproduced in BlitzMax:
http://blitzmax.com/Community/posts.php?topic=53895
Ok dumb question. Is zero the same as NULL in this case?
Anyway. This on web. (I dont understand it, so may be useful)
if it's a fragment shader, it must actually set gl_FragColor or discard the pixel. If it's a vertex shader, it must set the gl_Position at least.
Does GLGetError() return anything?
glGetError() returns zero.
I'm not even compiling a shader or anything. I'm just creating the program object.
Probably a stupid question, but you're not calling it in a GLBegin.. GLEnd pair, are you?
Ah ha...
The functions actually returns something like -214654612, not 0. This has to do with the value being an unsigned integer!
hahahahaha
Oh it makes me smile when people who know what they are doing still make the sort of stupid mistake that I make ;)
To my credit, I was using someone else's glsl code. :D
Gah, now I am dealing with the limited number of variables and instructions...GLSL is the most jury-rigged system I have ever dealt with.