2

I am trying to generate an AVI with PyMedia by muxing together an audio and video stream. However, I can't find any examples on the web, and can't even get a simple example with a single MPEG2 video stream like this working:

from pymedia import muxer
from pymedia.video import vcodec

params = {
    'id': vcodec.getCodecID('mpeg2video'),
    'frame_rate': 10000,
    'width': 640,
    'height': 480,
    'bitrate': 1000,
    'channels': 1,
}
mux = muxer.Muxer('avi')
mux.addStream(muxer.CODEC_TYPE_VIDEO, params)
mux.start()

In Windows, this crashes Python with a generic error box "python.exe has stopped working.".

Am I doing something wrong here or is this library just broken? I realise the PyMedia project hasn't been active for a few years, but have quite a bit of old code that uses it and am hoping I don't have to port it all to another library.

del
  • 6,341
  • 10
  • 42
  • 45
  • Try code that "worked before" against the latest CVS, then try the above. If it doesn't work and you can't make any progress in an hour then give up. – wberry Sep 06 '11 at 14:10

0 Answers0