===============================================================================
Copyright (c) On2 Technologies Inc. All Rights Reserved.
-------------------------------------------------------------------------------
File: $Workfile: README.samples$
$Revision: 6$
Last Update: $DateUTC: 2007-09-11 21:10:21Z$
-------------------------------------------------------------------------------
Flix Engine Samples README
===============================================================================
[Overview]
The flix engine consists of two main parts:
- the rpc server/encoding daemon (flixd)
- the rpc client library (libflixengine2.so).
The samples use libflixengine2.so to start encoding sessions on the server.
Language extensions are used to enable support for java, php, perl and python.
These consist of a wrapper .so that calls into libflixengine2.so.
===============================================================================
[Tree structure]
flixsamples/
c/
java/
perl/
php/
python/
===============================================================================
[Sample overview]
c/
cli_encode.c - c command line example
usage: cli_encode <infile> <outfile>
One of the simplest examples for testing your installation.
See c/README for build instructions.
java/
cli_encode.java - java command line example
usage: java cli_encode <infile> <outfile>
NOTE: You must build and install the java bindings
before building and running this example. After install the
necessary files should be in your classpath. Compilation can
be accomplished by running 'javac cli_encode.java'
perl/
NOTE: You must build and install the perl module before running these
examples.
The CGI examples require the CGI perl module be installed. You can run:
$ perl -e 'use CGI;'
to verify you have this module. If you do not, it can be downloaded
from CPAN (http://cpan.org).
cli_encode.pl - perl command line example
usage: cli_encode.pl <infile> <outfile>
flix2_sample.cgi
process_sample.cgi - slightly more involved cgi example that browses for
uploaded files and allows the user to set most of the
engine's options with the corresponding API call. These
are separated into sections that map to the engine's
include files. To use this example navigate to
flix2_sample.cgi in your web browser, select a file from
the list (by default the script looks for files in
/var/www/cgi-bin/flixmedia/in), set any of the desired
options and click submit. The selected options are
submitted to process_sample.cgi, the default location for
the output file is /var/www/cgi-bin/flixmedia/out.
php/
NOTE: You must build and install the php extension before running
these examples
cli_encode.php - php command line example similar to the java and perl
examples described above.
flix2_sample.php
process_sample.php - php cgi example similar to the perl example.
python/
NOTE: You must build and install the python extension before running
these examples
cli_encode.py - python command line example similar to the java and perl
examples described above
flix2_sample.py
process_sample.py - python cgi example similar to the perl example.
===============================================================================
[Building the language bindings]
If you did not have the proper prerequisites or chose not to build the
extensions at install time, you can attempt to build and install them by
running the compile scripts that are installed by default in
/usr/local/flixmodules. Depending on your distribution/current setup you may
have to download and install the proper development packages before the
language bindings will compile. See your distribution's documentation for more
information.