1 /****************************************************************************** 2 * 3 * Copyright (C) 2015 The Android Open Source Project 4 * 5 * Licensed under the Apache License, Version 2.0 (the "License"); 6 * you may not use this file except in compliance with the License. 7 * You may obtain a copy of the License at: 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 * See the License for the specific language governing permissions and 15 * limitations under the License. 16 * 17 ***************************************************************************** 18 * Originally developed and contributed by Ittiam Systems Pvt. Ltd, Bangalore 19 */ 20 /** 21 ******************************************************************************* 22 * @file 23 * ih264e_function_selector_generic.c 24 * 25 * @brief 26 * Contains functions to initialize function pointers of codec context 27 * 28 * @author 29 * Ittiam 30 * 31 * @par List of Functions: 32 * - ih264e_init_function_ptr_generic 33 * 34 * @remarks 35 * None 36 * 37 ******************************************************************************* 38 */ 39 40 41 /*****************************************************************************/ 42 /* File Includes */ 43 /*****************************************************************************/ 44 45 /* System Include files */ 46 #include <stdio.h> 47 #include <stddef.h> 48 #include <stdlib.h> 49 #include <string.h> 50 51 /* User Include files */ 52 #include "ih264_typedefs.h" 53 #include "iv.h" 54 #include "ivd.h" 55 #include "ih264_defs.h" 56 #include "ih264_size_defs.h" 57 #include "ih264_error.h" 58 #include "ih264_trans_quant_itrans_iquant.h" 59 #include "ih264_inter_pred_filters.h" 60 61 #include "ih264d_structs.h" 62 63 64 /** 65 ******************************************************************************* 66 * 67 * @brief Initialize the intra/inter/transform/deblk function pointers of 68 * codec context 69 * 70 * @par Description: the current routine initializes the function pointers of 71 * codec context basing on the architecture in use 72 * 73 * @param[in] ps_codec 74 * Codec context pointer 75 * 76 * @returns none 77 * 78 * @remarks none 79 * 80 ******************************************************************************* 81 */ 82 void ih264d_init_function_ptr_sse42(dec_struct_t *ps_codec) 83 { 84 ps_codec->pf_default_weighted_pred_luma = ih264_default_weighted_pred_luma_sse42; 85 ps_codec->pf_default_weighted_pred_chroma = ih264_default_weighted_pred_chroma_sse42; 86 ps_codec->pf_weighted_pred_luma = ih264_weighted_pred_luma_sse42; 87 ps_codec->pf_weighted_pred_chroma = ih264_weighted_pred_chroma_sse42; 88 ps_codec->pf_weighted_bi_pred_luma = ih264_weighted_bi_pred_luma_sse42; 89 ps_codec->pf_weighted_bi_pred_chroma = ih264_weighted_bi_pred_chroma_sse42; 90 91 ps_codec->pf_iquant_itrans_recon_luma_4x4 = ih264_iquant_itrans_recon_4x4_sse42; 92 ps_codec->pf_iquant_itrans_recon_chroma_4x4 = ih264_iquant_itrans_recon_chroma_4x4_sse42; 93 ps_codec->pf_ihadamard_scaling_4x4 = ih264_ihadamard_scaling_4x4_sse42; 94 return; 95 } 96