Thanks, I had seen your website and your GLSL wrapper in previous googling. 
However I could not get it to work.
I tried it again with renewed enthusiasm but I'm a bit stuck.

I've converted it from 2to3, both the shader and the game of life example. 
I then converted line 17 of game of life to an integer for the window 
dimensions and added ctypes import to the shader wrapper.
Now this line in the shader wrapper: src = (c_char_p * count)(*strings)
is causing this error: TypeError: bytes or integer address expected instead 
of str instance
I think python 3 may not like this. I googled around and got reference to 
making something a byte perhaps, but I'm clearly out of my depth here.
If you have any suggestions I'd be pleased to try them out.


On Monday, September 3, 2012 10:17:09 PM UTC+10, swiftcoder wrote:
>
> Pyglet doesn't provide out-of-the-box convenience classes for working with 
> Shaders, so you'll probably want to use a 3rd-party GLSL wrapper to handle 
> that part (unless you feel like rolling your own).
>
> If you are interested, I published a light-weight set of classes and a 
> simple demonstration on my blog a while back: 
> http://swiftcoder.wordpress.com/2008/12/20/conways-game-of-life-in-glslpyglet/
>
> I don't know of any pyglet-specific tutorials, off the top of my head, but 
> someone may have some stashed away.
>
> On Mon, Sep 3, 2012 at 6:30 AM, viper <[email protected] <javascript:>>wrote:
>
>> I'd tried some time ago to learn opengl with pyglet but wound up being 
>> way out of my depth. There are a number of good, modern tutorials for c/c++ 
>> that teach opengl, such as open.gl and 
>> https://github.com/progschj/OpenGL-Examples, so I turned to c++ instead.
>>
>> I do however, prefer to work with python.
>>
>> Are there any such tutorials for pyglet? For example, does anyone have or 
>> know of some basic tutorials for python 3 pyglet that show how to use 
>> vertex and fragment shaders without requiring another library or addon and 
>> that also do not use deprecated functionality of opengl?
>>
>> Maybe this is a big ask but I see a new alpha of pyglet has been released 
>> and I have renewed interest.
>
>  
> -- 
> Tristam MacDonald
> Software Development Engineer, Amazon.com
> http://swiftcoder.wordpress.com/
>  

-- 
You received this message because you are subscribed to the Google Groups 
"pyglet-users" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/pyglet-users/-/dnIdFX4moooJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/pyglet-users?hl=en.

Reply via email to