Pogg is licensed under the GNU LGPL (Lesser General Public License) which means that you can use it in proprietary software as long as you release the source code of the library (not the rest of the application) as well. You are encouraged to contribute to Pogg.
Being a pure Java library it works in Windows, Linux and Mac OS X, and you can use it in Java applets without special security permissions.
See the Examples section to see Pogg in action.
Pogg is specially designed to be used with Processing.org. Processing allows you to easily create 3D graphics and it has many libraries available to use sound, image processing, I/O, particle dynamics and many other things. Pogg is just another Processing library.
If you want to use it in a Java application, the Processing examples will help you as well. Processing in fact is a simplification of Java and all the Processing sketches are translated to Java when you compile and run them.
In Processing, the setup() method is called once to initialize all the variables and the draw() method is called every time a new frame has to be displayed.
If you want to program directly in Java, you should initialize somewhere the TheoraMovie object (the setup() in the examples). You can use the constructor without the PApplet and with the absolute path of the file:
TheoraMovie myMovie; myMovie = new TheoraMovie("c:/path/BugsShort.ogg");
Then your program should have an infinite loop that does something similar to the draw() method of the examples.
You will need to convert the “pixels” attribute to images that Java can use. The best example for that is ExtractMovieFrames.
To compile and execute your application, you have to add to the classpath the pogg.jar (which is in the download above) and the Processing core.jar (which is in the to Processing/lib folder when you install Processing). See the Processing in Eclipse tutorial for details.
For examples on how to use these methods see the Examples
There are no play(), pause() and frameRate() methods that you can find in the Processing Video library. In Pogg the video does not play by itself, you have to explicitly call read() to move forward one frame. If you want to “pause”, just stop reading. If you want a faster frame rate, you can call read() more often or change the Processing frameRate() (which will call draw() more often and it will call read()). See the AdvancedPlayer example to see how to implement all these features.
These libraries are more mature, they have native bindings (should be faster) and some of them support video capture and recording (Pogg doesn't). The main advantage of Pogg is its ability to be used in applets.
All these libraries have a Movie class with similar methods and it should be easy to interchange them.
Tags: processing.org, processing, proce55ing, Java, library, ogg, theora, jheora, video, movie, applet, vj, 3D, player