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

Re: [pygame] image.load() -->> array?





On 10/25/07, Ian Mallett <geometrian@xxxxxxxxx> wrote:
On a not unrelated note, I've been trying to make a 3D map viewer that
loads height values from a black/grey/white image.  I've been making
it a surface, and using surface.get_at() for each pixel.  I think
surfarray should do it better, though I've never used it.


Pygame seems quite flexible that way. Perhaps if you could construct the
landscape of the map as a n-dimensional surfarray, you would be able to
avoid creating too many surfaces. Since the final image -the 3D viewer -
may have only two dimensions. It could be any kind of screen or surface.

I don't know that much about what I'm saying, though!















--
-------    -.-
1/f   )))  --.
-------    ...
http://www.algomantra.com