Initial WebM release
[libvpx.git] / vp8 / encoder / x86 / encodemb_x86.h
blob9397a6ccaab174d926616c7a9c7f40cfe728a035
1 /*
2 * Copyright (c) 2010 The VP8 project authors. All Rights Reserved.
4 * Use of this source code is governed by a BSD-style license and patent
5 * grant that can be found in the LICENSE file in the root of the source
6 * tree. All contributing project authors may be found in the AUTHORS
7 * file in the root of the source tree.
8 */
11 #ifndef ENCODEMB_X86_H
12 #define ENCODEMB_X86_H
15 /* Note:
17 * This platform is commonly built for runtime CPU detection. If you modify
18 * any of the function mappings present in this file, be sure to also update
19 * them in the function pointer initialization code
21 #if HAVE_MMX
22 extern prototype_berr(vp8_block_error_mmx);
23 extern prototype_mberr(vp8_mbblock_error_mmx);
24 extern prototype_mbuverr(vp8_mbuverror_mmx);
25 extern prototype_subb(vp8_subtract_b_mmx);
26 extern prototype_submby(vp8_subtract_mby_mmx);
27 extern prototype_submbuv(vp8_subtract_mbuv_mmx);
30 #if !CONFIG_RUNTIME_CPU_DETECT
31 #undef vp8_encodemb_berr
32 #define vp8_encodemb_berr vp8_block_error_mmx
34 #undef vp8_encodemb_mberr
35 #define vp8_encodemb_mberr vp8_mbblock_error_mmx
37 #undef vp8_encodemb_mbuverr
38 #define vp8_encodemb_mbuverr vp8_mbuverror_mmx
40 #undef vp8_encodemb_subb
41 #define vp8_encodemb_subb vp8_subtract_b_mmx
43 #undef vp8_encodemb_submby
44 #define vp8_encodemb_submby vp8_subtract_mby_mmx
46 #undef vp8_encodemb_submbuv
47 #define vp8_encodemb_submbuv vp8_subtract_mbuv_mmx
49 #endif
50 #endif
53 #if HAVE_SSE2
54 extern prototype_berr(vp8_block_error_xmm);
55 extern prototype_mberr(vp8_mbblock_error_xmm);
56 extern prototype_mbuverr(vp8_mbuverror_xmm);
59 #if !CONFIG_RUNTIME_CPU_DETECT
60 #undef vp8_encodemb_berr
61 #define vp8_encodemb_berr vp8_block_error_xmm
63 #undef vp8_encodemb_mberr
64 #define vp8_encodemb_mberr vp8_mbblock_error_xmm
66 #undef vp8_encodemb_mbuverr
67 #define vp8_encodemb_mbuverr vp8_mbuverror_xmm
69 #endif
70 #endif
73 #endif