Home

Advertisement

Customize
maikmerten
The current state of the Wikipedia article on Theora states:

Playback performance

Currently, there is no mainstream hardware acceleration support for Theora. Consequently, playback performance, especially on lower-end systems (such as netbooks) lacks in comparison to competing formats, such as MPEG-4.

 
I'd like to point out that

  • Theora has lower computational complexity than H.264, thus the need for hardware acceleration may not be as dire
  • Current netbooks usually have no H.264 acceleration at all due to Intel's choice of hardware components, meaning the computational complexity of H.264 directly impacts on those poor little machines
  • Many software players don't use hardware acceleration even where available

"Hardware" acceleration is a much hotter topic in the realm of digital media players or mobile phones than it is in the "usual" computing environment. From what I understand work to optimize Theora for mobile applications has begun.
 
 
maikmerten
19 November 2008 @ 09:20 pm
(updated again to reflect recent changes)

I have frequently been asked where to get that nice litte Ogg Theora/Vorbis streaming applet. Well, the version I'm working on used to be its source hosted in the Wikimedia SVN, but development recently was moved to http://git.xiph.org/?p=cortado.git and there's a prototype project page at http://www.theora.org/cortado/

A signed binary for Cortado is available at http://www.theora.org/cortado.jar - this one should always be rather recent.
 
 
maikmerten
20 September 2008 @ 01:14 pm
By now I patched Wikimedia's Cortado/jheora fork to play back any valid Theora bitstream with 4:2:0 subsampling. This is mostly a matter of properly consuming bits from the bitstream used for non-VP3 features (e.g. per-block qi indices).

Also, I hardened jheora and the jst-component using jheora to not simply stop playback whenever an exception occurs within the decoder. Upon losing sync of the bitstream (e.g. when the bitstream is damaged) corrupted values may end up getting used as array indices later on - which of course usually lead to an ArrayOutOfBoundsException. The decoder now catches all exceptions and returns appropriate error codes (well, in fact just BADPACKET). The playback component can then decide to continue (the next packet may be fine anyway) or not. The new default behaviour is to just continue decoding. I tested this "error recovery" by randomly consuming bits in the decoder during various stages of decoding, thus wrecking the bitstream on purpose. This results in colorful block-storms and all imaginable sorts of corruption - but playback won't stop, which I consider a much better behavior than just giving up.


Anyway: Thusnelda, the Java world is prepared for you, so don't hesitate to replace the old encoder! ;-)
Tags: , , ,
 
 
maikmerten
20 August 2008 @ 10:38 am
As many of you know there's a Java applet ("Cortado") for playback of Ogg audio and video which originally was developed at Fluendo. Wikimedia is perhaps the best known "customer" of this applet and they since have forked it ( http://svn.wikimedia.org/viewvc/mediawiki/trunk/cortado/ ) as apparently Fluendo isn't really doing active development on Cortado anymore.

The Java Theora decoder used in Cortado is called "jheora". It is a ported version of an old C reference decoder, meaning it doesn't support the whole Theora 1.0 specification. This means that it won't decode Theora-streams created by "advanced" encoders like Monty's "Thusnelda" encoder.

Thusnelda is most likely going to become the new reference encoder, so we have a problem here.

I had a look into many options to somehow get an updated Java Theora decoder (e.g. port the new C reference decoder, which supports the complete Theora specification), but in the end I decided that just tacking missing Theora features onto the old jheora decoder may actually be the quickest way to get a robust decoder.

I'm positive that this may be the way to go and I was able to write a (biggish) patch to enable jheora to correctly decode Thusnelda streams: https://bugzilla.wikimedia.org/show_bug.cgi?id=15119

This patch is basically a complete rewrite of how quantization matrices are computed (interpolation, scaling etc. etc.) and implements proper handling of 4MV for partially coded macroblocks.

Still missing from jheora, but currently not used by any relevant encoder:


  • support for subsampling other than 4:2:0 (personally I think that this isn't relevant for web-video, but it may be a nice-to-have).

  • support for per-block quantizers. The patch already doing some decoding related to that (decode what quantizers are used within a frame) and it "just" needs finishing (decode what block is using what quantizer). Should be pretty straightforward to implement and debug once I have a fittingly encoded file.



To put it into a nutshell: jheora isn't completely unmaintained anymore ;-)

With an updated Cortado applet it should be pretty easy to bring HTML5 video (and audio) support to browsers not supporting Ogg codecs (e.g. Apple is shipping Java by default on OS X, so we can enable Ogg Theora/Vorbis playback with a tiny bit of JavaScript embedding the Cortado-applet instead).
Tags: , , ,
 
 
 
 

Advertisement

Customize