[FFmpeg-devel] [Fwd: Summer of code small task patch]

Dylan Yudaken dyudaken
Sun Mar 29 23:22:24 CEST 2009


Michael Niedermayer wrote:
> On Sun, Mar 29, 2009 at 05:19:43PM +0200, Dylan Yudaken wrote:
>   
>> Michael Niedermayer wrote:
>>     
>>> renaming things should be a seperate patch
>>> actually a patch should either do functional changes or non functional not
>>> both
>>>
>>>   
>>>       
>> I wasnt sure what exactly to do here or if the conversation reached a 
>> conclusion. I have included a full patch but if you need it split I guess I 
>> can go and do that - not 100% sure how though.
>>     
>
> for example:
> first patch  you replace the dct but leave the function names
> second patch you rename the functions
>   
OK, I have done this (sort of). I attached 3 files.
to use:
1: apply fdctLicenceChange.patch
2: apply fdctRename.patch1
3: put the attached dctref.c in and remove fdctref.c . I couldnt figure 
out how to generate a patch to do this.

1 is the straight replacement while 2 & 3 are the renaming.
>
>> +    for (j = 0; j < 8; ++j) {
>> +        coefficients[j] = 1;
>> +    }
>> +    for (i = 8; i < 64; i+=8) {
>> +        for (j = 0; j < 8; ++j) {
>> +            coefficients[i + j] = M_SQRT2 * cos(i * (j+0.5) * (M_PI / 64.0));
>> +        }
>> +    }
>> +
>>     
>
> the loops can be merged
>   
I think its better as is. If it was merged it would need a conditional 
statement to separate the loops, so it would be the same speed but just 
a little less neat.
If you think otherwise I'll do it.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fdctLicenceChange.patch
Type: application/mbox
Size: 9158 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090329/dc7c5c5f/attachment.bin>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: fdctRename.patch1
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090329/dc7c5c5f/attachment.asc>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: dctref.c
Type: text/x-csrc
Size: 3434 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090329/dc7c5c5f/attachment.c>



More information about the ffmpeg-devel mailing list