diff options
author | Alfred E. Heggestad <alfred.heggestad@gmail.com> | 2017-07-20 17:34:34 +0200 |
---|---|---|
committer | Alfred E. Heggestad <alfred.heggestad@gmail.com> | 2017-07-20 17:34:34 +0200 |
commit | 53cf99cd0fde4eca4fcb8400809b0346a4cb8d32 (patch) | |
tree | 040db46f0382c4f84f353f7f7c5262a96913dc67 /modules | |
parent | 2f753617d718b3467e69029e7625d1b274b8feae (diff) |
avcodec: use level_idc=0x1f for x264
Diffstat (limited to 'modules')
-rw-r--r-- | modules/avcodec/avcodec.c | 2 | ||||
-rw-r--r-- | modules/avcodec/encode.c | 5 |
2 files changed, 3 insertions, 4 deletions
diff --git a/modules/avcodec/avcodec.c b/modules/avcodec/avcodec.c index f8d9830..bfcde82 100644 --- a/modules/avcodec/avcodec.c +++ b/modules/avcodec/avcodec.c @@ -47,7 +47,7 @@ */ -const uint8_t h264_level_idc = 0x0c; +const uint8_t h264_level_idc = 0x1f; AVCodec *avcodec_h264enc; /* optional; specified H.264 encoder */ AVCodec *avcodec_h264dec; /* optional; specified H.264 decoder */ diff --git a/modules/avcodec/encode.c b/modules/avcodec/encode.c index 3f9f11d..9aeea34 100644 --- a/modules/avcodec/encode.c +++ b/modules/avcodec/encode.c @@ -415,11 +415,10 @@ static int open_encoder_x264(struct videnc_state *st, struct videnc_param *prm, { x264_param_t xprm; - x264_param_default(&xprm); + if (x264_param_default_preset(&xprm, "ultrafast", "zerolatency")) + return ENOSYS; -#if X264_BUILD >= 87 x264_param_apply_profile(&xprm, "baseline"); -#endif xprm.i_level_idc = h264_level_idc; xprm.i_width = size->w; |