diff options
author | Andreas Rheinhardt <[email protected]> | 2025-09-04 14:56:13 +0200 |
---|---|---|
committer | Andreas Rheinhardt <[email protected]> | 2025-09-12 21:37:42 +0200 |
commit | 87cb7c871b6b25e537a7b19e47bf2779ad8d31b4 (patch) | |
tree | eb4a390265ac5e07dcaad3b7db35c81a534d7042 | |
parent | f49de7018af3e41805ad600ce99b79163861ff59 (diff) |
avcodec/pcm_tablegen: Fix hardcoded-tables if alaw,mulaw,vidc codecs disabled
Since ae448e00afb43d7f72dfa9c82a4c45994e4fea6a the various
tableinit functions are not compiled unconditionally any more,
so that pcm_tablegen.c (which creates the hardcoded tables)
needs to be updated.
Reviewed-by: James Almer <[email protected]>
Signed-off-by: Andreas Rheinhardt <[email protected]>
-rw-r--r-- | libavcodec/pcm_tablegen.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/libavcodec/pcm_tablegen.c b/libavcodec/pcm_tablegen.c index 473a47f6d9..cff713606b 100644 --- a/libavcodec/pcm_tablegen.c +++ b/libavcodec/pcm_tablegen.c @@ -21,21 +21,27 @@ */ #include <stdlib.h> +#include "config_components.h" #define CONFIG_HARDCODED_TABLES 0 #include "pcm_tablegen.h" #include "tableprint.h" int main(void) { - pcm_alaw_tableinit(); - pcm_ulaw_tableinit(); - pcm_vidc_tableinit(); - write_fileheader(); +#if CONFIG_PCM_ALAW_ENCODER + pcm_alaw_tableinit(); WRITE_ARRAY("static const", uint8_t, linear_to_alaw); +#endif +#if CONFIG_PCM_MULAW_ENCODER + pcm_ulaw_tableinit(); WRITE_ARRAY("static const", uint8_t, linear_to_ulaw); +#endif +#if CONFIG_PCM_VIDC_ENCODER + pcm_vidc_tableinit(); WRITE_ARRAY("static const", uint8_t, linear_to_vidc); +#endif return 0; } |