• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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 *******************************************************************************
23 * @file
24 *  ih264e_mc.h
25 *
26 * @brief
27 *  This file contains declarations of routines that perform motion compensation
28 *  of luma and chroma macroblocks.
29 *
30 * @author
31 *  ittiam
32 *
33 * @remarks
34 *  none
35 *
36 *******************************************************************************
37 */
38 
39 #ifndef IH264E_MC_H_
40 #define IH264E_MC_H_
41 
42 /*****************************************************************************/
43 /* Extern Function Declarations                                              */
44 /*****************************************************************************/
45 
46 /**
47 ******************************************************************************
48 *
49 * @brief
50 *  performs motion compensation for a luma mb for the given mv.
51 *
52 * @par Description
53 *  This routine performs motion compensation of an inter mb. When the inter
54 *  mb mode is P16x16, there is no need to copy 16x16 unit from reference buffer
55 *  to pred buffer. In this case the function returns pointer and stride of the
56 *  ref. buffer and this info is used in place of pred buffer else where.
57 *  In other cases, the pred buffer is populated via copy / filtering + copy
58 *  (q pel cases) and returned.
59 *
60 * @param[in] ps_proc
61 *  pointer to current proc ctxt
62 *
63 * @param[out] pu1_pseudo_pred
64 *  pseudo prediction buffer
65 *
66 * @param[out] u4_pseudo_pred_strd
67 *  pseudo pred buffer stride
68 *
69 * @return  none
70 *
71 * @remarks Assumes half pel buffers for the entire frame are populated.
72 *
73 ******************************************************************************
74 */
75 void ih264e_motion_comp_luma(process_ctxt_t *ps_proc,
76                              UWORD8 **pu1_pseudo_pred,
77                              WORD32 *pi4_pseudo_pred_strd);
78 
79 /**
80 ******************************************************************************
81 *
82 * @brief
83 *  performs motion compensation for chroma mb
84 *
85 * @par   Description
86 *  Copies a MB of data from the reference buffer (Full pel, half pel or q pel)
87 *  according to the motion vectors given
88 *
89 * @param[in] ps_proc
90 *  pointer to current proc ctxt
91 *
92 * @return  none
93 *
94 * @remarks Assumes half pel and quarter pel buffers for the entire frame are
95 *  populated.
96 ******************************************************************************
97 */
98 void ih264e_motion_comp_chroma
99         (
100             process_ctxt_t *ps_proc
101         );
102 
103 
104 #endif // IH264E_MC_H_
105