On Fri, Feb 13, 2009 at 7:20 AM, [email protected] <
[email protected]> wrote:

>
> Ok, i know that this code has like 1o flaws, i am just
> learning pyglet-opengl, but it is *so* bad that the
> nvidia 8600MGT vga card in the notebook goes crazy,
> pixels start moving around to the extent that i have to
> restart to macbook.
>
> It actually draw what it should, but after 2-3 runs
> it will kill the pc.
>
> So i was thinking should some resources be manually
> freed in pyglet ?
> I am afraid to run this code or play around with it :)
> Just for entertainment :
>
> def draw_texture_test():
>
>    dotexture=1
>
>    if dotexture:
>        glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER,
> GL_LINEAR)
>        glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER,
> GL_LINEAR)
>        glEnable(GL_TEXTURE_2D)
>        glEnable(GL_COLOR_MATERIAL)
>        image   = pyglet.image.load(r'c:\test.png')
>        texture = image.get_texture()
>        glBindTexture(GL_TEXTURE_2D, texture.id)
>
>
>    pyglet.graphics.draw(3, pyglet.gl.GL_TRIANGLES,
>                         ('v2i', (10, 15, 800, 35, 500, 900)),
>                         ('t2f', (0, 0, 1, 1, 1, 0))
>    )
>
>    if dotexture:
>        glDisable(GL_TEXTURE_2D)
>

I take it this is a recent model MacBook, but running under Windows? The
reason I ask is that the Mac and Window's OpenGL drivers are very different,
and tend to suffer from different problems.
There doesn't seem to be anything wrong with the code you posted - certainly
not anything that should crash the driver. Any chance you could post the
whole program?

-- 
Tristam MacDonald
http://swiftcoder.wordpress.com/

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pyglet-users" group.
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