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

Side by Side Diff: include/libyuv/scale_row.h

Issue 1513183004: use rounding in scaledown by 2 (Closed) Base URL: https://chromium.googlesource.com/libyuv/libyuv@master
Patch Set: corrected version to 1554 Created 5 years 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 | « README.chromium ('k') | include/libyuv/version.h » ('j') | 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 2013 The LibYuv Project Authors. All rights reserved. 2 * Copyright 2013 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 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
49 (defined(_M_IX86) || defined(__x86_64__) || defined(__i386__)) 49 (defined(_M_IX86) || defined(__x86_64__) || defined(__i386__))
50 #define HAS_FIXEDDIV1_X86 50 #define HAS_FIXEDDIV1_X86
51 #define HAS_FIXEDDIV_X86 51 #define HAS_FIXEDDIV_X86
52 #define HAS_SCALEARGBCOLS_SSE2 52 #define HAS_SCALEARGBCOLS_SSE2
53 #define HAS_SCALEARGBCOLSUP2_SSE2 53 #define HAS_SCALEARGBCOLSUP2_SSE2
54 #define HAS_SCALEARGBFILTERCOLS_SSSE3 54 #define HAS_SCALEARGBFILTERCOLS_SSSE3
55 #define HAS_SCALEARGBROWDOWN2_SSE2 55 #define HAS_SCALEARGBROWDOWN2_SSE2
56 #define HAS_SCALEARGBROWDOWNEVEN_SSE2 56 #define HAS_SCALEARGBROWDOWNEVEN_SSE2
57 #define HAS_SCALECOLSUP2_SSE2 57 #define HAS_SCALECOLSUP2_SSE2
58 #define HAS_SCALEFILTERCOLS_SSSE3 58 #define HAS_SCALEFILTERCOLS_SSSE3
59 #define HAS_SCALEROWDOWN2_SSE2 59 #define HAS_SCALEROWDOWN2_SSSE3
60 #define HAS_SCALEROWDOWN34_SSSE3 60 #define HAS_SCALEROWDOWN34_SSSE3
61 #define HAS_SCALEROWDOWN38_SSSE3 61 #define HAS_SCALEROWDOWN38_SSSE3
62 #define HAS_SCALEROWDOWN4_SSE2 62 #define HAS_SCALEROWDOWN4_SSE2
63 #define HAS_SCALEADDROW_SSE2 63 #define HAS_SCALEADDROW_SSE2
64 #endif 64 #endif
65 65
66 // The following are available on all x86 platforms, but 66 // The following are available on all x86 platforms, but
67 // require VS2012, clang 3.4 or gcc 4.7. 67 // require VS2012, clang 3.4 or gcc 4.7.
68 // The code supports NaCL but requires a new compiler and validator. 68 // The code supports NaCL but requires a new compiler and validator.
69 #if !defined(LIBYUV_DISABLE_X86) && (defined(VISUALC_HAS_AVX2) || \ 69 #if !defined(LIBYUV_DISABLE_X86) && (defined(VISUALC_HAS_AVX2) || \
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 void ScaleARGBCols64_C(uint8* dst_argb, const uint8* src_argb, 225 void ScaleARGBCols64_C(uint8* dst_argb, const uint8* src_argb,
226 int dst_width, int x, int dx); 226 int dst_width, int x, int dx);
227 void ScaleARGBColsUp2_C(uint8* dst_argb, const uint8* src_argb, 227 void ScaleARGBColsUp2_C(uint8* dst_argb, const uint8* src_argb,
228 int dst_width, int, int); 228 int dst_width, int, int);
229 void ScaleARGBFilterCols_C(uint8* dst_argb, const uint8* src_argb, 229 void ScaleARGBFilterCols_C(uint8* dst_argb, const uint8* src_argb,
230 int dst_width, int x, int dx); 230 int dst_width, int x, int dx);
231 void ScaleARGBFilterCols64_C(uint8* dst_argb, const uint8* src_argb, 231 void ScaleARGBFilterCols64_C(uint8* dst_argb, const uint8* src_argb,
232 int dst_width, int x, int dx); 232 int dst_width, int x, int dx);
233 233
234 // Specialized scalers for x86. 234 // Specialized scalers for x86.
235 void ScaleRowDown2_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 235 void ScaleRowDown2_SSSE3(const uint8* src_ptr, ptrdiff_t src_stride,
236 uint8* dst_ptr, int dst_width); 236 uint8* dst_ptr, int dst_width);
237 void ScaleRowDown2Linear_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 237 void ScaleRowDown2Linear_SSSE3(const uint8* src_ptr, ptrdiff_t src_stride,
238 uint8* dst_ptr, int dst_width); 238 uint8* dst_ptr, int dst_width);
239 void ScaleRowDown2Box_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 239 void ScaleRowDown2Box_SSSE3(const uint8* src_ptr, ptrdiff_t src_stride,
240 uint8* dst_ptr, int dst_width); 240 uint8* dst_ptr, int dst_width);
241 void ScaleRowDown2_AVX2(const uint8* src_ptr, ptrdiff_t src_stride, 241 void ScaleRowDown2_AVX2(const uint8* src_ptr, ptrdiff_t src_stride,
242 uint8* dst_ptr, int dst_width); 242 uint8* dst_ptr, int dst_width);
243 void ScaleRowDown2Linear_AVX2(const uint8* src_ptr, ptrdiff_t src_stride, 243 void ScaleRowDown2Linear_AVX2(const uint8* src_ptr, ptrdiff_t src_stride,
244 uint8* dst_ptr, int dst_width); 244 uint8* dst_ptr, int dst_width);
245 void ScaleRowDown2Box_AVX2(const uint8* src_ptr, ptrdiff_t src_stride, 245 void ScaleRowDown2Box_AVX2(const uint8* src_ptr, ptrdiff_t src_stride,
246 uint8* dst_ptr, int dst_width); 246 uint8* dst_ptr, int dst_width);
247 void ScaleRowDown4_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 247 void ScaleRowDown4_SSE2(const uint8* src_ptr, ptrdiff_t src_stride,
248 uint8* dst_ptr, int dst_width); 248 uint8* dst_ptr, int dst_width);
249 void ScaleRowDown4Box_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 249 void ScaleRowDown4Box_SSE2(const uint8* src_ptr, ptrdiff_t src_stride,
250 uint8* dst_ptr, int dst_width); 250 uint8* dst_ptr, int dst_width);
(...skipping 11 matching lines...) Expand all
262 ptrdiff_t src_stride, 262 ptrdiff_t src_stride,
263 uint8* dst_ptr, int dst_width); 263 uint8* dst_ptr, int dst_width);
264 void ScaleRowDown38_SSSE3(const uint8* src_ptr, ptrdiff_t src_stride, 264 void ScaleRowDown38_SSSE3(const uint8* src_ptr, ptrdiff_t src_stride,
265 uint8* dst_ptr, int dst_width); 265 uint8* dst_ptr, int dst_width);
266 void ScaleRowDown38_3_Box_SSSE3(const uint8* src_ptr, 266 void ScaleRowDown38_3_Box_SSSE3(const uint8* src_ptr,
267 ptrdiff_t src_stride, 267 ptrdiff_t src_stride,
268 uint8* dst_ptr, int dst_width); 268 uint8* dst_ptr, int dst_width);
269 void ScaleRowDown38_2_Box_SSSE3(const uint8* src_ptr, 269 void ScaleRowDown38_2_Box_SSSE3(const uint8* src_ptr,
270 ptrdiff_t src_stride, 270 ptrdiff_t src_stride,
271 uint8* dst_ptr, int dst_width); 271 uint8* dst_ptr, int dst_width);
272 void ScaleRowDown2_Any_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 272 void ScaleRowDown2_Any_SSSE3(const uint8* src_ptr, ptrdiff_t src_stride,
273 uint8* dst_ptr, int dst_width); 273 uint8* dst_ptr, int dst_width);
274 void ScaleRowDown2Linear_Any_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 274 void ScaleRowDown2Linear_Any_SSSE3(const uint8* src_ptr, ptrdiff_t src_stride,
275 uint8* dst_ptr, int dst_width); 275 uint8* dst_ptr, int dst_width);
276 void ScaleRowDown2Box_Any_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 276 void ScaleRowDown2Box_Any_SSSE3(const uint8* src_ptr, ptrdiff_t src_stride,
277 uint8* dst_ptr, int dst_width); 277 uint8* dst_ptr, int dst_width);
278 void ScaleRowDown2_Any_AVX2(const uint8* src_ptr, ptrdiff_t src_stride, 278 void ScaleRowDown2_Any_AVX2(const uint8* src_ptr, ptrdiff_t src_stride,
279 uint8* dst_ptr, int dst_width); 279 uint8* dst_ptr, int dst_width);
280 void ScaleRowDown2Linear_Any_AVX2(const uint8* src_ptr, ptrdiff_t src_stride, 280 void ScaleRowDown2Linear_Any_AVX2(const uint8* src_ptr, ptrdiff_t src_stride,
281 uint8* dst_ptr, int dst_width); 281 uint8* dst_ptr, int dst_width);
282 void ScaleRowDown2Box_Any_AVX2(const uint8* src_ptr, ptrdiff_t src_stride, 282 void ScaleRowDown2Box_Any_AVX2(const uint8* src_ptr, ptrdiff_t src_stride,
283 uint8* dst_ptr, int dst_width); 283 uint8* dst_ptr, int dst_width);
284 void ScaleRowDown4_Any_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 284 void ScaleRowDown4_Any_SSE2(const uint8* src_ptr, ptrdiff_t src_stride,
285 uint8* dst_ptr, int dst_width); 285 uint8* dst_ptr, int dst_width);
286 void ScaleRowDown4Box_Any_SSE2(const uint8* src_ptr, ptrdiff_t src_stride, 286 void ScaleRowDown4Box_Any_SSE2(const uint8* src_ptr, ptrdiff_t src_stride,
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
487 void ScaleRowDown38_3_Box_MIPS_DSPR2(const uint8* src_ptr, 487 void ScaleRowDown38_3_Box_MIPS_DSPR2(const uint8* src_ptr,
488 ptrdiff_t src_stride, 488 ptrdiff_t src_stride,
489 uint8* dst_ptr, int dst_width); 489 uint8* dst_ptr, int dst_width);
490 490
491 #ifdef __cplusplus 491 #ifdef __cplusplus
492 } // extern "C" 492 } // extern "C"
493 } // namespace libyuv 493 } // namespace libyuv
494 #endif 494 #endif
495 495
496 #endif // INCLUDE_LIBYUV_SCALE_ROW_H_ NOLINT 496 #endif // INCLUDE_LIBYUV_SCALE_ROW_H_ NOLINT
OLDNEW
« no previous file with comments | « README.chromium ('k') | include/libyuv/version.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698