-
Notifications
You must be signed in to change notification settings - Fork 61
/
change-libavcodec-header.patch
281 lines (246 loc) · 8.73 KB
/
change-libavcodec-header.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
From 776f957791b3bcac91f949fab2e1b785f829f4c5 Mon Sep 17 00:00:00 2001
From: Sta Zhu <[email protected]>
Date: Mon, 18 Nov 2024 19:39:32 +0800
Subject: [PATCH] Video: Update `libavcodec` header
The recent ffmpeg changes doesn't match with chromium include
configs, need to change the header manually to fix this.
---
libavcodec/hevc/cabac.c | 2 +-
libavcodec/hevc/dsp_template.c | 10 ++++-----
libavcodec/hevc/filter.c | 2 +-
libavcodec/hevc/hevcdec.c | 36 ++++++++++++++++-----------------
libavcodec/hevc/mvs.c | 2 +-
libavcodec/hevc/parse.c | 4 ++--
libavcodec/hevc/parser.c | 6 +++---
libavcodec/hevc/pred_template.c | 2 +-
libavcodec/hevc/ps.c | 8 ++++----
libavcodec/hevc/ps_enc.c | 4 ++--
libavcodec/hevc/refs.c | 8 ++++----
libavcodec/hevc/sei.c | 4 ++--
12 files changed, 43 insertions(+), 45 deletions(-)
diff --git a/libavcodec/hevc/cabac.c b/libavcodec/hevc/cabac.c
index 892dd1c215..362dda6beb 100644
--- a/libavcodec/hevc/cabac.c
+++ b/libavcodec/hevc/cabac.c
@@ -24,7 +24,7 @@
#include "libavutil/attributes.h"
#include "libavutil/common.h"
-#include "cabac_functions.h"
+#include "libavcodec/cabac_functions.h"
#include "data.h"
#include "hevc.h"
#include "hevcdec.h"
diff --git a/libavcodec/hevc/dsp_template.c b/libavcodec/hevc/dsp_template.c
index a0f79c2673..b4f37237d7 100644
--- a/libavcodec/hevc/dsp_template.c
+++ b/libavcodec/hevc/dsp_template.c
@@ -20,13 +20,13 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#include "get_bits.h"
+#include "libavcodec/get_bits.h"
#include "hevcdec.h"
-#include "bit_depth_template.c"
+#include "libavcodec/bit_depth_template.c"
#include "dsp.h"
-#include "h26x/h2656_sao_template.c"
-#include "h26x/h2656_inter_template.c"
+#include "libavcodec/h26x/h2656_sao_template.c"
+#include "libavcodec/h26x/h2656_inter_template.c"
static void FUNC(put_pcm)(uint8_t *_dst, ptrdiff_t stride, int width, int height,
GetBitContext *gb, int pcm_bit_depth)
@@ -817,7 +817,7 @@ static void FUNC(put_hevc_epel_bi_w_hv)(uint8_t *_dst, ptrdiff_t _dststride,
#define TQ2 pix[2 * xstride + 3 * ystride]
#define TQ3 pix[3 * xstride + 3 * ystride]
-#include "h26x/h2656_deblock_template.c"
+#include "libavcodec/h26x/h2656_deblock_template.c"
static void FUNC(hevc_loop_filter_luma)(uint8_t *_pix,
ptrdiff_t _xstride, ptrdiff_t _ystride,
diff --git a/libavcodec/hevc/filter.c b/libavcodec/hevc/filter.c
index 68ae0e9ef6..e897ad5d58 100644
--- a/libavcodec/hevc/filter.c
+++ b/libavcodec/hevc/filter.c
@@ -26,7 +26,7 @@
#include "libavutil/internal.h"
#include "hevcdec.h"
-#include "progressframe.h"
+#include "libavcodec/progressframe.h"
#define LUMA 0
#define CB 1
diff --git a/libavcodec/hevc/hevcdec.c b/libavcodec/hevc/hevcdec.c
index 57881bc995..f108dbdd78 100644
--- a/libavcodec/hevc/hevcdec.c
+++ b/libavcodec/hevc/hevcdec.c
@@ -37,24 +37,24 @@
#include "libavutil/stereo3d.h"
#include "libavutil/timecode.h"
-#include "aom_film_grain.h"
-#include "bswapdsp.h"
-#include "cabac_functions.h"
-#include "codec_internal.h"
-#include "container_fifo.h"
-#include "decode.h"
-#include "golomb.h"
+#include "libavcodec/aom_film_grain.h"
+#include "libavcodec/bswapdsp.h"
+#include "libavcodec/cabac_functions.h"
+#include "libavcodec/codec_internal.h"
+#include "libavcodec/container_fifo.h"
+#include "libavcodec/decode.h"
+#include "libavcodec/golomb.h"
#include "hevc.h"
#include "parse.h"
#include "hevcdec.h"
-#include "hwaccel_internal.h"
-#include "hwconfig.h"
-#include "internal.h"
-#include "profiles.h"
-#include "progressframe.h"
-#include "refstruct.h"
-#include "thread.h"
-#include "threadprogress.h"
+#include "libavcodec/hwaccel_internal.h"
+#include "libavcodec/hwconfig.h"
+#include "libavcodec/internal.h"
+#include "libavcodec/profiles.h"
+#include "libavcodec/progressframe.h"
+#include "libavcodec/refstruct.h"
+#include "libavcodec/thread.h"
+#include "libavcodec/threadprogress.h"
static const uint8_t hevc_pel_weight[65] = { [2] = 0, [4] = 1, [6] = 2, [8] = 3, [12] = 4, [16] = 5, [24] = 6, [32] = 7, [48] = 8, [64] = 9 };
@@ -414,8 +414,7 @@ static int export_stream_params_from_sei(HEVCContext *s)
if ((s->sei.common.film_grain_characteristics &&
s->sei.common.film_grain_characteristics->present) ||
- (s->sei.common.aom_film_grain &&
- s->sei.common.aom_film_grain->enable)) {
+ (s->sei.common.aom_film_grain.enable)) {
avctx->properties |= FF_CODEC_PROPERTY_FILM_GRAIN;
}
@@ -3273,8 +3272,7 @@ static int hevc_frame_start(HEVCContext *s, HEVCLayerContext *l,
s->cur_frame->needs_fg =
((s->sei.common.film_grain_characteristics &&
s->sei.common.film_grain_characteristics->present) ||
- (s->sei.common.aom_film_grain &&
- s->sei.common.aom_film_grain->enable)) &&
+ (s->sei.common.aom_film_grain.enable)) &&
!(s->avctx->export_side_data & AV_CODEC_EXPORT_DATA_FILM_GRAIN) &&
!s->avctx->hwaccel;
diff --git a/libavcodec/hevc/mvs.c b/libavcodec/hevc/mvs.c
index 55f115ad0c..61c9e4e086 100644
--- a/libavcodec/hevc/mvs.c
+++ b/libavcodec/hevc/mvs.c
@@ -23,7 +23,7 @@
#include "hevc.h"
#include "hevcdec.h"
-#include "progressframe.h"
+#include "libavcodec/progressframe.h"
static const uint8_t l0_l1_cand_idx[12][2] = {
{ 0, 1, },
diff --git a/libavcodec/hevc/parse.c b/libavcodec/hevc/parse.c
index 29f21a5966..2f519380fb 100644
--- a/libavcodec/hevc/parse.c
+++ b/libavcodec/hevc/parse.c
@@ -16,8 +16,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#include "bytestream.h"
-#include "h2645_parse.h"
+#include "libavcodec/bytestream.h"
+#include "libavcodec/h2645_parse.h"
#include "hevc.h"
#include "parse.h"
diff --git a/libavcodec/hevc/parser.c b/libavcodec/hevc/parser.c
index 16b40e2b10..e94b6905c9 100644
--- a/libavcodec/hevc/parser.c
+++ b/libavcodec/hevc/parser.c
@@ -23,13 +23,13 @@
#include "libavutil/common.h"
#include "libavutil/mem.h"
-#include "golomb.h"
+#include "libavcodec/golomb.h"
#include "hevc.h"
#include "parse.h"
#include "ps.h"
#include "sei.h"
-#include "h2645_parse.h"
-#include "parser.h"
+#include "libavcodec/h2645_parse.h"
+#include "libavcodec/parser.h"
#define START_CODE 0x000001 ///< start_code_prefix_one_3bytes
diff --git a/libavcodec/hevc/pred_template.c b/libavcodec/hevc/pred_template.c
index b4c2fcf506..d873c1c5b6 100644
--- a/libavcodec/hevc/pred_template.c
+++ b/libavcodec/hevc/pred_template.c
@@ -22,7 +22,7 @@
#include "libavutil/pixdesc.h"
-#include "bit_depth_template.c"
+#include "libavcodec/bit_depth_template.c"
#include "pred.h"
#define POS(x, y) src[(x) + stride * (y)]
diff --git a/libavcodec/hevc/ps.c b/libavcodec/hevc/ps.c
index a1d352eec5..3eabe6c965 100644
--- a/libavcodec/hevc/ps.c
+++ b/libavcodec/hevc/ps.c
@@ -25,12 +25,12 @@
#include "libavutil/imgutils.h"
#include "libavutil/mem.h"
-#include "golomb.h"
-#include "h2645_vui.h"
+#include "libavcodec/golomb.h"
+#include "libavcodec/h2645_vui.h"
#include "data.h"
#include "ps.h"
-#include "profiles.h"
-#include "refstruct.h"
+#include "libavcodec/profiles.h"
+#include "libavcodec/refstruct.h"
static const uint8_t default_scaling_list_intra[] = {
16, 16, 16, 16, 17, 18, 21, 24,
diff --git a/libavcodec/hevc/ps_enc.c b/libavcodec/hevc/ps_enc.c
index 7fbcb3ba4e..4e44f849ba 100644
--- a/libavcodec/hevc/ps_enc.c
+++ b/libavcodec/hevc/ps_enc.c
@@ -18,9 +18,9 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#include "put_golomb.h"
+#include "libavcodec/put_golomb.h"
#include "ps.h"
-#include "put_bits.h"
+#include "libavcodec/put_bits.h"
static void write_ptl_layer(PutBitContext *pb, PTLCommon *ptl)
{
diff --git a/libavcodec/hevc/refs.c b/libavcodec/hevc/refs.c
index 6ba667e9f5..ee6f5a3f11 100644
--- a/libavcodec/hevc/refs.c
+++ b/libavcodec/hevc/refs.c
@@ -24,12 +24,12 @@
#include "libavutil/mem.h"
#include "libavutil/stereo3d.h"
-#include "container_fifo.h"
-#include "decode.h"
+#include "libavcodec/container_fifo.h"
+#include "libavcodec/decode.h"
#include "hevc.h"
#include "hevcdec.h"
-#include "progressframe.h"
-#include "refstruct.h"
+#include "libavcodec/progressframe.h"
+#include "libavcodec/refstruct.h"
void ff_hevc_unref_frame(HEVCFrame *frame, int flags)
{
diff --git a/libavcodec/hevc/sei.c b/libavcodec/hevc/sei.c
index e11a33773c..aa6acfca6b 100644
--- a/libavcodec/hevc/sei.c
+++ b/libavcodec/hevc/sei.c
@@ -22,8 +22,8 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
-#include "bytestream.h"
-#include "golomb.h"
+#include "libavcodec/bytestream.h"
+#include "libavcodec/golomb.h"
#include "ps.h"
#include "sei.h"
--
2.47.1