[x264-devel] About meory space for padding border

Jason Garrett-Glaser jason at x264.com
Sat Jan 22 22:12:41 CET 2011


On Wed, Jan 19, 2011 at 5:49 AM, r z <adv992009 at googlemail.com> wrote:
> Hi,
> I am new to x264 code and studying it. Could anyone tell me why the padding
> border needs to be doubled when interlaced flag is set?
> in x264_frame_new(),
>  int i_padv = PADV << h->param.b_interlaced;
>
> As far as I understand,  the padv is the vertical height in pixels for
> padding border at top/bottom, padh is the horizontal width in pixels for
> padding border at left/right.
> so the start postion of the original pixel of one frame is, buffer_addr +
> stride*padv+padh, as the code in the x264 source.
> Alex

If an MV is 16 pixels off the field (vertically) in interlaced mode,
it's actually 32 pixels off the frame.

Jason


More information about the x264-devel mailing list