All the tests of the line search (unoptimized and optimized)
use the exact same copypasted structure. Instead factorize this
into a test function which uses the provided function.
A 16x16 pixel block is copied to the destination pointed out by the
target motion vector. Since the motion vector is relative to the
center of the buffer, the upper bound of the range is size/2-16.
Previously we never used negative motion vectors, but there is no
reason not to test that direction. Therefore, the possible range
would be [-size/2,size/2-16]. Additionally pad this range with
INTPEL_NEEDED_MARGIN.
The block size is chosen randomly; if the block size is 16,
LineFullSearch_c will read a block with 16 pixels from kiMaxPos;
thus kiMaxPos cannot be larger than height-16, otherwise the calls
end up with reads out of bounds.
Previously, the same variable 'i' was sometimes declared within a for
loop and sometimes outside of the loop, all within the same function.
This avoids spurious warnings in MSVC 2005.
Add asm level functions
Add asm code for ME
Modify format
Add unit test for asm code.
Modify function name and format.
Remove unuse comment
Modify targets file
Add Macro protect for SSE41 funtion test
Modify according to review request.