[vlc-devel] [RFC] custom module capabilities

Rémi Denis-Courmont remi at remlab.net
Thu Sep 3 18:05:12 CEST 2020


Le torstaina 3. syyskuuta 2020, 18.49.20 EEST Lyndon Brown a écrit :
> One set of patches switches capabilities over to be enum based. (For
> which there are advantages such as efficiency and catching mistakes).

If you're concerned with typos in the capability string, you can simply 
replace the strings with macros:

#define VLC_CAPABILITY_DEMUX "demux"

and

    set_capability(VLC_CAPABILITY_DEMUX, xxx)

I don't really follow the efficiency argument. We already have a binary search 
tree for indexing capabilities. An enumeration is likely to cause a lot of 
compatibility problems as capabilities are added and removed.

-- 
レミ・デニ-クールモン
http://www.remlab.net/





More information about the vlc-devel mailing list