On 04/04/2011 11:35 AM, Justin Ruggles wrote:

> On 04/04/2011 11:30 AM, Ronald S. Bultje wrote:
> 
>> Hi,
>>
>> On Mon, Apr 4, 2011 at 3:21 PM, Justin Ruggles <[email protected]> 
>> wrote:
>>> On 04/02/2011 01:19 PM, Anton Khirnov wrote:
>>>> +#if FF_API_FLAC_GLOBAL_OPTS
>>>>      /**
>>>>       * Determines which LPC analysis algorithm to use.
>>>>       * - encoding: Set by user
>>>>       * - decoding: unused
>>>>       */
>>>> -    enum AVLPCType lpc_type;
>>>> +    attribute_deprecated enum AVLPCType lpc_type;
>>>
>>> Should we also deprecate the AVLPCType enum and move it to lpc.h without
>>> the AV prefix?  I don't think private options need to have public enums
>>> for their values.
>>
>> Does AVOption attempt to solve this in any way? I.e., does AVOption
>> have a mechanism to link a string to a numerical value to create a
>> "enum-style" list of (random) integers and (meaningful) strings?
> 
> 
> yes.


to be more specific, here is a snippet of Anton's patch:

> +    { "lpc_type", "LPC algorithm", offsetof(FlacEncodeContext, 
> options.lpc_type),
> +      FF_OPT_TYPE_INT, AV_LPC_TYPE_DEFAULT, AV_LPC_TYPE_DEFAULT, 
> AV_LPC_TYPE_NB-1, FLAGS },
> +    { "none",     NULL, 0, FF_OPT_TYPE_CONST, AV_LPC_TYPE_NONE,     INT_MIN, 
> INT_MAX, FLAGS, "lpc_type" },
> +    { "fixed",    NULL, 0, FF_OPT_TYPE_CONST, AV_LPC_TYPE_FIXED,    INT_MIN, 
> INT_MAX, FLAGS, "lpc_type" },
> +    { "levinson", NULL, 0, FF_OPT_TYPE_CONST, AV_LPC_TYPE_LEVINSON, INT_MIN, 
> INT_MAX, FLAGS, "lpc_type" },
> +    { "cholesky", NULL, 0, FF_OPT_TYPE_CONST, AV_LPC_TYPE_CHOLESKY, INT_MIN, 
> INT_MAX, FLAGS, "lpc_type" },

_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to