Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(308)

Side by Side Diff: unit_test/color_test.cc

Issue 2024213003: j422 now uses j420 source code so increase error threshold to match. (Closed) Base URL: https://chromium.googlesource.com/libyuv/libyuv@master
Patch Set: bump version Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « include/libyuv/version.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2015 The LibYuv Project Authors. All rights reserved. 2 * Copyright 2015 The LibYuv Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
139 free_aligned_buffer_page_end(temp_y); \ 139 free_aligned_buffer_page_end(temp_y); \
140 free_aligned_buffer_page_end(temp_u); \ 140 free_aligned_buffer_page_end(temp_u); \
141 free_aligned_buffer_page_end(temp_v); \ 141 free_aligned_buffer_page_end(temp_v); \
142 free_aligned_buffer_page_end(dst_pixels_opt); \ 142 free_aligned_buffer_page_end(dst_pixels_opt); \
143 free_aligned_buffer_page_end(dst_pixels_c); \ 143 free_aligned_buffer_page_end(dst_pixels_c); \
144 } \ 144 } \
145 145
146 TESTCS(TestI420, I420ToARGB, ARGBToI420, 1, 2, benchmark_width_, ERROR_FULL) 146 TESTCS(TestI420, I420ToARGB, ARGBToI420, 1, 2, benchmark_width_, ERROR_FULL)
147 TESTCS(TestI422, I422ToARGB, ARGBToI422, 0, 1, 0, ERROR_FULL) 147 TESTCS(TestI422, I422ToARGB, ARGBToI422, 0, 1, 0, ERROR_FULL)
148 TESTCS(TestJ420, J420ToARGB, ARGBToJ420, 1, 2, benchmark_width_, ERROR_J420) 148 TESTCS(TestJ420, J420ToARGB, ARGBToJ420, 1, 2, benchmark_width_, ERROR_J420)
149 TESTCS(TestJ422, J422ToARGB, ARGBToJ422, 0, 1, 0, 3) 149 TESTCS(TestJ422, J422ToARGB, ARGBToJ422, 0, 1, 0, ERROR_J420)
150 150
151 static void YUVToRGB(int y, int u, int v, int* r, int* g, int* b) { 151 static void YUVToRGB(int y, int u, int v, int* r, int* g, int* b) {
152 const int kWidth = 16; 152 const int kWidth = 16;
153 const int kHeight = 1; 153 const int kHeight = 1;
154 const int kPixels = kWidth * kHeight; 154 const int kPixels = kWidth * kHeight;
155 const int kHalfPixels = ((kWidth + 1) / 2) * ((kHeight + 1) / 2); 155 const int kHalfPixels = ((kWidth + 1) / 2) * ((kHeight + 1) / 2);
156 156
157 SIMD_ALIGNED(uint8 orig_y[16]); 157 SIMD_ALIGNED(uint8 orig_y[16]);
158 SIMD_ALIGNED(uint8 orig_u[8]); 158 SIMD_ALIGNED(uint8 orig_u[8]);
159 SIMD_ALIGNED(uint8 orig_v[8]); 159 SIMD_ALIGNED(uint8 orig_v[8]);
(...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after
561 EXPECT_EQ(r0, r1); 561 EXPECT_EQ(r0, r1);
562 EXPECT_EQ(g0, g1); 562 EXPECT_EQ(g0, g1);
563 EXPECT_EQ(b0, b1); 563 EXPECT_EQ(b0, b1);
564 EXPECT_EQ(r0, r2); 564 EXPECT_EQ(r0, r2);
565 EXPECT_EQ(g0, g2); 565 EXPECT_EQ(g0, g2);
566 EXPECT_EQ(b0, b2); 566 EXPECT_EQ(b0, b2);
567 } 567 }
568 } 568 }
569 569
570 } // namespace libyuv 570 } // namespace libyuv
OLDNEW
« no previous file with comments | « include/libyuv/version.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698