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

Side by Side Diff: source/scale_common.cc

Issue 2346633002: Fix some comment typos (Closed)
Patch Set: Created 4 years, 3 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 | « no previous file | source/scale_gcc.cc » ('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 403 matching lines...) Expand 10 before | Expand all | Expand 10 after
414 if (dst_width & 1) { 414 if (dst_width & 1) {
415 dst_ptr[0] = src_ptr[0]; 415 dst_ptr[0] = src_ptr[0];
416 } 416 }
417 } 417 }
418 418
419 // (1-f)a + fb can be replaced with a + f(b-a) 419 // (1-f)a + fb can be replaced with a + f(b-a)
420 #if defined(__arm__) || defined(__aarch64__) 420 #if defined(__arm__) || defined(__aarch64__)
421 #define BLENDER(a, b, f) (uint8)((int)(a) + \ 421 #define BLENDER(a, b, f) (uint8)((int)(a) + \
422 ((((int)((f)) * ((int)(b) - (int)(a))) + 0x8000) >> 16)) 422 ((((int)((f)) * ((int)(b) - (int)(a))) + 0x8000) >> 16))
423 #else 423 #else
424 // inteluses 7 bit math with rounding. 424 // Intel uses 7 bit math with rounding.
425 #define BLENDER(a, b, f) (uint8)((int)(a) + \ 425 #define BLENDER(a, b, f) (uint8)((int)(a) + \
426 (((int)((f) >> 9) * ((int)(b) - (int)(a)) + 0x40) >> 7)) 426 (((int)((f) >> 9) * ((int)(b) - (int)(a)) + 0x40) >> 7))
427 #endif 427 #endif
428 428
429 void ScaleFilterCols_C(uint8* dst_ptr, const uint8* src_ptr, 429 void ScaleFilterCols_C(uint8* dst_ptr, const uint8* src_ptr,
430 int dst_width, int x, int dx) { 430 int dst_width, int x, int dx) {
431 int j; 431 int j;
432 for (j = 0; j < dst_width - 1; j += 2) { 432 for (j = 0; j < dst_width - 1; j += 2) {
433 int xi = x >> 16; 433 int xi = x >> 16;
434 int a = src_ptr[xi]; 434 int a = src_ptr[xi];
(...skipping 715 matching lines...) Expand 10 before | Expand all | Expand 10 after
1150 *dx = -*dx; 1150 *dx = -*dx;
1151 // src_width = -src_width; // Caller must do this. 1151 // src_width = -src_width; // Caller must do this.
1152 } 1152 }
1153 } 1153 }
1154 #undef CENTERSTART 1154 #undef CENTERSTART
1155 1155
1156 #ifdef __cplusplus 1156 #ifdef __cplusplus
1157 } // extern "C" 1157 } // extern "C"
1158 } // namespace libyuv 1158 } // namespace libyuv
1159 #endif 1159 #endif
OLDNEW
« no previous file with comments | « no previous file | source/scale_gcc.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698