Python Multimedia


Python Multimedia
eBook: $26.99
Formats: PDF, PacktLib, ePub and Mobi formats
$22.94
save 15%!
Print + free eBook + free PacktLib access to the book: $71.98    Print cover: $44.99
$44.99
save 37%!
Free Shipping!
UK, US, Europe and selected countries in Asia.
Also available on:
Overview
Table of Contents
Author
Support
Sample Chapters
  • Use Python Imaging Library for digital image processing.
  • Create exciting 2D cartoon characters using Pyglet multimedia framework
  • Create GUI-based audio and video players using QT Phonon framework.
  • Get to grips with the primer on GStreamer multimedia framework and use this API for audio and video processing.

 

Book Details

Language : English
Paperback : 292 pages [ 235mm x 191mm ]
Release Date : August 2010
ISBN : 1849510164
ISBN 13 : 9781849510165
Author(s) : Ninad Sathaye
Topics and Technologies : All Books, Other, Beginner's Guides, Open Source, Python


Table of Contents

Preface
Chapter 1: Python and Multimedia
Chapter 2: Working with Images
Chapter 3: Enhancing Images
Chapter 4: Fun with Animations
Chapter 5: Working with Audios
Chapter 6: Audio Controls and Effects
Chapter 7: Working with Videos
Chapter 8: GUI-based Media Players Using QT Phonon
Index
  • Chapter 1: Python and Multimedia
    • Multimedia
    • Multimedia processing
      • Image processing
      • Audio and video processing
        • Compression
        • Mixing
        • Editing
      • Animations
    • Built-in multimedia support
      • winsound
      • audioop
      • wave
    • External multimedia libraries and frameworks
      • Python Imaging Library
      • PyMedia
      • GStreamer
      • Pyglet
      • PyGame
        • Sprite
        • Display
        • Surface
        • Draw
        • Event
        • Image
        • Music
    • Time for action – a simple application using PyGame
      • QT Phonon
      • Other multimedia libraries
        • Snack Sound Toolkit
        • PyAudiere
    • Summary
  • Chapter 2: Working with Images
    • Installation prerequisites
      • Python
        • Windows platform
        • Other platforms
      • Python Imaging Library (PIL)
        • Windows platform
        • Other platforms
      • PyQt4
        • Windows platform
        • Other platforms
      • Summary of installation prerequisites
    • Reading and writing images
    • Time for action – image file converter
      • Creating an image from scratch
    • Time for action – creating a new image containing some text
      • Reading images from archive
    • Time for action – reading images from archives
    • Basic image manipulations
      • Resizing
    • Time for action – resizing
      • Rotating
    • Time for action – rotating
      • Flipping
    • Time for action – flipping
      • Capturing screenshots
    • Time for action – capture screenshots at intervals
      • Cropping
    • Time for action – cropping an image
      • Pasting
    • Time for action – pasting: mirror the smiley face!
    • Project: Thumbnail Maker
    • Time for action – play with Thumbnail Maker application
      • Generating the UI code
    • Time for action – generating the UI code
      • Connecting the widgets
    • Time for action – connecting the widgets
      • Developing the image processing code
    • Time for action – developing image processing code
    • Summary
  • Chapter 3: Enhancing Images
    • Installation and download prerequisites
    • Adjusting brightness and contrast
    • Time for action – adjusting brightness and contrast
    • Tweaking colors
    • Time for action – swap colors within an image!
      • Changing individual image band
    • Time for action – change the color of a flower
      • Gray scale images
      • Cook up negatives
    • Blending
    • Time for action – blending two images
    • Creating transparent images
    • Time for action – create transparency
    • Making composites with image mask
    • Time for action – making composites with image mask
    • Project: Watermark Maker Tool
    • Time for action – Watermark Maker Tool
    • Applying image filters
      • Smoothing
    • Time for action – smoothing an image
      • Sharpening
      • Blurring
      • Edge detection and enhancements
    • Time for action – detecting and enhancing edges
      • Embossing
    • Time for action – embossing
    • Adding a border
    • Time for action – enclosing a picture in a photoframe
    • Summary
  • Chapter 4: Fun with Animations
    • Installation prerequisites
      • Pyglet
        • Windows platform
        • Other platforms
      • Summary of installation prerequisites
      • Testing the installation
    • A primer on Pyglet
      • Important components
        • Window
        • Image
        • Sprite
        • Animation
        • AnimationFrame
        • Clock
      • Displaying an image
      • Mouse and keyboard controls
      • Adding sound effects
    • Animations with Pyglet
      • Viewing an existing animation
    • Time for action – viewing an existing animation
      • Animation using a sequence of images
    • Time for action – animation using a sequence of images
      • Single image animation
    • Time for action – bouncing ball animation
      • Project: a simple bowling animation
    • Time for action – a simple bowling animation
      • Animations using different image regions
    • Time for action – raindrops animation
    • Project: drive on a rainy day!
    • Time for action – drive on a rainy day!
    • Summary
  • Chapter 5: Working with Audios
    • Installation prerequisites
      • GStreamer
        • Windows platform
        • Other platforms
      • PyGobject
        • Windows platform
        • Other platforms
      • Summary of installation prerequisites
      • Testing the installation
    • A primer on GStreamer
      • gst-inspect and gst-launch
      • Elements and pipeline
      • Plugins
      • Bins
      • Pads
        • Dynamic pads
        • Ghost pads
      • Caps
      • Bus
      • Playbin/Playbin2
    • Playing music
    • Time for action – playing an audio: method 1
      • Building a pipeline from elements
    • Time for action – playing an audio: method 2
      • Playing an audio from a website
    • Converting audio file format
    • Time for action – audio file format converter
    • Extracting part of an audio
      • The Gnonlin plugin
    • Time for action – MP3 cutter!
    • Recording
    • Time for action – recording
    • Summary
  • Chapter 6: Audio Controls and Effects
    • Controlling playback
      • Play
      • Pause/resume
    • Time for action – pause and resume a playing audio stream
      • Stop
      • Fast-forward/rewind
      • Project: extract audio using playback controls
    • Time for action – MP3 cutter from basic principles
    • Adjusting volume
    • Time for action – adjusting volume
    • Audio effects
      • Fading effects
    • Time for action – fading effects
      • Echo echo echo...
    • Time for action – adding echo effect
      • Panning/panorama
    • Project: combining audio clips
      • Media 'timeline' explained
    • Time for action – creating custom audio by combining clips
    • Audio mixing
    • Time for action – mixing audio tracks
    • Visualizing an audio track
    • Time for action – audio visualizer
    • Summary
  • Chapter 7: Working with Videos
    • Installation prerequisites
    • Playing a video
    • Time for action – video player!
      • Playing video using 'playbin'
    • Video format conversion
    • Time for action – video format converter
    • Video manipulations and effects
      • Resizing
    • Time for action – resize a video
      • Cropping
    • Time for action – crop a video
      • Adjusting brightness and contrast
      • Creating a gray scale video
    • Adding text and time on a video stream
    • Time for action – overlay text on a video track
    • Separating audio and video tracks
    • Time for action – audio and video tracks
    • Mixing audio and video tracks
    • Time for action – audio/video track mixer
    • Saving video frames as images
    • Time for action – saving video frames as images
    • Summary
  • Chapter 8: GUI-based Media Players Using QT Phonon
    • Installation prerequisites
      • PyQt4
      • Summary of installation prerequisites
    • Introduction to QT Phonon
      • Main components
        • Media graph
        • Media object
        • Sink
        • Path
        • Effects
      • Backends
      • Modules
        • MediaNode
        • MediaSource
        • MediaObject
        • Path
        • AudioOutput
        • Effect
        • VideoPlayer
        • SeekSlider
        • volumeSlider
    • Project: GUI-based music player
      • GUI elements in the music player
      • Generating the UI code
    • Time for action – generating the UI code
      • Connecting the widgets
    • Time for action – connecting the widgets
      • Developing the audio player code
    • Time for action – developing the audio player code
    • Project: GUI-based video player
      • Generating the UI code
    • Time for action – generating the UI code
      • Connecting the widgets
      • Developing the video player code
    • Time for action – developing the video player code
    • Summary

Ninad Sathaye

Ninad has more than 6 years of experience in software design and development. He is currently working at IBM India. Prior to IBM, he was a Systems Programmer at Nanorex Inc. based in Michigan, USA. At Nanorex, he was involved in the development of an open source, interactive 3D CAD software, written in Python and C. This is where he developed his passion for the Python programming language. Besides programming, his favorite hobbies are reading and traveling. Ninad holds a Master's of Science degree in Mechanical Engineering from Kansas State University, USA.

Sorry, we don't have any reviews for this title yet.

Code Downloads

Download the code and support files for this book.


Submit Errata

Please let us know if you have found any errors not listed on this list by completing our errata submission form. Our editors will check them and add them to this list. Thank you.


Errata

- 1 submitted: last submission 12 Nov 2013

Errata type: Code | Page number: 22

The command "$sudo apt-get python2.6" should be "sudo apt-get install python2.6"

 

Sample chapters

You can view our sample chapters and prefaces of this title on PacktLib or download sample chapters in PDF format.

Frequently bought together

Python Multimedia +    OpenGL 4.0 Shading Language Cookbook =
50% Off
the second eBook
Price for both: £24.65

Buy both these recommended eBooks together and get 50% off the cheapest eBook.

What you will learn from this book

  • How to develop utilities for some frequently needed image processing operations such as resizing, brightness and contrast adjustment, flipping and rotating images, and so on.
  • How to digitally enhance images using image filters.
  • How to blend images together, creating watermarks, thumbnails, and so on.
  • How to write audio and video file format conversion utilities.
  • How to combine two or more audio tracks, 'mixing' audio and video tracks.
  • How to develop an 'MP3 file cutter tool' to extract a portion of audio.
  • How to separate audio and video tracks.
  • How to develop programs to record sound, 'visualize' audio tracks, add special audio effects such as fading , echo, and so on.
  • How to save video frames as still images.

 

In Detail

Multimedia applications are used by a range of industries to enhance the visual appeal of a product. This book will teach the reader how to perform multimedia processing using Python.

This step-by-step guide gives you hands-on experience for developing exciting multimedia applications using Python. This book will help you to build applications for processing images, creating 2D animations and processing audio and video.

Writing applications that work with images, videos, and other sensory effects is great. Not every application gets to make full use of audio/visual effects, but a certain amount of multimedia makes any application a lot more appealing. There are numerous multimedia libraries for which Python bindings are available. These libraries enable working with different kinds of media, such as images, audio, video, games, and so on. This book introduces the reader to the most widely used open source libraries through several exciting, real world projects. Popular multimedia frameworks and libraries such as GStreamer,Pyglet, QT Phonon, and Python Imaging library are used to develop various multimedia applications.

Learn how to develop Multimedia applications using Python with this practical step-by-step guide

Approach

A practical guide, this book provides step-by-step instructions for developing multimedia applications, showcasing real world examples throughout.

Who this book is for

This book is for Python developers who want to dip their toes into working with images, animations, audio and video processing using Python.

Code Download and Errata
Packt Anytime, Anywhere
Register Books
Print Upgrades
eBook Downloads
Video Support
Contact Us
Awards Voting Nominations Previous Winners
Judges Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software
Resources
Open Source CMS Hall Of Fame CMS Most Promising Open Source Project Open Source E-Commerce Applications Open Source JavaScript Library Open Source Graphics Software