OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebM project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebM 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 #include "./vpx_config.h" | 10 #include "./vpx_config.h" |
11 | 11 |
12 #include "vp9/encoder/vp9_variance.h" | 12 #include "vp9/encoder/vp9_variance.h" |
13 #include "vp9/common/vp9_pragmas.h" | |
14 #include "vpx_ports/mem.h" | 13 #include "vpx_ports/mem.h" |
15 | 14 |
16 typedef void (*get_var_avx2) ( | 15 typedef void (*get_var_avx2) ( |
17 const unsigned char *src_ptr, | 16 const unsigned char *src_ptr, |
18 int source_stride, | 17 int source_stride, |
19 const unsigned char *ref_ptr, | 18 const unsigned char *ref_ptr, |
20 int recon_stride, | 19 int recon_stride, |
21 unsigned int *SSE, | 20 unsigned int *SSE, |
22 int *Sum | 21 int *Sum |
23 ); | 22 ); |
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 // processing 32 element in parallel | 258 // processing 32 element in parallel |
260 unsigned int sse; | 259 unsigned int sse; |
261 int se = vp9_sub_pixel_avg_variance32xh_avx2(src, src_stride, x_offset, | 260 int se = vp9_sub_pixel_avg_variance32xh_avx2(src, src_stride, x_offset, |
262 y_offset, dst, dst_stride, | 261 y_offset, dst, dst_stride, |
263 sec, 32, 32, &sse); | 262 sec, 32, 32, &sse); |
264 *sseptr = sse; | 263 *sseptr = sse; |
265 return sse - (((int64_t)se * se) >> 10); | 264 return sse - (((int64_t)se * se) >> 10); |
266 } | 265 } |
267 | 266 |
268 | 267 |
OLD | NEW |