[FFmpeg-devel] [PATCH] adding xavs encoding support

Stefan Gehrer stefan.gehrer
Thu Jul 22 20:21:13 CEST 2010


On 07/22/2010 04:24 PM, jianwen chen wrote:
> On Thu, Jul 22, 2010 at 1:59 AM, Stefan Gehrer<stefan.gehrer at gmx.de>  wrote:
>> libavcodec/libxavs.c in your patch calls a function
>> xavs_param_default(), which was removed from xavs.h with revision 20.
>> According to
>>
>> http://xavs.svn.sourceforge.net/viewvc/xavs/trunk/xavs.h?r1=13&r2=20
>>
>> this was six months ago.
>>
>> Re-adding the line
>>
>> void xavs_param_default( xavs_param_t * );
>>
>> to xavs.h fixes this.
>> If I do this manually I can compile, but when I try to encode I get
>> segmentation faults in xavs_encoder_encode() without a usable
>> backtrace. Command line I used:
>>
>> ffmpeg -s cif -i foreman.yuv -vcodec libxavs out.avi
>>
>> Could you please check?
>>
>>     Dear Stefan,
>
>     Thanks for point out the mistakes. Now the bugs of xavs are fixed.
>     The xavs version which I used is ok:)
>      Please check out the latest version xavs code
>      svn co https://xavs.svn.sourceforge.net/svnroot/xavs/trunk xavs
>
>      And the ffmpeg patch is no problem and the latest is in the previous
> mail,
>      patch-ffmpeg-svn-r24248-for-libxavs-update5.patch1
>
>      And it works well now.

I can confirm that the build works now, and that I can basically encode.
The encoded stream can be decoded with the ffmpeg-decoder, which makes
me happy.

Just two smaller things:
- At the end of encoding, I get a "Video encoding failed" message,
it seems the last call to encode_frame returns an error
- You pass CODEC_FLAG_PSNR to the library, but even if it is specified
there is no output of PSNR values. Could you please add it to the
library or if the wrapper has access to the reconstructed frames you
could also do it there, see mpegvideo_enc.c for an example.
That would help testing a lot.

Stefan



More information about the ffmpeg-devel mailing list