<div dir="ltr">Thanks, I had to init the InputContext and then set its codec id and codec before opening it.<div><br></div><div><div>        AVDictionary* dictionary = NULL;</div><div><span style="white-space:pre-wrap">       </span>av_dict_set(&dictionary, "video_size", "1280x720", NULL);</div><div><span style="white-space:pre-wrap">        </span>av_dict_set(&dictionary, "framerate", "30", NULL);</div><div><span style="white-space:pre-wrap">       </span></div><div><span style="white-space:pre-wrap"> </span>ifmt_ctx = avformat_alloc_context();</div><div><span style="white-space:pre-wrap">     </span>ifmt_ctx->video_codec_id = AV_CODEC_ID_MJPEG;</div><div><span style="white-space:pre-wrap"> </span>av_format_set_video_codec(ifmt_ctx, opened_mjpeg_codec);</div></div><div><br></div><div>        avformat_open_input(&ifmt_ctx, filename, inputFormat, &dictionary);<br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Oct 21, 2015 at 5:34 PM, Carl Eugen Hoyos <span dir="ltr"><<a href="mailto:cehoyos@ag.or.at" target="_blank">cehoyos@ag.or.at</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">Casey Price <cprice1317@...> writes:<br>
<br>
>       av_dict_set(&opt, "vcodec", "mjpeg", 0);<br>
<br>
>       av_dict_set(&opt, "s", "1280x720", 0);<br>
<br>
</span>The option is actually called "video_size"<br>
<span class=""><br>
>         av_dict_set(&opt , "framerate", "30", 0);<br>
<br>
</span>This looks correct.<br>
<br>
I am quite sure that "vcodec" is wrong, you<br>
probably have to pass the opened decoder to<br>
avformat (but I don't really know).<br>
<br>
Carl Eugen<br>
_______________________________________________<br>
Libav-user mailing list<br>
<a href="mailto:Libav-user@ffmpeg.org">Libav-user@ffmpeg.org</a><br>
<a href="http://ffmpeg.org/mailman/listinfo/libav-user" rel="noreferrer" target="_blank">http://ffmpeg.org/mailman/listinfo/libav-user</a><br>
</blockquote></div><br></div>