[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] no unlock: surfarray.pixels2d() and PixelArray() bug or intented?



On, Fri Jun 06, 2008, Jake b wrote:

> version: pygame '1.8.0release'
> 
> When using pygame.surfarray.pixels2d( surface ) or pygame.PixelArray(
> surface ) they both lock the screen surface, but do not unlock when done.
> 
> Is this a bug, or is it intended behavior? If so, why? It seems backwards to
> me.

They need to be released or their definition scope has to be left. As
both access the underlying pixels directly during their lifetime, an
explicit deletion of them has to be triggered.

Regards
Marcus

Attachment: pgpL9Ple5lRHI.pgp
Description: PGP signature