[Libav-user] Getting options

Patrick Zielinski ptothez at live.ca
Fri Feb 10 20:53:11 CET 2012


/** * Look for an option in an object. Consider only options which * have all the specified flags set. * * @param[in] obj A pointer to a struct whose first element is a *                pointer to an AVClass. *                Alternatively a double pointer to an AVClass, if *                AV_OPT_SEARCH_FAKE_OBJ search flag is set. * @param[in] name The name of the option to look for. * @param[in] unit When searching for named constants, name of the unit *                 it belongs to. * @param opt_flags Find only options with all the specified flags set (AV_OPT_FLAG). * @param search_flags A combination of AV_OPT_SEARCH_*. * * @return A pointer to the option found, or NULL if no option *         was found. * * @note Options found with AV_OPT_SEARCH_CHILDREN flag may not be settable * directly with av_set_string3(). Use special calls which take an options * AVDictionary (e.g. avformat_open_input()) to set options found with this * flag. */const AVOption *av_opt_find(void *obj, const char *name, const char *unit,                            int opt_flags, int search_flags);

I don't get the unit and opt_flags parameter, let's say I want to get width from an ACCodecContext, how do I do it?
const AVOption *options = av_opt_find(codecCtx, option, NULL, NULL, NULL); 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://ffmpeg.org/pipermail/libav-user/attachments/20120210/deb8cb45/attachment.html>


More information about the Libav-user mailing list