[MPlayer-dev-eng] encoding to huffyuv

Marian Jancar mjanx123 at milada.troja.mff.cuni.cz
Sun Jun 30 13:08:23 CEST 2002


On Sat, 29 Jun 2002 13:52:46 -0500
"Billy Biggs" <vektor at dumbterm.net> wrote:

>   An alternative, I wrote a simple huffyuv-style compression codec for

I also wrote something similar, using mmx to compute the (intraframe) deltas and to replace them with Huffman codes Im able to compress full PAL in about 80% cpu time of K6-2 350, unfortunately the remaining 20% isnt enough to save the data to the disk without drops. The limitig factor is memory speed i guess, bt848 writes 20MB/s, I need to read 20MB/s 2 times - curent and previous filed, write 10MB/s huffman codes and then read them by hdd controler, the required 80MB/s total is probably too much. Better compression (or better computer, i know) could help here.

>   It's really simple, and I use the same code for chroma as for luma
> (silly), but it gives good results and I was using it in a v4l recorder

What do you suggest? Or you meant Huffman codes? I tried also compute own Huffman table for each stored frame but it helped only few % and the difference was lower with higher resolution.

> app I've been writing (www.sf.net/projects/reetpvr).  It would be pretty
> easy I bet to throw it in mplayer.  The code is straight C and only
> depends on inttypes.h :)

Actualy mencoder handles v4l input an inefficient way, I cant save 384x288 stream without drops using mnecoder while using streamer from xawtv I can save 768x288 with fewer drops. I will add the losless compression to steamer and the support to read it to mplayer, this is probably the easiest way achieve my goal. I will develop own simple format based on advices and experince from anyone capable, as the huffyuv sources contain assembler in a Microsoft format, which I dont want to rewrite by hand and dont know any convertor to at least nasm.

Marian



More information about the MPlayer-dev-eng mailing list