comparison mediaplayer.h @ 2290:c4980d89614b

Support WAVE files in media player
author Michael Pavone <pavone@retrodev.com>
date Sat, 04 Feb 2023 23:31:11 -0800
parents 92449b47cce8
children 789802d99629
comparison
equal deleted inserted replaced
2289:92449b47cce8 2290:c4980d89614b
2 #define MEDIAPLAYER_H_ 2 #define MEDIAPLAYER_H_
3 3
4 #include <stdint.h> 4 #include <stdint.h>
5 #include "system.h" 5 #include "system.h"
6 #include "vgm.h" 6 #include "vgm.h"
7 #include "wave.h"
8 #include "render_audio.h"
7 9
8 typedef struct chip_info chip_info; 10 typedef struct chip_info chip_info;
9 typedef void (*chip_run_fun)(void *context, uint32_t cycle); 11 typedef void (*chip_run_fun)(void *context, uint32_t cycle);
10 typedef void (*chip_adjust_fun)(chip_info *chip); 12 typedef void (*chip_adjust_fun)(chip_info *chip);
11 struct chip_info { 13 struct chip_info {
23 system_header header; 25 system_header header;
24 system_media *media; 26 system_media *media;
25 vgm_header *vgm; 27 vgm_header *vgm;
26 vgm_extended_header *vgm_ext; 28 vgm_extended_header *vgm_ext;
27 data_block *ym_seek_block; 29 data_block *ym_seek_block;
30 wave_header *wave;
31 audio_source *audio;
28 chip_info *chips; 32 chip_info *chips;
29 uint32_t num_chips; 33 uint32_t num_chips;
30 uint32_t current_offset; 34 uint32_t current_offset;
31 uint32_t playback_time; 35 uint32_t playback_time;
32 uint32_t wait_samples; 36 uint32_t wait_samples;