Python-WebM
===========

The python-webm package is an interface to the Google WebM new video/image codec
which promise a better compression of image and video data.
The interface uses ctypes to call the libvpx/libwebm Google libraries installed
in the system.
At the moment only the libwebm library is wrapped and with some limitations.


Platforms
---------

Here a list of platforms with the current support status of the python-webm
package:

* Windows: SUPPORTED
* Ubuntu: SUPPORTED
* Mac OS X: SUPPORTED


Prerequisites
-------------

Below a list of prerequisites to use the python-webm package:

* Python 2.6.5+ (http://www.python.org)
* Python nose (http://code.google.com/p/python-nose)
* libwebp from sources (http://www.webmproject.org/code/#webp-repositories) or
  binary distribution for the target OS
* Python PIL (http://www.pythonware.com/products/pil)

If you are installing the WebP library by sources remember to compile and
install libwebp after libvpx. To compile and/or install every library following
the instructions shipped within.


Usage
-----

Decode and encode functions are defined int the respective webm.decode and
web.encode modules.

Functions to convert YUV images to RGB[A]/BGR[A] are available in the webm.yuv
module. At the moment the result image is in greyscale format due to a
uncompleted conversion algorithm.


Unit testing
------------

To run the unit tests you must first install the Python nose package from the
official web site http://code.google.com/p/python-nose or from PyPI (preferred)
by running:

  $ easy_install nose

Nose is a very helpful library to discover, manage and run unit tests. If you
are lazy and you want to run the tests immediately just run:

  $ nosetests -s -x

to discover and run the unit tests, without capturing the stdout (-s) and
stopping the tests at the first fail or error (-x).
