diff options
author | Takamichi Horikawa <takamichiho@gmail.com> | 2017-04-15 01:00:20 +0900 |
---|---|---|
committer | Takamichi Horikawa <takamichiho@gmail.com> | 2017-04-15 01:00:20 +0900 |
commit | 680ab52d9e151676b8f90d105b23d2d0d89b0471 (patch) | |
tree | 5a05e82900393d2e1ecdf034cf1735d4ebfaec98 /libopna/opna.c | |
parent | 428126ee4c8802a4b5f9c9ee491d54013857741b (diff) |
add fmdsp fft analyzer
Diffstat (limited to 'libopna/opna.c')
-rw-r--r-- | libopna/opna.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libopna/opna.c b/libopna/opna.c index 567c913..9f87ff3 100644 --- a/libopna/opna.c +++ b/libopna/opna.c @@ -9,6 +9,7 @@ void opna_reset(struct opna *opna) { opna_drum_reset(&opna->drum); opna_adpcm_reset(&opna->adpcm); opna->mask = 0; + opna->generated_frames = 0; } void opna_writereg(struct opna *opna, unsigned reg, unsigned val) { @@ -42,6 +43,7 @@ void opna_mix_oscillo(struct opna *opna, int16_t *buf, unsigned samples, struct oscillo ? &oscillo[6] : 0, offset); opna_drum_mix(&opna->drum, buf, samples); opna_adpcm_mix(&opna->adpcm, buf, samples); + opna->generated_frames += samples; } unsigned opna_get_mask(const struct opna *opna) { |