[FFmpeg-devel] [PATCH] fix H.264 decoding on big-endian

Måns Rullgård mans
Sun Feb 14 23:47:27 CET 2010


Michael Niedermayer <michaelni at gmx.at> writes:

> On Sun, Feb 14, 2010 at 09:27:32PM +0100, Reimar D?ffinger wrote:
>> On Sun, Feb 14, 2010 at 09:21:10PM +0100, Reimar D?ffinger wrote:
>> > no idea what I am doing, but this seems to work:
>> 
>> Sorry, now the same against latest SVN:
>> Index: libavcodec/h264_direct.c
>> ===================================================================
>> --- libavcodec/h264_direct.c	(revision 21824)
>> +++ libavcodec/h264_direct.c	(working copy)
>> @@ -178,8 +178,13 @@
>>  
>>              int match_count= (left_ref==ref[list]) + (top_ref==ref[list]) + (refc==ref[list]);
>>              if(match_count > 1){ //most common
>> +#if HAVE_BIGENDIAN
>> +                mv[list]= (mid_pred(A[0], B[0], C[0])<<16)
>> +                         +(mid_pred(A[1], B[1], C[1])&0xFFFF);
>> +#else
>>                  mv[list]= (mid_pred(A[0], B[0], C[0])&0xFFFF)
>>                           +(mid_pred(A[1], B[1], C[1])<<16);
>> +#endif
>
> should be pack16to32()
> and sorry for this, i would have noticed it normally but fate is so yellow
> that its hard to spot breakages.
> 1. mike should finally update the checksums of the 8 correctly changed files
>    assuming they are still correct

He's waiting for you, I think...

-- 
M?ns Rullg?rd
mans at mansr.com



More information about the ffmpeg-devel mailing list