Revision 10787,
5.1 KB
checked in by ara_t, 8 years ago
(diff) |
add ffmpeg2.0.patch
|
-
Binary files a/plugins/ffmpeg/.lqt_ffmpeg.c.swp and b/plugins/ffmpeg/.lqt_ffmpeg.c.swp differ
diff -rupN a/plugins/ffmpeg/ffmpeg.h b/plugins/ffmpeg/ffmpeg.h
a
|
b
|
void lqt_ffmpeg_set_parameter(AVCodecCon |
45 | 45 | |
46 | 46 | |
47 | 47 | #endif |
| 48 | #define AVCODEC_MAX_AUDIO_FRAME_SIZE 192000 |
| 49 | #define CODEC_FLAG2_STRICT_GOP 0x00000002 |
| 50 | #define CODEC_FLAG_QP_RD 0x08000000 |
| 51 | #define CODEC_FLAG_CBP_RD 0x04000000 |
-
diff -rupN a/plugins/ffmpeg/lqt_ffmpeg.c b/plugins/ffmpeg/lqt_ffmpeg.c
a
|
b
|
int ffmpeg_num_video_codecs = -1; |
89 | 89 | PARAM_QSCALE, \ |
90 | 90 | PARAM_QCOMPRESS, \ |
91 | 91 | PARAM_QBLUR, \ |
92 | | PARAM_QUANTIZER_NOISE_SHAPING, \ |
93 | 92 | PARAM_TRELLIS |
94 | 93 | |
95 | | #define ENCODE_PARAM_VIDEO_QUANTIZER_IP \ |
96 | | ENCODE_PARAM_VIDEO_QUANTIZER_I, \ |
97 | | PARAM_I_QUANT_FACTOR, \ |
98 | | PARAM_I_QUANT_OFFSET |
99 | | |
100 | | #define ENCODE_PARAM_VIDEO_QUANTIZER_IPB \ |
101 | | ENCODE_PARAM_VIDEO_QUANTIZER_IP, \ |
102 | | PARAM_B_QUANT_FACTOR, \ |
103 | | PARAM_B_QUANT_OFFSET |
104 | | |
105 | 94 | #define ENCODE_PARAM_VIDEO_FRAMETYPES_IP \ |
106 | 95 | { \ |
107 | 96 | .name = "frame_types", \ |
… |
… |
static lqt_parameter_info_static_t encod |
207 | 196 | ENCODE_PARAM_VIDEO_FRAMETYPES_IPB, |
208 | 197 | PARAM_FLAG_AC_PRED_MPEG4, |
209 | 198 | ENCODE_PARAM_VIDEO_RATECONTROL, |
210 | | ENCODE_PARAM_VIDEO_QUANTIZER_IPB, |
211 | 199 | PARAM_FLAG_CBP_RD, |
212 | 200 | ENCODE_PARAM_VIDEO_ME, |
213 | 201 | PARAM_FLAG_GMC, |
… |
… |
static lqt_parameter_info_static_t encod |
225 | 213 | static lqt_parameter_info_static_t encode_parameters_dx50[] = { |
226 | 214 | ENCODE_PARAM_VIDEO_FRAMETYPES_IP, |
227 | 215 | ENCODE_PARAM_VIDEO_RATECONTROL, |
228 | | ENCODE_PARAM_VIDEO_QUANTIZER_IP, |
229 | 216 | ENCODE_PARAM_VIDEO_ME, |
230 | 217 | ENCODE_PARAM_VIDEO_ME_PRE, |
231 | 218 | ENCODE_PARAM_VIDEO_MASKING, |
… |
… |
static lqt_parameter_info_static_t encod |
237 | 224 | static lqt_parameter_info_static_t encode_parameters_h263[] = { |
238 | 225 | ENCODE_PARAM_VIDEO_FRAMETYPES_IP, |
239 | 226 | ENCODE_PARAM_VIDEO_RATECONTROL, |
240 | | ENCODE_PARAM_VIDEO_QUANTIZER_IP, |
241 | 227 | ENCODE_PARAM_VIDEO_ME, |
242 | 228 | PARAM_FLAG_4MV, |
243 | 229 | ENCODE_PARAM_VIDEO_ME_PRE, |
… |
… |
static lqt_parameter_info_static_t encod |
250 | 236 | static lqt_parameter_info_static_t encode_parameters_h263p[] = { |
251 | 237 | ENCODE_PARAM_VIDEO_FRAMETYPES_IP, |
252 | 238 | ENCODE_PARAM_VIDEO_RATECONTROL, |
253 | | ENCODE_PARAM_VIDEO_QUANTIZER_IP, |
254 | 239 | ENCODE_PARAM_VIDEO_ME, |
255 | 240 | PARAM_FLAG_4MV, |
256 | 241 | ENCODE_PARAM_VIDEO_ME_PRE, |
… |
… |
static lqt_parameter_info_static_t encod |
264 | 249 | static lqt_parameter_info_static_t encode_parameters_msmpeg4v3[] = { |
265 | 250 | ENCODE_PARAM_VIDEO_FRAMETYPES_IP, |
266 | 251 | ENCODE_PARAM_VIDEO_RATECONTROL, |
267 | | ENCODE_PARAM_VIDEO_QUANTIZER_IP, |
268 | 252 | ENCODE_PARAM_VIDEO_ME, |
269 | 253 | ENCODE_PARAM_VIDEO_ME_PRE, |
270 | 254 | ENCODE_PARAM_VIDEO_MASKING, |
-
diff -rupN a/plugins/ffmpeg/params.c b/plugins/ffmpeg/params.c
a
|
b
|
void lqt_ffmpeg_set_parameter(AVCodecCon |
202 | 202 | PARAM_INT("ff_max_b_frames",max_b_frames); |
203 | 203 | PARAM_FLOAT("ff_b_quant_factor",b_quant_factor); |
204 | 204 | PARAM_INT("ff_b_frame_strategy",b_frame_strategy); |
| 205 | #if (LIBAVCODEC_VERSION_MAJOR < 55) |
205 | 206 | PARAM_INT("ff_luma_elim_threshold",luma_elim_threshold); |
206 | 207 | PARAM_INT("ff_chroma_elim_threshold",chroma_elim_threshold); |
| 208 | #endif |
207 | 209 | PARAM_INT("ff_strict_std_compliance",strict_std_compliance); |
208 | 210 | PARAM_QP2LAMBDA("ff_b_quant_offset",b_quant_offset); |
209 | 211 | PARAM_INT("ff_rc_min_rate",rc_min_rate); |
… |
… |
void lqt_ffmpeg_set_parameter(AVCodecCon |
241 | 243 | PARAM_QP2LAMBDA("ff_lmax", lmax); |
242 | 244 | PARAM_INT("ff_noise_reduction",noise_reduction); |
243 | 245 | PARAM_INT_SCALE("ff_rc_initial_buffer_occupancy",rc_initial_buffer_occupancy,1000); |
| 246 | #if #if (LIBAVCODEC_VERSION_MAJOR < 55) |
244 | 247 | PARAM_INT("ff_inter_threshold",inter_threshold); |
245 | 248 | PARAM_INT("ff_quantizer_noise_shaping",quantizer_noise_shaping); |
| 249 | #endif |
246 | 250 | PARAM_INT("ff_thread_count",thread_count); |
247 | 251 | PARAM_INT("ff_me_threshold",me_threshold); |
248 | 252 | PARAM_INT("ff_mb_threshold",mb_threshold); |
-
diff -rupN a/plugins/ffmpeg/params.h b/plugins/ffmpeg/params.h
a
|
b
|
the reference. Unused for constant quant |
177 | 177 | .val_max = { .val_int = 1 }, \ |
178 | 178 | } |
179 | 179 | |
| 180 | #if (LIBAVCODEC_VERSION_MAJOR < 55) |
180 | 181 | #define PARAM_LUMA_ELIM_THRESHOLD \ |
181 | 182 | { \ |
182 | 183 | .name = "ff_luma_elim_threshold", \ |
… |
… |
recommendation") \ |
202 | 203 | chrominamce. Negative values also consider dc \ |
203 | 204 | coefficient. 7 is JVT recommendation") \ |
204 | 205 | } |
| 206 | #endif |
205 | 207 | |
206 | 208 | #define PARAM_STRICT_STANDARD_COMPLIANCE \ |
207 | 209 | { \ |
… |
… |
with max and/or min bitrate, this must b |
739 | 741 | |
740 | 742 | /* Does nothing */ |
741 | 743 | /** Frame types */ |
| 744 | #if (LIBAVCODEC_VERSION_MAJOR < 55) |
742 | 745 | #define PARAM_INTER_THRESHOLD \ |
743 | 746 | { \ |
744 | 747 | .name = "ff_inter_threshold", \ |
… |
… |
with max and/or min bitrate, this must b |
759 | 762 | .help_string = TRS("Choose quantization such that noise will be masked by " \ |
760 | 763 | "similar-frequency content in the image") \ |
761 | 764 | } |
| 765 | #endif |
762 | 766 | |
763 | 767 | /** Motion estimation */ |
764 | 768 | #define PARAM_ME_THRESHOLD \ |
Note: See
TracBrowser
for help on using the repository browser.