diff options
author | wm4 <wm4@nowhere> | 2020-09-03 14:13:17 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2020-09-03 14:13:17 +0200 |
commit | 80bf6b26ba800b0bf65b40123940481e4e9911b7 (patch) | |
tree | 65106662d790ffd7b8c6b3f4562e9063c7913506 /common/encode.h | |
parent | 2761f37fe48aa5b3aae3c4d4ce611a6ef07db0ae (diff) | |
download | mpv-80bf6b26ba800b0bf65b40123940481e4e9911b7.tar.bz2 mpv-80bf6b26ba800b0bf65b40123940481e4e9911b7.tar.xz |
encode: disable unsupported media types automatically
If you encode to e.g. an audio-only format, then video is disabled
automatically. This also takes care of the very cryptic error message.
It says "[vo/lavc] codec for video not found". Sort of true, but
obscures the real problem if it's e.g. an audio-only format.
Diffstat (limited to 'common/encode.h')
-rw-r--r-- | common/encode.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/common/encode.h b/common/encode.h index 974651e103..c951e95d51 100644 --- a/common/encode.h +++ b/common/encode.h @@ -54,6 +54,8 @@ bool encode_lavc_free(struct encode_lavc_context *ctx); void encode_lavc_discontinuity(struct encode_lavc_context *ctx); bool encode_lavc_showhelp(struct mp_log *log, struct encode_opts *options); int encode_lavc_getstatus(struct encode_lavc_context *ctx, char *buf, int bufsize, float relative_position); +bool encode_lavc_stream_type_ok(struct encode_lavc_context *ctx, + enum stream_type type); void encode_lavc_expect_stream(struct encode_lavc_context *ctx, enum stream_type type); void encode_lavc_set_metadata(struct encode_lavc_context *ctx, |