O'Reilly logo

Python Multimedia Beginner's Guide by Ninad Sathaye

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Time for action - MP3 cutter!

In this section we will develop a utility that will cut out a portion of an MP3 formatted audio and save it as a separate file.

  1. Keep the file AudioCutter.py handy. You can download it from the Packt website. Here we will only discuss important methods. The methods not discussed here are similar to the ones from earlier examples. Review the file AudioCutter.py which has all the necessary source code to run this application.
  2. Start the usual way. Do the necessary imports and write the following skeleton code.
    import os, sys, time import thread import gobject import pygst pygst.require("0.10") import gst class AudioCutter: def __init__(self): pass def constructPipeline(self): pass def gnonlin_pad_added(self, gnonlin_elem, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required