It is easier to read.
Unified · Split
| @@ -106,28 +106,31 @@ typedef struct SpecifierOpt { · 105 unmodified lines | |||
| 106 | typedef struct OptionDef { | 106 | typedef struct OptionDef { |
| 107 | const char *name; | 107 | const char *name; |
| 108 | int flags; | 108 | int flags; |
| 109 | #define HAS_ARG 0x0001 | 109 | #define HAS_ARG (1 << 0) |
| 110 | #define OPT_BOOL 0x0002 | 110 | #define OPT_BOOL (1 << 1) |
| 111 | #define OPT_EXPERT 0x0004 | 111 | #define OPT_EXPERT (1 << 2) |
| 112 | #define OPT_STRING 0x0008 | 112 | #define OPT_STRING (1 << 3) |
| 113 | #define OPT_VIDEO 0x0010 | 113 | #define OPT_VIDEO (1 << 4) |
| 114 | #define OPT_AUDIO 0x0020 | 114 | #define OPT_AUDIO (1 << 5) |
| 115 | #define OPT_INT 0x0080 | 115 | #define OPT_INT (1 << 6) |
| 116 | #define OPT_FLOAT 0x0100 | 116 | #define OPT_FLOAT (1 << 7) |
| 117 | #define OPT_SUBTITLE 0x0200 | 117 | #define OPT_SUBTITLE (1 << 8) |
| 118 | #define OPT_INT64 0x0400 | 118 | #define OPT_INT64 (1 << 9) |
| 119 | #define OPT_EXIT 0x0800 | 119 | #define OPT_EXIT (1 << 10) |
| 120 | #define OPT_DATA 0x1000 | 120 | #define OPT_DATA (1 << 11) |
| 121 | #define OPT_PERFILE 0x2000 /* the option is per-file (currently ffmpeg-only). | 121 | /* The option is per-file (currently ffmpeg-only). |
| 122 | implied by OPT_OFFSET or OPT_SPEC */ | 122 | implied by OPT_OFFSET or OPT_SPEC */ |
| 123 | #define OPT_OFFSET 0x4000 /* option is specified as an offset in a passed optctx */ | 123 | #define OPT_PERFILE (1 << 12) |
| 124 | #define OPT_SPEC 0x8000 /* option is to be stored in an array of SpecifierOpt. | 124 | /* Option is specified as an offset in a passed optctx */ |
| 125 | Implies OPT_OFFSET. Next element after the offset is | 125 | #define OPT_OFFSET (1 << 13) |
| 126 | an int containing element count in the array. */ | 126 | /* Option is to be stored in an array of SpecifierOpt. Implies OPT_OFFSET. |
| 127 | #define OPT_TIME 0x10000 | 127 | Next element after the offset is an int containing element count in the |
| 128 | #define OPT_DOUBLE 0x20000 | 128 | array. */ |
| 129 | #define OPT_INPUT 0x40000 | 129 | #define OPT_SPEC (1 << 14) |
| 130 | #define OPT_OUTPUT 0x80000 | 130 | #define OPT_TIME (1 << 15) |
| 131 | #define OPT_DOUBLE (1 << 16) | ||
| 132 | #define OPT_INPUT (1 << 17) | ||
| 133 | #define OPT_OUTPUT (1 << 18) | ||
| 131 | union { | 134 | union { |
| 132 | void *dst_ptr; | 135 | void *dst_ptr; |
| 133 | int (*func_arg)(void *, const char *, const char *); | 136 | int (*func_arg)(void *, const char *, const char *); |