On 7/10/2020 6:54 PM, Henrik Gramner wrote:
> On Thu, Jul 9, 2020 at 4:54 PM James Almer <jamr...@gmail.com> wrote:
>> @@ -38,7 +38,7 @@ pb_255: times 16 db 255
>>
>>  SECTION .text
>>
>> -%macro BLEND_INIT 2-3
>> +%macro BLEND_INIT 2
>>  %if ARCH_X86_64
>>  cglobal blend_%1, 6, 9, %2, top, top_linesize, bottom, bottom_linesize, 
>> dst, dst_linesize, width, end, x
>>      mov    widthd, dword widthm
> 
> Wont this change the output? width was previously doubled a few lines
> down when called with three args (%0 means "number of arguments").
> 
> The existing macro is written in a somewhat obfuscated way using the
> number of arguments as an implicit boolean flag, instead of just using
> a boolean flag directly.
> 
> Maybe it'd be better to change this macro to have 3 fixed arguments
> and use %3 instead of %0 == 3 in combination with adding a default 0
> value in the other macros with a variable number of arguments, e.g.
> "%macro BLEND_SIMPLE 2-3 0"

You're right, i had missed the %0 checks. I'm surprised the checkasm
test didn't break after this, seeing it does seemingly test 16bit.

Will send a new version that generates the same output.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".

Reply via email to