[x265] [PATCH] primitives: added C primitives for upShift/downShift input pixels
Derek Buitenhuis
derek.buitenhuis at gmail.com
Wed Mar 12 13:34:34 CET 2014
On 3/12/2014 8:45 AM, Steve Borho wrote:
>> > - for (int c = 0; c < width; c++)
>> > + y += lumaWidth;
>> > + Y += lumaWidth;
>> > + v += chromaWidth;
>> > + V += chromaWidth;
>> > + u += chromaWidth;
>> > + U += chromaWidth;
>
> blech. the destination buffer has loads of padding (stride is much
> wider than width), writing past the right edge is perfectly safe but
> you do need to be careful about reading beyond the input stride.
I'd just like to note that using one letter variables that differ only by case
is *insane*, and renders the code unreadable.
- Derek
More information about the x265-devel
mailing list