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

Re: [pygame] pgreloaded status update



Marcus von Appen skrev 2010-02-12 23:49:
On, Wed Feb 10, 2010, Bo Jangeborg wrote:

I have a need for memory compression so I figured that rwops might be
used to preload pictures and sounds without unpacking them. Am I
barking up the wrong tree ? If not are there any documentation on how
to use it ?
You can use the RWops C API or stream wrapper C API to implement a
preloading system. Both offer no pythonic interfaces though, so you
have to implement your own C extension module. The APIs themselves are
documented (type 'make doc' to build the html documentation under
doc/html), but do not provide any indepth examples.

Is that SDL source or pygame2 ?
Doing a quick search through the sources, you can find different
examples for how to use them (CPyStreamWrapper is used within
pygame2.freetype, the SDL RWops can be found in the rwops.c code and in
various parts of pygame2.sdl).

Do not hesitate to ask, if you're stuck with anything :-).

Regards
Marcus
Ah , I suppose I have to get started with C. Was hoping to avoid that.
Any recommendations for a compiler to get started with ? I am targeting Windows, Apple and Linux.

Bo)