diff options
author | Robert Bares <robert@bares.me> | 2018-04-15 22:47:32 +0100 |
---|---|---|
committer | Commit Bot <commit-bot@chromium.org> | 2018-04-19 02:41:27 +0000 |
commit | a8aa921c4614f9d6a0e8f3459648ca1ae75cdbe6 (patch) | |
tree | e16d06b5323d206885397ce189e9c9e0902acbb8 /AUTHORS | |
parent | 5669005fc099b569abd009353968811ef8a593a7 (diff) | |
download | libyuv-a8aa921c4614f9d6a0e8f3459648ca1ae75cdbe6.tar.gz |
Allow negative height when ConvertToI420/ARGB is called with NV12/NV21
ConvertToI420 and ConvertToARGB support the use of a negative height
parameter to flip the image vertically. When converting from NV12 or
NV21 this parameter was misinterpreted, resulting in invalid output.
This CL introduces the use of abs_src_height to correctly calculate
the location of the source UV plane.
The sign of crop_height is not used, to reduce confusion ConvertToI420
and ConvertToARGB no longer accept negative crop height.
Unit tests for Android420ToI420 are updated to fix miscalculation of
src_stride_uv, fix incorrect pixel strides, and to test inversion.
New unit tests are included to test inversion for ConvertToARGB,
ConvertToI420, Android420ToARGB, and Android420ToABGR.
For consistency the test NV12Crop is renamed ConvertToI420_NV12_Crop.
Bug: libyuv:446
Test: out/Release/libyuv_unittest --gtest_filter=*.ConvertTo*:*.Android420To*
Change-Id: Idc98e62671cb30272cfa7e24fafbc8b73712f7c6
Reviewed-on: https://chromium-review.googlesource.com/994074
Commit-Queue: Frank Barchard <fbarchard@chromium.org>
Reviewed-by: Frank Barchard <fbarchard@chromium.org>
Diffstat (limited to 'AUTHORS')
-rw-r--r-- | AUTHORS | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -1,4 +1,6 @@ # Names should be added to this file like so: # Name or Organization <email address> +Robert Bares <robert@bares.me> + Google Inc. |