From 0ab3184526e7b9b95c06a3ec7a6674283a5922d0 Mon Sep 17 00:00:00 2001 From: wm4 Date: Sun, 29 Apr 2018 19:42:18 +0200 Subject: encode: get rid of the output packet queue Until recently, ao_lavc and vo_lavc started encoding whenever the core happened to send them data. Since audio and video are not initialized at the same time, and the muxer was not necessarily opened when the first encoder started to produce data, the resulting packets were put into a queue. As soon as the muxer was opened, the queue was flushed. Change this to make the core wait with sending data until all encoders are initialized. This has the advantage that we don't need to queue up the packets. --- common/encode.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'common/encode.h') diff --git a/common/encode.h b/common/encode.h index 4a09fedaa2..62a8b094e9 100644 --- a/common/encode.h +++ b/common/encode.h @@ -56,6 +56,8 @@ 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); void encode_lavc_expect_stream(struct encode_lavc_context *ctx, enum stream_type type); +void encode_lavc_stream_eof(struct encode_lavc_context *ctx, + enum stream_type type); void encode_lavc_set_metadata(struct encode_lavc_context *ctx, struct mp_tags *metadata); void encode_lavc_set_audio_pts(struct encode_lavc_context *ctx, double pts); -- cgit v1.2.3