[MPlayer-dev-eng] Re: [PATCH] Fix to make zoran output work

Karolina Lindqvist karolina.lindqvist at kramnet.se
Thu Sep 14 19:42:52 CEST 2006


söndag 03 september 2006 14:17 skrev rsnel at cube.dyndns.org:

> I actually considered depreciating zr in favor of zr2; the design is much
> cleaner (no more -zr* commandline options, no jpeg_enc.c lingering
> in libvo/...). Are your speedups applicable to zr2?
>
> > No patches. Possible later when I feel that everything is working, and is
> > providing a significant upgrade.
>
> Anything that improves zr and/or zr2 is welcome. Please also CC: my home
> address when you send a patch, so that I will react sooner.

There is quiete a lot of changes to the zoran driver right now. 
This is what I have done:
OSD (enhanced, and bugs fixed)
MMX optimizations

jpeg_enc.c retried.  zr now uses the jpeg_enc in the zrjpeg filter. The MMX 
optimizations are moved to there. jpeg_enc now only accepts YV12, that 
zrmjpeg requires, and YUV422, that the zr driver use as internal format. So 
it is optimized for those special cases. Decimation is now done when storing 
into the internal format, instead of in jpeg_enc. (Moving less pixels, gives 
speed increase).

the -zrXXX options are retired and the zr driver now have zr:opt... options 
(actually both type of options are there right now. The -zr options CAN be 
retired)

Since zr is using YUV422P as internal format, that is also accepted now. YV12 
and YUY2 are converted when storing. 

Then other small changes, like draw_frame retried in favour of the new format 
draw, etc. The biggest work was changing the inner frame storage routines, 
that simplified jpeg_enc and also things like OSD etc.

Speed improvement varies between 10 and 30%. I think there was a buffer 
starvation problem before, which caused the zr driver to stall and then drop 
frames. I increased the number of buffers to 4, which appears to help with 
that. But here I am not exactly sure how many buffers are needed. Maybe some 
further investigation is needed there.

The patch file for just vo_zr.c is over 1600 lines. And it also contains some 
whitespace changes and comments. I really don't know how to do the feat of 
removing all white space changes, since of course white-space and comments 
should be kept for the new code, while being removed for the old. sic.
I am not particularly eager to remove white-space changes for old code, since 
that might introduce new bugs, or is there some trick to it?

I continue to fix things every day, so this is "work in progress".

Well, bye for Now
Karolina








More information about the MPlayer-dev-eng mailing list