diff options
author | Solomon Peachy <pizza@shaftnet.org> | 2021-08-04 09:49:56 -0400 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2022-10-02 11:57:20 -0400 |
commit | d25d24812e8120c0eb133a412287ac030eb185c9 (patch) | |
tree | d1c336d5d81c39366672c86f30c484f96e24a469 /apps/plugins/mpegplayer/libmpeg2/motion_comp.h | |
parent | 9ce5b2a2eda5c7101898476adaa3533e0ba5db82 (diff) | |
download | rockbox-d25d24812e8120c0eb133a412287ac030eb185c9.tar.gz rockbox-d25d24812e8120c0eb133a412287ac030eb185c9.zip |
RFC: Get rid of mpegplayer plugin
It might have made sense once upon a time, but in today's world...
Change-Id: I5d638e6f7a2308c50ab12bd901338f02cf426aae
Diffstat (limited to 'apps/plugins/mpegplayer/libmpeg2/motion_comp.h')
-rw-r--r-- | apps/plugins/mpegplayer/libmpeg2/motion_comp.h | 86 |
1 files changed, 0 insertions, 86 deletions
diff --git a/apps/plugins/mpegplayer/libmpeg2/motion_comp.h b/apps/plugins/mpegplayer/libmpeg2/motion_comp.h deleted file mode 100644 index 4737e72cab..0000000000 --- a/apps/plugins/mpegplayer/libmpeg2/motion_comp.h +++ /dev/null | |||
@@ -1,86 +0,0 @@ | |||
1 | /* | ||
2 | * motion_comp.h | ||
3 | * Copyright (C) 2000-2003 Michel Lespinasse <walken@zoy.org> | ||
4 | * Copyright (C) 1999-2000 Aaron Holtzman <aholtzma@ess.engr.uvic.ca> | ||
5 | * | ||
6 | * This file is part of mpeg2dec, a free MPEG-2 video stream decoder. | ||
7 | * See http://libmpeg2.sourceforge.net/ for updates. | ||
8 | * | ||
9 | * mpeg2dec is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License as published by | ||
11 | * the Free Software Foundation; either version 2 of the License, or | ||
12 | * (at your option) any later version. | ||
13 | * | ||
14 | * mpeg2dec is distributed in the hope that it will be useful, | ||
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
17 | * GNU General Public License for more details. | ||
18 | * | ||
19 | * You should have received a copy of the GNU General Public License | ||
20 | * along with this program; if not, write to the Free Software | ||
21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
22 | * | ||
23 | * $Id$ | ||
24 | */ | ||
25 | |||
26 | |||
27 | #define avg2(a,b) ((a+b+1)>>1) | ||
28 | #define avg4(a,b,c,d) ((a+b+c+d+2)>>2) | ||
29 | |||
30 | #define predict_o(i) (ref[i]) | ||
31 | #define predict_x(i) (avg2 (ref[i], ref[i+1])) | ||
32 | #define predict_y(i) (avg2 (ref[i], (ref+stride)[i])) | ||
33 | #define predict_xy(i) (avg4 (ref[i], ref[i+1], \ | ||
34 | (ref+stride)[i], (ref+stride)[i+1])) | ||
35 | |||
36 | #define put(predictor,i) dest[i] = predictor (i) | ||
37 | #define avg(predictor,i) dest[i] = avg2 (predictor (i), dest[i]) | ||
38 | |||
39 | /* mc function template */ | ||
40 | #define MC_FUNC(op, xy) \ | ||
41 | MC_FUNC_16(op, xy) \ | ||
42 | MC_FUNC_8(op, xy) | ||
43 | |||
44 | #define MC_FUNC_16(op, xy) \ | ||
45 | void MC_##op##_##xy##_16 (uint8_t * dest, const uint8_t * ref, \ | ||
46 | const int stride, int height) \ | ||
47 | { \ | ||
48 | do { \ | ||
49 | op (predict_##xy, 0); \ | ||
50 | op (predict_##xy, 1); \ | ||
51 | op (predict_##xy, 2); \ | ||
52 | op (predict_##xy, 3); \ | ||
53 | op (predict_##xy, 4); \ | ||
54 | op (predict_##xy, 5); \ | ||
55 | op (predict_##xy, 6); \ | ||
56 | op (predict_##xy, 7); \ | ||
57 | op (predict_##xy, 8); \ | ||
58 | op (predict_##xy, 9); \ | ||
59 | op (predict_##xy, 10); \ | ||
60 | op (predict_##xy, 11); \ | ||
61 | op (predict_##xy, 12); \ | ||
62 | op (predict_##xy, 13); \ | ||
63 | op (predict_##xy, 14); \ | ||
64 | op (predict_##xy, 15); \ | ||
65 | ref += stride; \ | ||
66 | dest += stride; \ | ||
67 | } while (--height); \ | ||
68 | } | ||
69 | |||
70 | #define MC_FUNC_8(op, xy) \ | ||
71 | void MC_##op##_##xy##_8 (uint8_t * dest, const uint8_t * ref, \ | ||
72 | const int stride, int height) \ | ||
73 | { \ | ||
74 | do { \ | ||
75 | op (predict_##xy, 0); \ | ||
76 | op (predict_##xy, 1); \ | ||
77 | op (predict_##xy, 2); \ | ||
78 | op (predict_##xy, 3); \ | ||
79 | op (predict_##xy, 4); \ | ||
80 | op (predict_##xy, 5); \ | ||
81 | op (predict_##xy, 6); \ | ||
82 | op (predict_##xy, 7); \ | ||
83 | ref += stride; \ | ||
84 | dest += stride; \ | ||
85 | } while (--height); \ | ||
86 | } | ||