tools/decode_simple: initialize decoder parameters with container info

pull/389/head
Anton Khirnov 2 years ago
parent 992e984fa8
commit 554c6d7cb1
  1. 4
      tools/decode_simple.c

@ -149,6 +149,10 @@ int ds_open(DecodeContext *dc, const char *url, int stream_idx)
if (!dc->decoder) if (!dc->decoder)
return AVERROR(ENOMEM); return AVERROR(ENOMEM);
ret = avcodec_parameters_to_context(dc->decoder, dc->stream->codecpar);
if (ret < 0)
goto fail;
return 0; return 0;
fail: fail:

Loading…
Cancel
Save