Skip to content

Commit bef67b7

Browse files
committed
acap/testcard, vdisp/dump: IWYU
1 parent 382f2fc commit bef67b7

File tree

2 files changed

+21
-15
lines changed

2 files changed

+21
-15
lines changed

src/audio/capture/testcard.c

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,23 @@
3737

3838
#define MOD_NAME "[Audio testcard] "
3939

40-
#ifdef HAVE_CONFIG_H
41-
#include "config.h"
42-
#include "config_unix.h"
43-
#include "config_win32.h"
44-
#endif
40+
#include <assert.h> // for assert
41+
#include <errno.h> // for errno
42+
#include <limits.h> // for INT_MAX
43+
#include <math.h> // for sin, pow, sqrt, M_PI, round
44+
#include <stdbool.h> // for false, bool, true
45+
#include <stddef.h> // for ptrdiff_t
46+
#include <stdint.h> // for INT32_MAX, int32_t, INT32_MIN, int64_t
47+
#include <stdio.h> // for fclose, fopen, perror, printf, FILE
48+
#include <stdlib.h> // for NULL, calloc, free, size_t, strtol
49+
#include <string.h> // for strlen, memcpy, strchr, memset, strcmp
50+
#include <strings.h> // for strncasecmp, strcasecmp
51+
#include <unistd.h> // for usleep
4552

4653
#include "audio/audio_capture.h"
4754
#include "audio/types.h"
4855
#include "audio/utils.h"
4956
#include "audio/wav_reader.h"
50-
#include "compat/misc.h"
5157
#include "compat/usleep.h"
5258
#include "debug.h"
5359
#include "host.h"
@@ -58,9 +64,6 @@
5864
#include "utils/macros.h"
5965
#include "utils/misc.h"
6066

61-
#include <assert.h>
62-
#include <string.h>
63-
6467
#define AUDIO_CAPTURE_TESTCARD_MAGIC 0xf4b3c9c9u
6568

6669
#define DEFAULT_AUDIO_BPS 2

src/video_display/dump.c

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,21 +38,24 @@
3838
* @file
3939
* @todo Add audio support
4040
*/
41-
#include "config.h"
42-
#include "config_unix.h"
43-
#include "config_win32.h"
4441

45-
#include <stdint.h>
42+
#include <assert.h> // for assert
43+
#include <stdbool.h> // for true, bool, false
44+
#include <stdlib.h> // for NULL, free, calloc, malloc, size_t
45+
#include <string.h> // for memcpy, strcmp, strlen
46+
#include <time.h> // for strftime, time, time_t, tm
4647

4748
#include "compat/time.h"
4849
#include "debug.h"
4950
#include "export.h"
5051
#include "host.h"
5152
#include "lib_common.h"
53+
#include "types.h" // for video_frame, tile, video_desc, codec_t
5254
#include "utils/color_out.h"
5355
#include "utils/macros.h"
5456
#include "video.h"
5557
#include "video_display.h"
58+
struct module;
5659

5760
#define MOD_NAME "[dump] "
5861

@@ -146,7 +149,7 @@ static bool display_dump_get_property(void *state, int property, void *val, size
146149
memcpy(val, codecs, sizeof(codecs));
147150
*len = sizeof(codecs);
148151
} else {
149-
return FALSE;
152+
return false;
150153
}
151154
break;
152155
case DISPLAY_PROPERTY_VIDEO_MODE:
@@ -164,7 +167,7 @@ static bool display_dump_reconfigure(void *state, struct video_desc desc)
164167
struct dump_display_state *s = state;
165168
vf_free(s->f);
166169
s->f = vf_alloc_desc(desc);
167-
s->f->decoder_overrides_data_len = is_codec_opaque(desc.color_spec) != 0 ? TRUE : FALSE;
170+
s->f->decoder_overrides_data_len = is_codec_opaque(desc.color_spec) != 0 ? true : false;
168171
s->max_tile_data_len = MAX(8 * desc.width * desc.height, 1000000UL);
169172
for (unsigned int i = 0; i < s->f->tile_count; ++i) {
170173
if (is_codec_opaque(desc.color_spec)) {

0 commit comments

Comments
 (0)