Re: [PyOpenGL-Users] Code doesn't run on amd/ati hardware
Brought to you by:
mcfletch
From: Mike C. F. <mcf...@vr...> - 2013-01-15 15:10:15
|
On 13-01-14 05:44 PM, Ian Mallett wrote: > Hey, > > I had exactly this same problem some years ago. The solution for me > was to replace: > glShaderSource(self.fragmentShaderId, self.fragmentShader120) > . . . with: > glShaderSource(self.fragmentShaderId, [self.fragmentShader120]) Weird, I thought I'd fixed that ages ago. The wrapper is *supposed* to look at the source and say "is this a string or unicode? then wrap it with a list"... Maybe I dreamed I fixed it... ah... the low-level wrapper would only convert 8-bit strings into arrays-of-objects, any chance these were unicode strings? The higher-level wrapper (OpenGL.GL.shaders.compileShader) *does* do the conversions for Unicode, but the low-level stuff was checking just for bytes. Anyway, wrapping with a list should be fine, as it's what the API actually expects. Thanks for pointing out the error, Mike -- ________________________________________________ Mike C. Fletcher Designer, VR Plumber, Coder http://www.vrplumber.com http://blog.vrplumber.com |