[x265] Custom LowRes scale

Nicolas Morey-Chaisemartin nmorey at kalray.eu
Tue Jul 22 17:15:31 CEST 2014


On 07/22/2014 04:51 PM, Steve Borho wrote:
> On 07/22, Nicolas Morey-Chaisemartin wrote:
>> Is there a clean way to get a LUMA_NNxNN value from a block size ? Should I handle block larger than 64x64 by looping on the 64x64 blocks? or simply add a check at lowres init that the fullres CU size is <= 64 ? 
> inline int partitionFromLog2Size(int log2Size);
>
> It's cleaner to not allow the lowres to downscale too much; 4k is only
> roughly twice as wide/high as HD anyway. 8k would be 4x, which would map
> nicely to 64x64 blocks.
The patch I sent uses standard filter and detects block over 64 just in case.
> Now that I think about this; the 16x16 block size of lowres is assumed
> in a few rate control routines for adaptive quant and row cost
> estimation.
I might have missed some but I think I fixed most ratecontrol and deltaQP in this patch.
Anyway as long as the value are not changed, the patch shouldn't break anything.
However it'll definitely need to be double checked by someone familiar with the code before allowing other values.

>
>>>> While we're talking about lowres MV: from what I could gather they are
>>>> not used during the motionSearch on the full res picture.  As a lot of
>>>> time is spent finding those, whouldn't it be useful to add them as
>>>> candidate in the fullres search?
>>> This has been on my TODO list for ages; a couple of people have claimed
>>> they've tried it and it hasn't helped as much as you might think.  But I
>>> haven't had a working patch in hand to verify it.
>>>
>>> The AMVP fixup after motion search, where we get to go shopping for a
>>> better MVP after the search, often makes extra motion candidates
>>> superfluous.
>>>
>> I started working on this yesterday for our accelerator but I got carried away on lowres scaling.
>> I haven't any results yet but I'll post them as soon as I have some.
>> By the way, lowres MV are in lowres luma pixels right? So I'll need to scale the vector by 2 to get the full MV?
> Yes, you would need to shift them up as many bits as you downscaled
> lowres (today it is one bit)
>
That's what I though. Thanks



More information about the x265-devel mailing list