Yes, exactly, it's a MBP about a yeard old, and yes
running vista x64 ultimate on it.
I call this function in every update step (fps=60).
So the code does render nice, and it's after that it's stopped
a few mintues (seconds) later video memory gets corrupt.
Some more details :

def init():
    glEnable(GL_BLEND)
    glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA)
    glDepthFunc(GL_LEQUAL)
    glEnable(GL_COLOR_MATERIAL)
    glShadeModel(GL_SMOOTH

The rest of the code is already commented out, so the problem
must be around here.
Strange, this is the first time pyglet caused any problems,
so it *must* be related to texture mapping.
Sprites, fonts, animation was all ok. (and lights too)

On Feb 13, 1:52 pm, Tristam MacDonald <[email protected]> wrote:
> 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 MacDonaldhttp://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