[cvs] / xvidcore / src / image / interpolate8x8.h Repository:
ViewVC logotype

Diff of /xvidcore/src/image/interpolate8x8.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1, Fri Mar 8 02:44:46 2002 UTC revision 1.10.2.3, Sun Jul 13 10:01:00 2003 UTC
# Line 1  Line 1 
1    /*****************************************************************************
2     *
3     *  XVID MPEG-4 VIDEO CODEC
4     *  - Interpolation related header  -
5     *
6     *  Copyright(C) 2001-2003 Peter Ross <pross@xvid.org>
7     *
8     *  This program is free software ; you can redistribute it and/or modify
9     *  it under the terms of the GNU General Public License as published by
10     *  the Free Software Foundation ; either version 2 of the License, or
11     *  (at your option) any later version.
12     *
13     *  This program is distributed in the hope that it will be useful,
14     *  but WITHOUT ANY WARRANTY ; without even the implied warranty of
15     *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16     *  GNU General Public License for more details.
17     *
18     *  You should have received a copy of the GNU General Public License
19     *  along with this program ; if not, write to the Free Software
20     *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
21     *
22     * $Id$
23     *
24     ****************************************************************************/
25    
26    #ifndef _INTERPOLATE8X8_H_
27    #define _INTERPOLATE8X8_H_
28    
29  #include "../utils/mem_transfer.h"  #include "../utils/mem_transfer.h"
30    
31  typedef void (INTERPOLATE8X8)(uint8_t * const dst,  typedef void (INTERPOLATE8X8)(uint8_t * const dst,
# Line 6  Line 34 
34                                          const uint32_t rounding);                                          const uint32_t rounding);
35  typedef INTERPOLATE8X8 * INTERPOLATE8X8_PTR;  typedef INTERPOLATE8X8 * INTERPOLATE8X8_PTR;
36    
37    typedef void (INTERPOLATE8X8_AVG2) (uint8_t *dst,
38                                                                            const uint8_t *src1,
39                                                                            const uint8_t *src2,
40                                                                            const uint32_t stride,
41                                                                            const uint32_t rounding,
42                                                                            const uint32_t height);
43    typedef INTERPOLATE8X8_AVG2 *INTERPOLATE8X8_AVG2_PTR;
44    
45    typedef void (INTERPOLATE8X8_AVG4) (uint8_t *dst,
46                                                                            const uint8_t *src1,
47                                                                            const uint8_t *src2,
48                                                                            const uint8_t *src3,
49                                                                            const uint8_t *src4,
50                                                                            const uint32_t stride,
51                                                                            const uint32_t rounding);
52    typedef INTERPOLATE8X8_AVG4 *INTERPOLATE8X8_AVG4_PTR;
53    
54    typedef void (INTERPOLATE_LOWPASS) (uint8_t *dst,
55                                                                               uint8_t *src,
56                                                                               int32_t stride,
57                                                                               int32_t rounding);
58    
59    typedef INTERPOLATE_LOWPASS *INTERPOLATE_LOWPASS_PTR;
60    
61    typedef void (INTERPOLATE_LOWPASS_HV) (uint8_t *dst1,
62                                                                                      uint8_t *dst2,
63                                                                                      uint8_t *src,
64                                                                                      int32_t stride,
65                                                                                      int32_t rounding);
66    
67    typedef INTERPOLATE_LOWPASS_HV *INTERPOLATE_LOWPASS_HV_PTR;
68    
69    typedef void (INTERPOLATE8X8_6TAP_LOWPASS) (uint8_t *dst,
70                                                                                    uint8_t *src,
71                                                                                    int32_t stride,
72                                                                                    int32_t rounding);
73    
74    typedef INTERPOLATE8X8_6TAP_LOWPASS *INTERPOLATE8X8_6TAP_LOWPASS_PTR;
75    
76  extern INTERPOLATE8X8_PTR interpolate8x8_halfpel_h;  extern INTERPOLATE8X8_PTR interpolate8x8_halfpel_h;
77  extern INTERPOLATE8X8_PTR interpolate8x8_halfpel_v;  extern INTERPOLATE8X8_PTR interpolate8x8_halfpel_v;
78  extern INTERPOLATE8X8_PTR interpolate8x8_halfpel_hv;  extern INTERPOLATE8X8_PTR interpolate8x8_halfpel_hv;
79    
80    extern INTERPOLATE8X8_AVG2_PTR interpolate8x8_avg2;
81    extern INTERPOLATE8X8_AVG4_PTR interpolate8x8_avg4;
82    
83    extern INTERPOLATE_LOWPASS_PTR interpolate8x8_lowpass_h;
84    extern INTERPOLATE_LOWPASS_PTR interpolate8x8_lowpass_v;
85    
86    extern INTERPOLATE_LOWPASS_PTR interpolate16x16_lowpass_h;
87    extern INTERPOLATE_LOWPASS_PTR interpolate16x16_lowpass_v;
88    
89    extern INTERPOLATE_LOWPASS_HV_PTR interpolate8x8_lowpass_hv;
90    extern INTERPOLATE_LOWPASS_HV_PTR interpolate16x16_lowpass_hv;
91    
92    extern INTERPOLATE8X8_6TAP_LOWPASS_PTR interpolate8x8_6tap_lowpass_h;
93    extern INTERPOLATE8X8_6TAP_LOWPASS_PTR interpolate8x8_6tap_lowpass_v;
94    
95  INTERPOLATE8X8 interpolate8x8_halfpel_h_c;  INTERPOLATE8X8 interpolate8x8_halfpel_h_c;
96  INTERPOLATE8X8 interpolate8x8_halfpel_v_c;  INTERPOLATE8X8 interpolate8x8_halfpel_v_c;
97  INTERPOLATE8X8 interpolate8x8_halfpel_hv_c;  INTERPOLATE8X8 interpolate8x8_halfpel_hv_c;
# Line 26  Line 108 
108  INTERPOLATE8X8 interpolate8x8_halfpel_v_3dn;  INTERPOLATE8X8 interpolate8x8_halfpel_v_3dn;
109  INTERPOLATE8X8 interpolate8x8_halfpel_hv_3dn;  INTERPOLATE8X8 interpolate8x8_halfpel_hv_3dn;
110    
111  static __inline void interpolate8x8_switch(uint8_t * const cur,  INTERPOLATE8X8 interpolate8x8_halfpel_h_3dne;
112    INTERPOLATE8X8 interpolate8x8_halfpel_v_3dne;
113    INTERPOLATE8X8 interpolate8x8_halfpel_hv_3dne;
114    
115    INTERPOLATE8X8 interpolate8x8_halfpel_h_ia64;
116    INTERPOLATE8X8 interpolate8x8_halfpel_v_ia64;
117    INTERPOLATE8X8 interpolate8x8_halfpel_hv_ia64;
118    
119    INTERPOLATE8X8_AVG2 interpolate8x8_avg2_c;
120    INTERPOLATE8X8_AVG4 interpolate8x8_avg4_c;
121    
122    INTERPOLATE8X8_AVG2 interpolate8x8_avg2_mmx;
123    INTERPOLATE8X8_AVG4 interpolate8x8_avg4_mmx;
124    
125    INTERPOLATE_LOWPASS interpolate8x8_lowpass_h_c;
126    INTERPOLATE_LOWPASS interpolate8x8_lowpass_v_c;
127    
128    INTERPOLATE_LOWPASS interpolate16x16_lowpass_h_c;
129    INTERPOLATE_LOWPASS interpolate16x16_lowpass_v_c;
130    
131    INTERPOLATE_LOWPASS_HV interpolate8x8_lowpass_hv_c;
132    INTERPOLATE_LOWPASS_HV interpolate16x16_lowpass_hv_c;
133    
134    INTERPOLATE8X8_6TAP_LOWPASS interpolate8x8_6tap_lowpass_h_c;
135    INTERPOLATE8X8_6TAP_LOWPASS interpolate8x8_6tap_lowpass_v_c;
136    
137    INTERPOLATE8X8_6TAP_LOWPASS interpolate8x8_6tap_lowpass_h_mmx;
138    INTERPOLATE8X8_6TAP_LOWPASS interpolate8x8_6tap_lowpass_v_mmx;
139    
140    static __inline void
141    interpolate8x8_switch(uint8_t * const cur,
142                                       const uint8_t * const refn,                                       const uint8_t * const refn,
143                                              const uint32_t x,
144                                              const uint32_t y,
145                                              const int32_t dx,
146                                              const int dy,
147                                              const uint32_t stride,
148                                              const uint32_t rounding)
149    {
150    
151            const uint8_t * const src = refn + (y + (dy>>1)) * stride + x + (dx>>1);
152            uint8_t * const dst = cur + y * stride + x;
153    
154            switch (((dx & 1) << 1) + (dy & 1))     { /* ((dx%2)?2:0)+((dy%2)?1:0) */
155            case 0:
156                    transfer8x8_copy(dst, src, stride);
157                    break;
158            case 1:
159                    interpolate8x8_halfpel_v(dst, src, stride, rounding);
160                    break;
161            case 2:
162                    interpolate8x8_halfpel_h(dst, src, stride, rounding);
163                    break;
164            default:
165                    interpolate8x8_halfpel_hv(dst, src, stride, rounding);
166                    break;
167            }
168    }
169    
170    
171    static __inline void
172    interpolate16x16_switch(uint8_t * const cur,
173                                              const uint8_t * const refn,
174                                              const uint32_t x,
175                                              const uint32_t y,
176                                              const int32_t dx,
177                                              const int dy,
178                                              const uint32_t stride,
179                                              const uint32_t rounding)
180    {
181            interpolate8x8_switch(cur, refn, x,   y,   dx, dy, stride, rounding);
182            interpolate8x8_switch(cur, refn, x+8, y,   dx, dy, stride, rounding);
183            interpolate8x8_switch(cur, refn, x,   y+8, dx, dy, stride, rounding);
184            interpolate8x8_switch(cur, refn, x+8, y+8, dx, dy, stride, rounding);
185    }
186    
187    
188    static __inline void
189    interpolate32x32_switch(uint8_t * const cur,
190                                              const uint8_t * const refn,
191                                              const uint32_t x,
192                                              const uint32_t y,
193                                              const int32_t dx,
194                                              const int dy,
195                                              const uint32_t stride,
196                                              const uint32_t rounding)
197    {
198            interpolate16x16_switch(cur, refn, x,    y,    dx, dy, stride, rounding);
199            interpolate16x16_switch(cur, refn, x+16, y,    dx, dy, stride, rounding);
200            interpolate16x16_switch(cur, refn, x,    y+16, dx, dy, stride, rounding);
201            interpolate16x16_switch(cur, refn, x+16, y+16, dx, dy, stride, rounding);
202    }
203    
204    
205    static __inline uint8_t *
206    interpolate8x8_switch2(uint8_t * const buffer,
207                                              const uint8_t * const refn,
208                                              const int x,
209                                              const int y,
210                                              const int dx,
211                                              const int dy,
212                                              const uint32_t stride,
213                                              const uint32_t rounding)
214    {
215    
216            const uint8_t * const src = refn + (y + (dy>>1)) * stride + x + (dx>>1);
217    
218            switch (((dx & 1) << 1) + (dy & 1))     { /* ((dx%2)?2:0)+((dy%2)?1:0) */
219            case 0:
220                    return (uint8_t *)src;
221            case 1:
222                    interpolate8x8_halfpel_v(buffer, src, stride, rounding);
223                    break;
224            case 2:
225                    interpolate8x8_halfpel_h(buffer, src, stride, rounding);
226                    break;
227            default:
228                    interpolate8x8_halfpel_hv(buffer, src, stride, rounding);
229                    break;
230            }
231            return buffer;
232    }
233    
234    static __inline void interpolate8x8_quarterpel(uint8_t * const cur,
235                                         uint8_t * const refn,
236                                             uint8_t * const refh,
237                                             uint8_t * const refv,
238                                             uint8_t * const refhv,
239                                       const uint32_t x, const uint32_t y,                                       const uint32_t x, const uint32_t y,
240                                           const int32_t dx,  const int dy,                                           const int32_t dx,  const int dy,
241                                           const uint32_t stride,                                           const uint32_t stride,
242                                           const uint32_t rounding)                                           const uint32_t rounding)
243  {  {
244          int32_t ddx, ddy;          const int32_t xRef = x*4 + dx;
245            const int32_t yRef = y*4 + dy;
246    
247            uint8_t *src, *dst;
248            uint8_t *halfpel_h, *halfpel_v, *halfpel_hv;
249            int32_t x_int, y_int, x_frac, y_frac;
250    
251            x_int = xRef/4;
252            if (xRef < 0 && xRef % 4)
253                    x_int--;
254    
255            x_frac = xRef - (4*x_int);
256    
257            y_int  = yRef/4;
258            if (yRef < 0 && yRef % 4)
259                    y_int--;
260    
261            y_frac = yRef - (4*y_int);
262    
263            src = refn + y_int * stride + x_int;
264            halfpel_h = refh;
265            halfpel_v = refv;
266            halfpel_hv = refhv;
267    
268          switch ( ((dx&1)<<1) + (dy&1) )   // ((dx%2)?2:0)+((dy%2)?1:0)          dst = cur + y * stride + x;
269    
270            switch((y_frac << 2) | (x_frac)) {
271    
272            case 0:
273                    transfer8x8_copy(dst, src, stride);
274                    break;
275    
276            case 1:
277                    interpolate8x8_lowpass_h(halfpel_h, src, stride, rounding);
278                    interpolate8x8_avg2(dst, src, halfpel_h, stride, rounding, 8);
279                    break;
280    
281            case 2:
282                interpolate8x8_lowpass_h(dst, src, stride, rounding);
283                    break;
284    
285            case 3:
286                    interpolate8x8_lowpass_h(halfpel_h, src, stride, rounding);
287                    interpolate8x8_avg2(dst, src + 1, halfpel_h, stride, rounding, 8);
288                    break;
289    
290            case 4:
291                    interpolate8x8_lowpass_v(halfpel_v, src, stride, rounding);
292                    interpolate8x8_avg2(dst, src, halfpel_v, stride, rounding, 8);
293                    break;
294    
295            case 5:
296                    interpolate8x8_lowpass_h(halfpel_h, src, stride, rounding);
297                    interpolate8x8_avg2(halfpel_v, src, halfpel_h, stride, rounding, 9);
298                    interpolate8x8_lowpass_v(halfpel_hv, halfpel_v, stride, rounding);
299                    interpolate8x8_avg2(dst, halfpel_v, halfpel_hv, stride, rounding, 8);
300                    break;
301    
302            case 6:
303                    interpolate8x8_lowpass_hv(halfpel_hv, halfpel_h, src, stride, rounding);
304                    interpolate8x8_avg2(dst, halfpel_h, halfpel_hv, stride, rounding, 8);
305                    break;
306    
307            case 7:
308                    interpolate8x8_lowpass_h(halfpel_h, src, stride, rounding);
309                    interpolate8x8_avg2(halfpel_v, src + 1, halfpel_h, stride, rounding, 9);
310                    interpolate8x8_lowpass_v(halfpel_hv, halfpel_v, stride, rounding);
311                    interpolate8x8_avg2(dst, halfpel_v, halfpel_hv, stride, rounding, 8);
312                    break;
313    
314            case 8:
315                interpolate8x8_lowpass_v(dst, src, stride, rounding);
316                    break;
317    
318            case 9:
319                    interpolate8x8_lowpass_h(halfpel_h, src, stride, rounding);
320                    interpolate8x8_avg2(halfpel_v, src, halfpel_h, stride, rounding, 9);
321                    interpolate8x8_lowpass_v(dst, halfpel_v, stride, rounding);
322                    break;
323    
324            case 10:
325                    interpolate8x8_lowpass_hv(dst, halfpel_h, src, stride, rounding);
326                    break;
327    
328            case 11:
329                    interpolate8x8_lowpass_h(halfpel_h, src, stride, rounding);
330                    interpolate8x8_avg2(halfpel_v, src + 1, halfpel_h, stride, rounding, 9);
331                    interpolate8x8_lowpass_v(dst, halfpel_v, stride, rounding);
332                    break;
333    
334            case 12:
335                    interpolate8x8_lowpass_v(halfpel_v, src, stride, rounding);
336                    interpolate8x8_avg2(dst, src+stride, halfpel_v, stride, rounding, 8);
337                    break;
338    
339            case 13:
340                    interpolate8x8_lowpass_h(halfpel_h, src, stride, rounding);
341                    interpolate8x8_avg2(halfpel_v, src, halfpel_h, stride, rounding, 9);
342                    interpolate8x8_lowpass_v(halfpel_hv, halfpel_v, stride, rounding);
343                    interpolate8x8_avg2(dst, halfpel_v+stride, halfpel_hv, stride, rounding, 8);
344                    break;
345    
346            case 14:
347                    interpolate8x8_lowpass_hv(halfpel_hv, halfpel_h, src, stride, rounding);
348                    interpolate8x8_avg2(dst, halfpel_h+stride, halfpel_hv, stride, rounding, 8);
349                    break;
350    
351            case 15:
352                    interpolate8x8_lowpass_h(halfpel_h, src, stride, rounding);
353                    interpolate8x8_avg2(halfpel_v, src + 1, halfpel_h, stride, rounding, 9);
354                    interpolate8x8_lowpass_v(halfpel_hv, halfpel_v, stride, rounding);
355                    interpolate8x8_avg2(dst, halfpel_hv, halfpel_v + stride, stride, rounding, 8);
356                    break;
357            }
358    }
359    
360    static __inline void interpolate16x16_quarterpel(uint8_t * const cur,
361                                         uint8_t * const refn,
362                                             uint8_t * const refh,
363                                             uint8_t * const refv,
364                                             uint8_t * const refhv,
365                                         const uint32_t x, const uint32_t y,
366                                             const int32_t dx,  const int dy,
367                                             const uint32_t stride,
368                                             const uint32_t rounding)
369      {      {
370            const int32_t xRef = x*4 + dx;
371            const int32_t yRef = y*4 + dy;
372    
373            uint8_t *src, *dst;
374            uint8_t *halfpel_h, *halfpel_v, *halfpel_hv;
375            int32_t x_int, y_int, x_frac, y_frac;
376    
377            x_int = xRef/4;
378            if (xRef < 0 && xRef % 4)
379                    x_int--;
380    
381            x_frac = xRef - (4*x_int);
382    
383            y_int  = yRef/4;
384            if (yRef < 0 && yRef % 4)
385                    y_int--;
386    
387            y_frac = yRef - (4*y_int);
388    
389            src = refn + y_int * stride + x_int;
390            halfpel_h = refh;
391            halfpel_v = refv;
392            halfpel_hv = refhv;
393    
394            dst = cur + y * stride + x;
395    
396            switch((y_frac << 2) | (x_frac)) {
397    
398      case 0 :      case 0 :
399                  ddx = dx/2;                  transfer16x16_copy(dst, src, stride);
                 ddy = dy/2;  
                 transfer8x8_copy(cur + y*stride + x, refn + (y+ddy)*stride + x + ddx, stride);  
400                  break;                  break;
401    
402      case 1 :      case 1 :
403                  ddx = dx/2;                  interpolate16x16_lowpass_h(halfpel_h, src, stride, rounding);
404                  ddy = (dy-1)/2;                  interpolate8x8_avg2(dst, src, halfpel_h, stride, rounding, 8);
405                  interpolate8x8_halfpel_v(cur + y*stride + x,                  interpolate8x8_avg2(dst+8, src+8, halfpel_h+8, stride, rounding, 8);
406                                                          refn + (y+ddy)*stride + x + ddx, stride, rounding);                  interpolate8x8_avg2(dst+8*stride, src+8*stride, halfpel_h+8*stride, stride, rounding, 8);
407                    interpolate8x8_avg2(dst+8*stride+8, src+8*stride+8, halfpel_h+8*stride+8, stride, rounding, 8);
408                  break;                  break;
409    
410      case 2 :      case 2 :
411                  ddx = (dx-1)/2;              interpolate16x16_lowpass_h(dst, src, stride, rounding);
                 ddy = dy/2;  
                 interpolate8x8_halfpel_h(cur + y*stride + x,  
                                                         refn + (y+ddy)*stride + x + ddx, stride, rounding);  
412                  break;                  break;
413    
414      default :          case 3:
415                  ddx = (dx-1)/2;                  interpolate16x16_lowpass_h(halfpel_h, src, stride, rounding);
416                  ddy = (dy-1)/2;                  interpolate8x8_avg2(dst, src + 1, halfpel_h, stride, rounding, 8);
417                  interpolate8x8_halfpel_hv(cur + y*stride + x,                  interpolate8x8_avg2(dst+8, src + 8 + 1, halfpel_h+8, stride, rounding, 8);
418                                                          refn + (y+ddy)*stride + x + ddx, stride, rounding);                  interpolate8x8_avg2(dst+8*stride, src + 8*stride + 1, halfpel_h+8*stride, stride, rounding, 8);
419                    interpolate8x8_avg2(dst+8*stride+8, src+8*stride+8 + 1, halfpel_h+8*stride+8, stride, rounding, 8);
420                    break;
421    
422            case 4:
423                    interpolate16x16_lowpass_v(halfpel_v, src, stride, rounding);
424                    interpolate8x8_avg2(dst, src, halfpel_v, stride, rounding, 8);
425                    interpolate8x8_avg2(dst+8, src+8, halfpel_v+8, stride, rounding, 8);
426                    interpolate8x8_avg2(dst+8*stride, src+8*stride, halfpel_v+8*stride, stride, rounding, 8);
427                    interpolate8x8_avg2(dst+8*stride+8, src+8*stride+8, halfpel_v+8*stride+8, stride, rounding, 8);
428                    break;
429    
430            case 5:
431                    interpolate16x16_lowpass_h(halfpel_h, src, stride, rounding);
432                    interpolate8x8_avg2(halfpel_v, src, halfpel_h, stride, rounding, 9);
433                    interpolate8x8_avg2(halfpel_v+8, src + 8, halfpel_h+8, stride, rounding, 9);
434                    interpolate8x8_avg2(halfpel_v+8*stride, src + 8*stride, halfpel_h+8*stride, stride, rounding, 9);
435                    interpolate8x8_avg2(halfpel_v+8*stride+8, src+8*stride+8, halfpel_h+8*stride+8, stride, rounding, 9);
436    
437                    interpolate16x16_lowpass_v(halfpel_hv, halfpel_v, stride, rounding);
438                    interpolate8x8_avg2(dst, halfpel_hv, halfpel_v, stride, rounding, 8);
439                    interpolate8x8_avg2(dst+8, halfpel_hv+8, halfpel_v+8, stride, rounding, 8);
440                    interpolate8x8_avg2(dst+8*stride, halfpel_hv+8*stride, halfpel_v+8*stride, stride, rounding, 8);
441                    interpolate8x8_avg2(dst+8*stride+8, halfpel_hv+8*stride+8, halfpel_v+8*stride+8, stride, rounding, 8);
442                    break;
443    
444            case 6:
445                    interpolate16x16_lowpass_hv(halfpel_hv, halfpel_h, src, stride, rounding);
446                    interpolate8x8_avg2(dst, halfpel_h, halfpel_hv, stride, rounding, 8);
447                    interpolate8x8_avg2(dst+8, halfpel_h+8, halfpel_hv+8, stride, rounding, 8);
448                    interpolate8x8_avg2(dst+8*stride, halfpel_h+8*stride, halfpel_hv+8*stride, stride, rounding, 8);
449                    interpolate8x8_avg2(dst+8*stride+8, halfpel_h+8*stride+8, halfpel_hv+8*stride+8, stride, rounding, 8);
450                    break;
451    
452            case 7:
453                    interpolate16x16_lowpass_h(halfpel_h, src, stride, rounding);
454                    interpolate8x8_avg2(halfpel_v, src+1, halfpel_h, stride, rounding, 9);
455                    interpolate8x8_avg2(halfpel_v+8, src+1 + 8, halfpel_h+8, stride, rounding, 9);
456                    interpolate8x8_avg2(halfpel_v+8*stride, src+1 + 8*stride, halfpel_h+8*stride, stride, rounding, 9);
457                    interpolate8x8_avg2(halfpel_v+8*stride+8, src+1+8*stride+8, halfpel_h+8*stride+8, stride, rounding, 9);
458    
459                    interpolate16x16_lowpass_v(halfpel_hv, halfpel_v, stride, rounding);
460                    interpolate8x8_avg2(dst, halfpel_hv, halfpel_v, stride, rounding, 8);
461                    interpolate8x8_avg2(dst+8, halfpel_hv+8, halfpel_v+8, stride, rounding, 8);
462                    interpolate8x8_avg2(dst+8*stride, halfpel_hv+8*stride, halfpel_v+8*stride, stride, rounding, 8);
463                    interpolate8x8_avg2(dst+8*stride+8, halfpel_hv+8*stride+8, halfpel_v+8*stride+8, stride, rounding, 8);
464                    break;
465    
466            case 8:
467                interpolate16x16_lowpass_v(dst, src, stride, rounding);
468                    break;
469    
470            case 9:
471                    interpolate16x16_lowpass_h(halfpel_h, src, stride, rounding);
472                    interpolate8x8_avg2(halfpel_v, src, halfpel_h, stride, rounding, 9);
473                    interpolate8x8_avg2(halfpel_v+8, src + 8, halfpel_h+8, stride, rounding, 9);
474                    interpolate8x8_avg2(halfpel_v+8*stride, src + 8*stride, halfpel_h+8*stride, stride, rounding, 9);
475                    interpolate8x8_avg2(halfpel_v+8*stride+8, src+8*stride+8, halfpel_h+8*stride+8, stride, rounding, 9);
476                    interpolate16x16_lowpass_v(dst, halfpel_v, stride, rounding);
477                    break;
478    
479            case 10:
480                    interpolate16x16_lowpass_hv(dst, halfpel_h, src, stride, rounding);
481                    break;
482    
483            case 11:
484                    interpolate16x16_lowpass_h(halfpel_h, src, stride, rounding);
485                    interpolate8x8_avg2(halfpel_v, src+1, halfpel_h, stride, rounding, 9);
486                    interpolate8x8_avg2(halfpel_v+8, src+1 + 8, halfpel_h+8, stride, rounding, 9);
487                    interpolate8x8_avg2(halfpel_v+8*stride, src+1 + 8*stride, halfpel_h+8*stride, stride, rounding, 9);
488                    interpolate8x8_avg2(halfpel_v+8*stride+8, src+1+8*stride+8, halfpel_h+8*stride+8, stride, rounding, 9);
489                    interpolate16x16_lowpass_v(dst, halfpel_v, stride, rounding);
490                    break;
491    
492            case 12:
493                    interpolate16x16_lowpass_v(halfpel_v, src, stride, rounding);
494                    interpolate8x8_avg2(dst, src+stride, halfpel_v, stride, rounding, 8);
495                    interpolate8x8_avg2(dst+8, src+stride+8, halfpel_v+8, stride, rounding, 8);
496                    interpolate8x8_avg2(dst+8*stride, src+stride+8*stride, halfpel_v+8*stride, stride, rounding, 8);
497                    interpolate8x8_avg2(dst+8*stride+8, src+stride+8*stride+8, halfpel_v+8*stride+8, stride, rounding, 8);
498                    break;
499    
500            case 13:
501                    interpolate16x16_lowpass_h(halfpel_h, src, stride, rounding);
502                    interpolate8x8_avg2(halfpel_v, src, halfpel_h, stride, rounding, 9);
503                    interpolate8x8_avg2(halfpel_v+8, src + 8, halfpel_h+8, stride, rounding, 9);
504                    interpolate8x8_avg2(halfpel_v+8*stride, src + 8*stride, halfpel_h+8*stride, stride, rounding, 9);
505                    interpolate8x8_avg2(halfpel_v+8*stride+8, src+8*stride+8, halfpel_h+8*stride+8, stride, rounding, 9);
506    
507                    interpolate16x16_lowpass_v(halfpel_hv, halfpel_v, stride, rounding);
508                    interpolate8x8_avg2(dst, halfpel_hv, halfpel_v+stride, stride, rounding, 8);
509                    interpolate8x8_avg2(dst+8, halfpel_hv+8, halfpel_v+stride+8, stride, rounding, 8);
510                    interpolate8x8_avg2(dst+8*stride, halfpel_hv+8*stride, halfpel_v+stride+8*stride, stride, rounding, 8);
511                    interpolate8x8_avg2(dst+8*stride+8, halfpel_hv+8*stride+8, halfpel_v+stride+8*stride+8, stride, rounding, 8);
512                    break;
513    
514            case 14:
515                    interpolate16x16_lowpass_hv(halfpel_hv, halfpel_h, src, stride, rounding);
516                    interpolate8x8_avg2(dst, halfpel_h+stride, halfpel_hv, stride, rounding, 8);
517                    interpolate8x8_avg2(dst+8, halfpel_h+stride+8, halfpel_hv+8, stride, rounding, 8);
518                    interpolate8x8_avg2(dst+8*stride, halfpel_h+stride+8*stride, halfpel_hv+8*stride, stride, rounding, 8);
519                    interpolate8x8_avg2(dst+8*stride+8, halfpel_h+stride+8*stride+8, halfpel_hv+8*stride+8, stride, rounding, 8);
520                    break;
521    
522            case 15:
523                    interpolate16x16_lowpass_h(halfpel_h, src, stride, rounding);
524                    interpolate8x8_avg2(halfpel_v, src+1, halfpel_h, stride, rounding, 9);
525                    interpolate8x8_avg2(halfpel_v+8, src+1 + 8, halfpel_h+8, stride, rounding, 9);
526                    interpolate8x8_avg2(halfpel_v+8*stride, src+1 + 8*stride, halfpel_h+8*stride, stride, rounding, 9);
527                    interpolate8x8_avg2(halfpel_v+8*stride+8, src+1+8*stride+8, halfpel_h+8*stride+8, stride, rounding, 9);
528    
529                    interpolate16x16_lowpass_v(halfpel_hv, halfpel_v, stride, rounding);
530                    interpolate8x8_avg2(dst, halfpel_hv, halfpel_v+stride, stride, rounding, 8);
531                    interpolate8x8_avg2(dst+8, halfpel_hv+8, halfpel_v+stride+8, stride, rounding, 8);
532                    interpolate8x8_avg2(dst+8*stride, halfpel_hv+8*stride, halfpel_v+stride+8*stride, stride, rounding, 8);
533                    interpolate8x8_avg2(dst+8*stride+8, halfpel_hv+8*stride+8, halfpel_v+stride+8*stride+8, stride, rounding, 8);
534                  break;                  break;
535      }      }
536  }  }
537    
538    #endif

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.10.2.3

No admin address has been configured
ViewVC Help
Powered by ViewVC 1.0.4