2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved.
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
6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree.
12 #include "vpx_ports/config.h"
13 #include "vp8/common/g_common.h"
14 #include "vp8/common/subpixel.h"
15 #include "vp8/common/loopfilter.h"
16 #include "vp8/common/recon.h"
17 #include "vp8/common/idct.h"
18 #include "vp8/common/onyxc_int.h"
20 extern void vp8_arch_x86_common_init(VP8_COMMON
*ctx
);
21 extern void vp8_arch_arm_common_init(VP8_COMMON
*ctx
);
23 void (*vp8_build_intra_predictors_mby_ptr
)(MACROBLOCKD
*x
);
24 extern void vp8_build_intra_predictors_mby(MACROBLOCKD
*x
);
26 void (*vp8_build_intra_predictors_mby_s_ptr
)(MACROBLOCKD
*x
);
27 extern void vp8_build_intra_predictors_mby_s(MACROBLOCKD
*x
);
29 void vp8_machine_specific_config(VP8_COMMON
*ctx
)
31 #if CONFIG_RUNTIME_CPU_DETECT
32 VP8_COMMON_RTCD
*rtcd
= &ctx
->rtcd
;
34 rtcd
->idct
.idct1
= vp8_short_idct4x4llm_1_c
;
35 rtcd
->idct
.idct16
= vp8_short_idct4x4llm_c
;
36 rtcd
->idct
.idct1_scalar_add
= vp8_dc_only_idct_add_c
;
37 rtcd
->idct
.iwalsh1
= vp8_short_inv_walsh4x4_1_c
;
38 rtcd
->idct
.iwalsh16
= vp8_short_inv_walsh4x4_c
;
40 rtcd
->recon
.copy16x16
= vp8_copy_mem16x16_c
;
41 rtcd
->recon
.copy8x8
= vp8_copy_mem8x8_c
;
42 rtcd
->recon
.copy8x4
= vp8_copy_mem8x4_c
;
43 rtcd
->recon
.recon
= vp8_recon_b_c
;
44 rtcd
->recon
.recon2
= vp8_recon2b_c
;
45 rtcd
->recon
.recon4
= vp8_recon4b_c
;
46 rtcd
->recon
.recon_mb
= vp8_recon_mb_c
;
47 rtcd
->recon
.recon_mby
= vp8_recon_mby_c
;
49 rtcd
->subpix
.sixtap16x16
= vp8_sixtap_predict16x16_c
;
50 rtcd
->subpix
.sixtap8x8
= vp8_sixtap_predict8x8_c
;
51 rtcd
->subpix
.sixtap8x4
= vp8_sixtap_predict8x4_c
;
52 rtcd
->subpix
.sixtap4x4
= vp8_sixtap_predict_c
;
53 rtcd
->subpix
.bilinear16x16
= vp8_bilinear_predict16x16_c
;
54 rtcd
->subpix
.bilinear8x8
= vp8_bilinear_predict8x8_c
;
55 rtcd
->subpix
.bilinear8x4
= vp8_bilinear_predict8x4_c
;
56 rtcd
->subpix
.bilinear4x4
= vp8_bilinear_predict4x4_c
;
58 rtcd
->loopfilter
.normal_mb_v
= vp8_loop_filter_mbv_c
;
59 rtcd
->loopfilter
.normal_b_v
= vp8_loop_filter_bv_c
;
60 rtcd
->loopfilter
.normal_mb_h
= vp8_loop_filter_mbh_c
;
61 rtcd
->loopfilter
.normal_b_h
= vp8_loop_filter_bh_c
;
62 rtcd
->loopfilter
.simple_mb_v
= vp8_loop_filter_mbvs_c
;
63 rtcd
->loopfilter
.simple_b_v
= vp8_loop_filter_bvs_c
;
64 rtcd
->loopfilter
.simple_mb_h
= vp8_loop_filter_mbhs_c
;
65 rtcd
->loopfilter
.simple_b_h
= vp8_loop_filter_bhs_c
;
67 #if CONFIG_POSTPROC || (CONFIG_VP8_ENCODER && CONFIG_PSNR)
68 rtcd
->postproc
.down
= vp8_mbpost_proc_down_c
;
69 rtcd
->postproc
.across
= vp8_mbpost_proc_across_ip_c
;
70 rtcd
->postproc
.downacross
= vp8_post_proc_down_and_across_c
;
71 rtcd
->postproc
.addnoise
= vp8_plane_add_noise_c
;
72 rtcd
->postproc
.blend_mb_inner
= vp8_blend_mb_inner_c
;
73 rtcd
->postproc
.blend_mb_outer
= vp8_blend_mb_outer_c
;
74 rtcd
->postproc
.blend_b
= vp8_blend_b_c
;
79 vp8_build_intra_predictors_mby_ptr
= vp8_build_intra_predictors_mby
;
80 vp8_build_intra_predictors_mby_s_ptr
= vp8_build_intra_predictors_mby_s
;
82 #if ARCH_X86 || ARCH_X86_64
83 vp8_arch_x86_common_init(ctx
);
87 vp8_arch_arm_common_init(ctx
);