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

Re: [pygame] multimedia pygame



On May 12, 2004, at 6:41 PM, enrike wrote:

Regarding MAX/MSP and PD I must say they are quite nice tools, I specially like PD since its free software. They are very nice environments for prototyping audio but also visuals (thanks to external libraries such as Jitter and GEM). They are visual programmin environments and as such its quite difficult to create big and complex proyects. But the students usually like it very much and learn a lot by using them.
You can also "drive" PD (and MAX/MSP) using pyOSC.
Actually it can be very interesting to implement part of the "patch" in python
using OSC to receive data from the PD patch and sending back some controls/events.

this is exactly what i am doing!
Actually we developed a simple API for the pyOSC implementation by Daniel Holth so that students or people that dont understand (or cannot be bothered) sockets and studff like that can use OSC in a very simple way, we are planning to release it in a few days.

We want create "controllers" for PD, Supercollider, MAX/MSP and other programs that understand OSC.

You can have a look at what we have been doing so far in.
www.ixi-software.net/content/software.html
Check out SpinOSC as this the direction we are planning to move from now on.
I did an event driven OSC implementation in Python on top of Twisted a couple years ago for a performance piece at a new media festival. Are you guys just polling? I started working on a high level game development framework, currently on top of pygame, and I'm like 80% done with a Pygame Twisted reactor. It uses the pygame clock and event sink, but does the select loop in a separate thread, which generates a pygame event and in turn iterates the reactor. In the cases where pygame events aren't necessary (most of the stuff I've done doesn't require ultra-responsive user input), I've just used the Twisted reactor to iterate pygame (reactor.callLater(delayUntilNextFrame, self.nextFrame) sort of style).
ok!. would it be possible to get the code? is it finished? We did a simple version that keeps pulling for incomming messages. We are using OSC really intensively in some of our experiments and I think we would benefit a lot from a highly optimised implementation of python OSC.
I don't even know if I still have it, it was a one-off performance piece, I don't regularly deal with OSC. I wasn't actually using it for music either, I was talking to some image recognition software written in MAX/MSP (crazy dutch people!). In any event, it probably deserves to be rewritten because Twisted's UDP support is totally different now and I'm a few years better at Python and I have some really cool ideas for how to develop binary protocols (both wire and file) that I would like to implement and experiment with. It would be a pretty good excuse.

I'm not going to have time to really even think about doing anything until next week at the earliest.. going to BSDCan tomorrow, won't be back until Monday.. and I have some friends coming in from out of town as soon as I get back so I may be a bit distracted from the regular freelance/open source development grind :)

Very recently there is a tool being developed at the MIT called Processing that allows to program in a simplified version of Java to create visuals and also sound. In many senses its a bit like pygame.
Can you send/share some link about "Processing" in order to have a look at it?

I think its someting like www.processing.net
this was an old link to the demo but it might have changed
http://proce55ing.net/download/alpha.html

Looks like they plan to release open source in the future but not at the moment.
It's been planned for a while, but never happened. It is a bit like pygame, but it uses Java syntax and mostly OpenGL sort of semantics (though it is bitmap based). Something written in pygame+Numeric+PyOpenGL could do the same thing, but probably be much nicer to use and more flexible.

this is the kind of stuff I was refering to in my first email.
i think if somebody puts together some package, or maybe some guidelines to ease the complexity of getting into all these different libraries, this would be great for many people. I was checking out PyOpenGL recently and I had the feeling that this is great and very fast but also that not being myself into 3D it was going to take me ages to be a ble to use it properly for 2D. Pygame is much more related to what I am used to, however still it lacks some things I (and many others i guess) would need, like integrating into wxpython in my particular case.
OpenGL isn't very hard to use for 2D, you really only need to figure out how to setup an orthographic projection, and how to manage textures. The NeHe tutorials probably cover that, I guess. If you're doing OpenGL with wxPython, you might as well not use pygame at all.. or at least, not for anything but sound, but even then there are better sound libraries than pygame's that you could be using.

You're just going to cause yourself pain if you want both wxPython and SDL to talk to the mouse+keyboard. Integrating multiple event loops is not for the faint of heart, and requires some pretty deep insight into how each of them works. In the 2D rapid game development framework I'm prototyping, pygame is just an implementation detail. Eventually, pygame will probably just be a fallback for when OpenGL isn't available, and the timing/event handling will probably be done per-platform (or at least, I would really like to use platform-specific stuff on OS X.. I might keep SDL for the others). I definitely want to be using something with floating point rectangles, if nothing else :)

-bob