[FFmpeg-user] Specifying a codec by name
Sreenath BH
bhsreenath at gmail.com
Wed Mar 16 05:19:07 CET 2016
On 3/15/16, Moritz Barsnick <barsnick at gmx.net> wrote:
> Hi,
>
> On Tue, Mar 15, 2016 at 15:18:22 +0530, Sreenath BH wrote:
>> We want to use the same ffmpeg libraries to load either the nvidia or
>> the libx264 codec in our program.
>
> For the use of the libraries, please refer to the libav-user list:
> https://lists.libav.org/mailman/listinfo/libav-devel/
>
>> However, the function avcodec_open2 takes the codec ID as the argument.
>>
>> How do I specify the codec to be used by its name, instead of the codec
>> ID?
>
> Well, if I read the documentation of that function, it clearly says:
> https://www.ffmpeg.org/doxygen/2.7/group__lavc__core.html#ga11f785a188d7d9df71621001465b0f1d
>
> "The functions avcodec_find_decoder_by_name(),
> avcodec_find_encoder_by_name(), avcodec_find_decoder() and
> avcodec_find_encoder() provide an easy way for retrieving a codec."
>
> I know nothing more than that, sorry. :-)
>
> HTH,
> Moritz
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>
Hi,
Thanks. That's exactly what I wanted.
And apologies for posting a question before reading available online
documentation first.
-Sreenath
More information about the ffmpeg-user
mailing list