xref: /third_party/ffmpeg/libavcodec/ivi_dsp.h (revision cabdff1a)
1cabdff1aSopenharmony_ci/*
2cabdff1aSopenharmony_ci * DSP functions for Indeo Video Interactive codecs (Indeo4 and Indeo5)
3cabdff1aSopenharmony_ci *
4cabdff1aSopenharmony_ci * Copyright (c) 2009-2011 Maxim Poliakovski
5cabdff1aSopenharmony_ci *
6cabdff1aSopenharmony_ci * This file is part of FFmpeg.
7cabdff1aSopenharmony_ci *
8cabdff1aSopenharmony_ci * FFmpeg is free software; you can redistribute it and/or
9cabdff1aSopenharmony_ci * modify it under the terms of the GNU Lesser General Public
10cabdff1aSopenharmony_ci * License as published by the Free Software Foundation; either
11cabdff1aSopenharmony_ci * version 2.1 of the License, or (at your option) any later version.
12cabdff1aSopenharmony_ci *
13cabdff1aSopenharmony_ci * FFmpeg is distributed in the hope that it will be useful,
14cabdff1aSopenharmony_ci * but WITHOUT ANY WARRANTY; without even the implied warranty of
15cabdff1aSopenharmony_ci * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16cabdff1aSopenharmony_ci * Lesser General Public License for more details.
17cabdff1aSopenharmony_ci *
18cabdff1aSopenharmony_ci * You should have received a copy of the GNU Lesser General Public
19cabdff1aSopenharmony_ci * License along with FFmpeg; if not, write to the Free Software
20cabdff1aSopenharmony_ci * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21cabdff1aSopenharmony_ci */
22cabdff1aSopenharmony_ci
23cabdff1aSopenharmony_ci/**
24cabdff1aSopenharmony_ci * @file
25cabdff1aSopenharmony_ci * DSP functions (inverse transforms, motion compensations, wavelet recomposition)
26cabdff1aSopenharmony_ci * for Indeo Video Interactive codecs.
27cabdff1aSopenharmony_ci */
28cabdff1aSopenharmony_ci
29cabdff1aSopenharmony_ci#ifndef AVCODEC_IVI_DSP_H
30cabdff1aSopenharmony_ci#define AVCODEC_IVI_DSP_H
31cabdff1aSopenharmony_ci
32cabdff1aSopenharmony_ci#include <stddef.h>
33cabdff1aSopenharmony_ci#include <stdint.h>
34cabdff1aSopenharmony_ci
35cabdff1aSopenharmony_ci#include "ivi.h"
36cabdff1aSopenharmony_ci
37cabdff1aSopenharmony_ci/**
38cabdff1aSopenharmony_ci *  5/3 wavelet recomposition filter for Indeo5
39cabdff1aSopenharmony_ci *
40cabdff1aSopenharmony_ci *  @param[in]   plane        pointer to the descriptor of the plane being processed
41cabdff1aSopenharmony_ci *  @param[out]  dst          pointer to the destination buffer
42cabdff1aSopenharmony_ci *  @param[in]   dst_pitch    pitch of the destination buffer
43cabdff1aSopenharmony_ci */
44cabdff1aSopenharmony_civoid ff_ivi_recompose53(const IVIPlaneDesc *plane, uint8_t *dst,
45cabdff1aSopenharmony_ci                        const ptrdiff_t dst_pitch);
46cabdff1aSopenharmony_ci
47cabdff1aSopenharmony_ci/**
48cabdff1aSopenharmony_ci *  Haar wavelet recomposition filter for Indeo 4
49cabdff1aSopenharmony_ci *
50cabdff1aSopenharmony_ci *  @param[in]  plane        pointer to the descriptor of the plane being processed
51cabdff1aSopenharmony_ci *  @param[out] dst          pointer to the destination buffer
52cabdff1aSopenharmony_ci *  @param[in]  dst_pitch    pitch of the destination buffer
53cabdff1aSopenharmony_ci */
54cabdff1aSopenharmony_civoid ff_ivi_recompose_haar(const IVIPlaneDesc *plane, uint8_t *dst,
55cabdff1aSopenharmony_ci                           const ptrdiff_t dst_pitch);
56cabdff1aSopenharmony_ci
57cabdff1aSopenharmony_ci/**
58cabdff1aSopenharmony_ci *  two-dimensional inverse Haar 8x8 transform for Indeo 4
59cabdff1aSopenharmony_ci *
60cabdff1aSopenharmony_ci *  @param[in]  in        pointer to the vector of transform coefficients
61cabdff1aSopenharmony_ci *  @param[out] out       pointer to the output buffer (frame)
62cabdff1aSopenharmony_ci *  @param[in]  pitch     pitch to move to the next y line
63cabdff1aSopenharmony_ci *  @param[in]  flags     pointer to the array of column flags:
64cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
65cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
66cabdff1aSopenharmony_ci */
67cabdff1aSopenharmony_civoid ff_ivi_inverse_haar_8x8(const int32_t *in, int16_t *out, ptrdiff_t pitch,
68cabdff1aSopenharmony_ci                             const uint8_t *flags);
69cabdff1aSopenharmony_civoid ff_ivi_inverse_haar_8x1(const int32_t *in, int16_t *out, uint32_t pitch,
70cabdff1aSopenharmony_ci                             const uint8_t *flags);
71cabdff1aSopenharmony_civoid ff_ivi_inverse_haar_1x8(const int32_t *in, int16_t *out, uint32_t pitch,
72cabdff1aSopenharmony_ci                             const uint8_t *flags);
73cabdff1aSopenharmony_ci
74cabdff1aSopenharmony_ci/**
75cabdff1aSopenharmony_ci *  one-dimensional inverse 8-point Haar transform on rows for Indeo 4
76cabdff1aSopenharmony_ci *
77cabdff1aSopenharmony_ci *  @param[in]  in        pointer to the vector of transform coefficients
78cabdff1aSopenharmony_ci *  @param[out] out       pointer to the output buffer (frame)
79cabdff1aSopenharmony_ci *  @param[in]  pitch     pitch to move to the next y line
80cabdff1aSopenharmony_ci *  @param[in]  flags     pointer to the array of column flags:
81cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
82cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
83cabdff1aSopenharmony_ci */
84cabdff1aSopenharmony_civoid ff_ivi_row_haar8(const int32_t *in, int16_t *out, ptrdiff_t pitch,
85cabdff1aSopenharmony_ci                      const uint8_t *flags);
86cabdff1aSopenharmony_ci
87cabdff1aSopenharmony_ci/**
88cabdff1aSopenharmony_ci *  one-dimensional inverse 8-point Haar transform on columns for Indeo 4
89cabdff1aSopenharmony_ci *
90cabdff1aSopenharmony_ci *  @param[in]  in        pointer to the vector of transform coefficients
91cabdff1aSopenharmony_ci *  @param[out] out       pointer to the output buffer (frame)
92cabdff1aSopenharmony_ci *  @param[in]  pitch     pitch to move to the next y line
93cabdff1aSopenharmony_ci *  @param[in]  flags     pointer to the array of column flags:
94cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
95cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
96cabdff1aSopenharmony_ci */
97cabdff1aSopenharmony_civoid ff_ivi_col_haar8(const int32_t *in, int16_t *out, ptrdiff_t pitch,
98cabdff1aSopenharmony_ci                      const uint8_t *flags);
99cabdff1aSopenharmony_ci
100cabdff1aSopenharmony_ci/**
101cabdff1aSopenharmony_ci *  two-dimensional inverse Haar 4x4 transform for Indeo 4
102cabdff1aSopenharmony_ci *
103cabdff1aSopenharmony_ci *  @param[in]  in        pointer to the vector of transform coefficients
104cabdff1aSopenharmony_ci *  @param[out] out       pointer to the output buffer (frame)
105cabdff1aSopenharmony_ci *  @param[in]  pitch     pitch to move to the next y line
106cabdff1aSopenharmony_ci *  @param[in]  flags     pointer to the array of column flags:
107cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
108cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
109cabdff1aSopenharmony_ci */
110cabdff1aSopenharmony_civoid ff_ivi_inverse_haar_4x4(const int32_t *in, int16_t *out, ptrdiff_t pitch,
111cabdff1aSopenharmony_ci                             const uint8_t *flags);
112cabdff1aSopenharmony_ci
113cabdff1aSopenharmony_ci/**
114cabdff1aSopenharmony_ci *  one-dimensional inverse 4-point Haar transform on rows for Indeo 4
115cabdff1aSopenharmony_ci *
116cabdff1aSopenharmony_ci *  @param[in]  in        pointer to the vector of transform coefficients
117cabdff1aSopenharmony_ci *  @param[out] out       pointer to the output buffer (frame)
118cabdff1aSopenharmony_ci *  @param[in]  pitch     pitch to move to the next y line
119cabdff1aSopenharmony_ci *  @param[in]  flags     pointer to the array of column flags:
120cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
121cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
122cabdff1aSopenharmony_ci */
123cabdff1aSopenharmony_civoid ff_ivi_row_haar4(const int32_t *in, int16_t *out, ptrdiff_t pitch,
124cabdff1aSopenharmony_ci                      const uint8_t *flags);
125cabdff1aSopenharmony_ci
126cabdff1aSopenharmony_ci/**
127cabdff1aSopenharmony_ci *  one-dimensional inverse 4-point Haar transform on columns for Indeo 4
128cabdff1aSopenharmony_ci *
129cabdff1aSopenharmony_ci *  @param[in]  in        pointer to the vector of transform coefficients
130cabdff1aSopenharmony_ci *  @param[out] out       pointer to the output buffer (frame)
131cabdff1aSopenharmony_ci *  @param[in]  pitch     pitch to move to the next y line
132cabdff1aSopenharmony_ci *  @param[in]  flags     pointer to the array of column flags:
133cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
134cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
135cabdff1aSopenharmony_ci */
136cabdff1aSopenharmony_civoid ff_ivi_col_haar4(const int32_t *in, int16_t *out, ptrdiff_t pitch,
137cabdff1aSopenharmony_ci                      const uint8_t *flags);
138cabdff1aSopenharmony_ci
139cabdff1aSopenharmony_ci/**
140cabdff1aSopenharmony_ci *  DC-only two-dimensional inverse Haar transform for Indeo 4.
141cabdff1aSopenharmony_ci *  Performing the inverse transform in this case is equivalent to
142cabdff1aSopenharmony_ci *  spreading DC_coeff >> 3 over the whole block.
143cabdff1aSopenharmony_ci *
144cabdff1aSopenharmony_ci *  @param[in]  in          pointer to the dc coefficient
145cabdff1aSopenharmony_ci *  @param[out] out         pointer to the output buffer (frame)
146cabdff1aSopenharmony_ci *  @param[in]  pitch       pitch to move to the next y line
147cabdff1aSopenharmony_ci *  @param[in]  blk_size    transform block size
148cabdff1aSopenharmony_ci */
149cabdff1aSopenharmony_civoid ff_ivi_dc_haar_2d(const int32_t *in, int16_t *out, ptrdiff_t pitch,
150cabdff1aSopenharmony_ci                       int blk_size);
151cabdff1aSopenharmony_ci
152cabdff1aSopenharmony_ci/**
153cabdff1aSopenharmony_ci *  two-dimensional inverse slant 8x8 transform
154cabdff1aSopenharmony_ci *
155cabdff1aSopenharmony_ci *  @param[in]    in      pointer to the vector of transform coefficients
156cabdff1aSopenharmony_ci *  @param[out]   out     pointer to the output buffer (frame)
157cabdff1aSopenharmony_ci *  @param[in]    pitch   pitch to move to the next y line
158cabdff1aSopenharmony_ci *  @param[in]    flags   pointer to the array of column flags:
159cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
160cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
161cabdff1aSopenharmony_ci */
162cabdff1aSopenharmony_civoid ff_ivi_inverse_slant_8x8(const int32_t *in, int16_t *out, ptrdiff_t pitch,
163cabdff1aSopenharmony_ci                              const uint8_t *flags);
164cabdff1aSopenharmony_ci
165cabdff1aSopenharmony_ci/**
166cabdff1aSopenharmony_ci *  two-dimensional inverse slant 4x4 transform
167cabdff1aSopenharmony_ci *
168cabdff1aSopenharmony_ci *  @param[in]    in      pointer to the vector of transform coefficients
169cabdff1aSopenharmony_ci *  @param[out]   out     pointer to the output buffer (frame)
170cabdff1aSopenharmony_ci *  @param[in]    pitch   pitch to move to the next y line
171cabdff1aSopenharmony_ci *  @param[in]    flags   pointer to the array of column flags:
172cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
173cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
174cabdff1aSopenharmony_ci */
175cabdff1aSopenharmony_civoid ff_ivi_inverse_slant_4x4(const int32_t *in, int16_t *out, ptrdiff_t pitch,
176cabdff1aSopenharmony_ci                              const uint8_t *flags);
177cabdff1aSopenharmony_ci
178cabdff1aSopenharmony_ci/**
179cabdff1aSopenharmony_ci *  DC-only two-dimensional inverse slant transform.
180cabdff1aSopenharmony_ci *  Performing the inverse slant transform in this case is equivalent to
181cabdff1aSopenharmony_ci *  spreading (DC_coeff + 1)/2 over the whole block.
182cabdff1aSopenharmony_ci *  It works much faster than performing the slant transform on a vector of zeroes.
183cabdff1aSopenharmony_ci *
184cabdff1aSopenharmony_ci *  @param[in]    in          pointer to the dc coefficient
185cabdff1aSopenharmony_ci *  @param[out]   out         pointer to the output buffer (frame)
186cabdff1aSopenharmony_ci *  @param[in]    pitch       pitch to move to the next y line
187cabdff1aSopenharmony_ci *  @param[in]    blk_size    transform block size
188cabdff1aSopenharmony_ci */
189cabdff1aSopenharmony_civoid ff_ivi_dc_slant_2d(const int32_t *in, int16_t *out, ptrdiff_t pitch, int blk_size);
190cabdff1aSopenharmony_ci
191cabdff1aSopenharmony_ci/**
192cabdff1aSopenharmony_ci *  inverse 1D row slant transform
193cabdff1aSopenharmony_ci *
194cabdff1aSopenharmony_ci *  @param[in]    in      pointer to the vector of transform coefficients
195cabdff1aSopenharmony_ci *  @param[out]   out     pointer to the output buffer (frame)
196cabdff1aSopenharmony_ci *  @param[in]    pitch   pitch to move to the next y line
197cabdff1aSopenharmony_ci *  @param[in]    flags   pointer to the array of column flags (unused here)
198cabdff1aSopenharmony_ci */
199cabdff1aSopenharmony_civoid ff_ivi_row_slant8(const int32_t *in, int16_t *out, ptrdiff_t pitch,
200cabdff1aSopenharmony_ci                       const uint8_t *flags);
201cabdff1aSopenharmony_ci
202cabdff1aSopenharmony_ci/**
203cabdff1aSopenharmony_ci *  inverse 1D column slant transform
204cabdff1aSopenharmony_ci *
205cabdff1aSopenharmony_ci *  @param[in]    in      pointer to the vector of transform coefficients
206cabdff1aSopenharmony_ci *  @param[out]   out     pointer to the output buffer (frame)
207cabdff1aSopenharmony_ci *  @param[in]    pitch   pitch to move to the next y line
208cabdff1aSopenharmony_ci *  @param[in]    flags   pointer to the array of column flags:
209cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
210cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
211cabdff1aSopenharmony_ci */
212cabdff1aSopenharmony_civoid ff_ivi_col_slant8(const int32_t *in, int16_t *out, ptrdiff_t pitch,
213cabdff1aSopenharmony_ci                       const uint8_t *flags);
214cabdff1aSopenharmony_ci
215cabdff1aSopenharmony_ci/**
216cabdff1aSopenharmony_ci *  inverse 1D row slant transform
217cabdff1aSopenharmony_ci *
218cabdff1aSopenharmony_ci *  @param[in]    in      pointer to the vector of transform coefficients
219cabdff1aSopenharmony_ci *  @param[out]   out     pointer to the output buffer (frame)
220cabdff1aSopenharmony_ci *  @param[in]    pitch   pitch to move to the next y line
221cabdff1aSopenharmony_ci *  @param[in]    flags   pointer to the array of column flags (unused here)
222cabdff1aSopenharmony_ci */
223cabdff1aSopenharmony_civoid ff_ivi_row_slant4(const int32_t *in, int16_t *out, ptrdiff_t pitch,
224cabdff1aSopenharmony_ci                       const uint8_t *flags);
225cabdff1aSopenharmony_ci
226cabdff1aSopenharmony_ci/**
227cabdff1aSopenharmony_ci *  inverse 1D column slant transform
228cabdff1aSopenharmony_ci *
229cabdff1aSopenharmony_ci *  @param[in]    in      pointer to the vector of transform coefficients
230cabdff1aSopenharmony_ci *  @param[out]   out     pointer to the output buffer (frame)
231cabdff1aSopenharmony_ci *  @param[in]    pitch   pitch to move to the next y line
232cabdff1aSopenharmony_ci *  @param[in]    flags   pointer to the array of column flags:
233cabdff1aSopenharmony_ci *                        != 0 - non_empty column, 0 - empty one
234cabdff1aSopenharmony_ci *                        (this array must be filled by caller)
235cabdff1aSopenharmony_ci */
236cabdff1aSopenharmony_civoid ff_ivi_col_slant4(const int32_t *in, int16_t *out, ptrdiff_t pitch,
237cabdff1aSopenharmony_ci                       const uint8_t *flags);
238cabdff1aSopenharmony_ci
239cabdff1aSopenharmony_ci/**
240cabdff1aSopenharmony_ci *  DC-only inverse row slant transform
241cabdff1aSopenharmony_ci */
242cabdff1aSopenharmony_civoid ff_ivi_dc_row_slant(const int32_t *in, int16_t *out, ptrdiff_t pitch, int blk_size);
243cabdff1aSopenharmony_ci
244cabdff1aSopenharmony_ci/**
245cabdff1aSopenharmony_ci *  DC-only inverse column slant transform
246cabdff1aSopenharmony_ci */
247cabdff1aSopenharmony_civoid ff_ivi_dc_col_slant(const int32_t *in, int16_t *out, ptrdiff_t pitch, int blk_size);
248cabdff1aSopenharmony_ci
249cabdff1aSopenharmony_ci/**
250cabdff1aSopenharmony_ci *  Copy the pixels into the frame buffer.
251cabdff1aSopenharmony_ci */
252cabdff1aSopenharmony_civoid ff_ivi_put_pixels_8x8(const int32_t *in, int16_t *out, ptrdiff_t pitch, const uint8_t *flags);
253cabdff1aSopenharmony_ci
254cabdff1aSopenharmony_ci/**
255cabdff1aSopenharmony_ci *  Copy the DC coefficient into the first pixel of the block and
256cabdff1aSopenharmony_ci *  zero all others.
257cabdff1aSopenharmony_ci */
258cabdff1aSopenharmony_civoid ff_ivi_put_dc_pixel_8x8(const int32_t *in, int16_t *out, ptrdiff_t pitch, int blk_size);
259cabdff1aSopenharmony_ci
260cabdff1aSopenharmony_ci/**
261cabdff1aSopenharmony_ci *  8x8 block motion compensation with adding delta
262cabdff1aSopenharmony_ci *
263cabdff1aSopenharmony_ci *  @param[in,out]   buf      pointer to the block in the current frame buffer containing delta
264cabdff1aSopenharmony_ci *  @param[in]       ref_buf  pointer to the corresponding block in the reference frame
265cabdff1aSopenharmony_ci *  @param[in]       pitch    pitch for moving to the next y line
266cabdff1aSopenharmony_ci *  @param[in]       mc_type  interpolation type
267cabdff1aSopenharmony_ci */
268cabdff1aSopenharmony_civoid ff_ivi_mc_8x8_delta(int16_t *buf, const int16_t *ref_buf, ptrdiff_t pitch, int mc_type);
269cabdff1aSopenharmony_ci
270cabdff1aSopenharmony_ci/**
271cabdff1aSopenharmony_ci *  4x4 block motion compensation with adding delta
272cabdff1aSopenharmony_ci *
273cabdff1aSopenharmony_ci *  @param[in,out]   buf      pointer to the block in the current frame buffer containing delta
274cabdff1aSopenharmony_ci *  @param[in]       ref_buf  pointer to the corresponding block in the reference frame
275cabdff1aSopenharmony_ci *  @param[in]       pitch    pitch for moving to the next y line
276cabdff1aSopenharmony_ci *  @param[in]       mc_type  interpolation type
277cabdff1aSopenharmony_ci */
278cabdff1aSopenharmony_civoid ff_ivi_mc_4x4_delta(int16_t *buf, const int16_t *ref_buf, ptrdiff_t pitch, int mc_type);
279cabdff1aSopenharmony_ci
280cabdff1aSopenharmony_ci/**
281cabdff1aSopenharmony_ci *  motion compensation without adding delta
282cabdff1aSopenharmony_ci *
283cabdff1aSopenharmony_ci *  @param[in,out]  buf      pointer to the block in the current frame receiving the result
284cabdff1aSopenharmony_ci *  @param[in]      ref_buf  pointer to the corresponding block in the reference frame
285cabdff1aSopenharmony_ci *  @param[in]      pitch    pitch for moving to the next y line
286cabdff1aSopenharmony_ci *  @param[in]      mc_type  interpolation type
287cabdff1aSopenharmony_ci */
288cabdff1aSopenharmony_civoid ff_ivi_mc_8x8_no_delta(int16_t *buf, const int16_t *ref_buf, ptrdiff_t pitch, int mc_type);
289cabdff1aSopenharmony_ci
290cabdff1aSopenharmony_ci/**
291cabdff1aSopenharmony_ci *  4x4 block motion compensation without adding delta
292cabdff1aSopenharmony_ci *
293cabdff1aSopenharmony_ci *  @param[in,out]  buf      pointer to the block in the current frame receiving the result
294cabdff1aSopenharmony_ci *  @param[in]      ref_buf  pointer to the corresponding block in the reference frame
295cabdff1aSopenharmony_ci *  @param[in]      pitch    pitch for moving to the next y line
296cabdff1aSopenharmony_ci *  @param[in]      mc_type  interpolation type
297cabdff1aSopenharmony_ci */
298cabdff1aSopenharmony_civoid ff_ivi_mc_4x4_no_delta(int16_t *buf, const int16_t *ref_buf, ptrdiff_t pitch, int mc_type);
299cabdff1aSopenharmony_ci
300cabdff1aSopenharmony_ci/**
301cabdff1aSopenharmony_ci *  8x8 block motion compensation with adding delta
302cabdff1aSopenharmony_ci *
303cabdff1aSopenharmony_ci *  @param[in,out]  buf      pointer to the block in the current frame buffer containing delta
304cabdff1aSopenharmony_ci *  @param[in]      ref_buf  pointer to the corresponding block in the backward reference frame
305cabdff1aSopenharmony_ci *  @param[in]      ref_buf2 pointer to the corresponding block in the forward reference frame
306cabdff1aSopenharmony_ci *  @param[in]      pitch    pitch for moving to the next y line
307cabdff1aSopenharmony_ci *  @param[in]      mc_type  interpolation type for backward reference
308cabdff1aSopenharmony_ci *  @param[in]      mc_type2 interpolation type for forward reference
309cabdff1aSopenharmony_ci */
310cabdff1aSopenharmony_civoid ff_ivi_mc_avg_8x8_delta(int16_t *buf, const int16_t *ref_buf, const int16_t *ref_buf2, ptrdiff_t pitch, int mc_type, int mc_type2);
311cabdff1aSopenharmony_ci
312cabdff1aSopenharmony_ci/**
313cabdff1aSopenharmony_ci *  4x4 block motion compensation with adding delta
314cabdff1aSopenharmony_ci *
315cabdff1aSopenharmony_ci *  @param[in,out]  buf      pointer to the block in the current frame buffer containing delta
316cabdff1aSopenharmony_ci *  @param[in]      ref_buf  pointer to the corresponding block in the backward reference frame
317cabdff1aSopenharmony_ci *  @param[in]      ref_buf2 pointer to the corresponding block in the forward reference frame
318cabdff1aSopenharmony_ci *  @param[in]      pitch    pitch for moving to the next y line
319cabdff1aSopenharmony_ci *  @param[in]      mc_type  interpolation type for backward reference
320cabdff1aSopenharmony_ci *  @param[in]      mc_type2 interpolation type for forward reference
321cabdff1aSopenharmony_ci */
322cabdff1aSopenharmony_civoid ff_ivi_mc_avg_4x4_delta(int16_t *buf, const int16_t *ref_buf, const int16_t *ref_buf2, ptrdiff_t pitch, int mc_type, int mc_type2);
323cabdff1aSopenharmony_ci
324cabdff1aSopenharmony_ci/**
325cabdff1aSopenharmony_ci *  motion compensation without adding delta for B-frames
326cabdff1aSopenharmony_ci *
327cabdff1aSopenharmony_ci *  @param[in,out]  buf      pointer to the block in the current frame receiving the result
328cabdff1aSopenharmony_ci *  @param[in]      ref_buf  pointer to the corresponding block in the backward reference frame
329cabdff1aSopenharmony_ci *  @param[in]      ref_buf2 pointer to the corresponding block in the forward reference frame
330cabdff1aSopenharmony_ci *  @param[in]      pitch    pitch for moving to the next y line
331cabdff1aSopenharmony_ci *  @param[in]      mc_type  interpolation type for backward reference
332cabdff1aSopenharmony_ci *  @param[in]      mc_type2 interpolation type for forward reference
333cabdff1aSopenharmony_ci */
334cabdff1aSopenharmony_civoid ff_ivi_mc_avg_8x8_no_delta(int16_t *buf, const int16_t *ref_buf, const int16_t *ref_buf2, ptrdiff_t pitch, int mc_type, int mc_type2);
335cabdff1aSopenharmony_ci
336cabdff1aSopenharmony_ci/**
337cabdff1aSopenharmony_ci *  4x4 block motion compensation without adding delta for B-frames
338cabdff1aSopenharmony_ci *
339cabdff1aSopenharmony_ci *  @param[in,out]  buf      pointer to the block in the current frame receiving the result
340cabdff1aSopenharmony_ci *  @param[in]      ref_buf  pointer to the corresponding block in the backward reference frame
341cabdff1aSopenharmony_ci *  @param[in]      ref_buf2 pointer to the corresponding block in the forward reference frame
342cabdff1aSopenharmony_ci *  @param[in]      pitch    pitch for moving to the next y line
343cabdff1aSopenharmony_ci *  @param[in]      mc_type  interpolation type for backward reference
344cabdff1aSopenharmony_ci *  @param[in]      mc_type2 interpolation type for forward reference
345cabdff1aSopenharmony_ci */
346cabdff1aSopenharmony_civoid ff_ivi_mc_avg_4x4_no_delta(int16_t *buf, const int16_t *ref_buf, const int16_t *ref_buf2, ptrdiff_t pitch, int mc_type, int mc_type2);
347cabdff1aSopenharmony_ci
348cabdff1aSopenharmony_ci#endif /* AVCODEC_IVI_DSP_H */
349