[Libav-user] Codec type or id mismatches.

Carl Eugen Hoyos ceffmpeg at gmail.com
Mon Mar 11 21:03:08 EET 2019


2019-02-25 11:28 GMT+01:00, ABDALLAH Moussa <Moussa.ABDALLAH at nexeya.com>:

> I'm trying to write a stream video from an ip camero to a file using a
> source that I get on the web and I got an error on the function
> avcodec_open2(codec_ctx, codec, NULL).
> Indeed when I compile the program and I execute it this is what I get on the
> console : [h264 @ 0x33670c0] Codec type or id mismatches.

Are you sure that format_ctx->streams[video_stream_index]->codec->codec_id
is AV_CODEC_ID_H264?

Carl Eugen


More information about the Libav-user mailing list