diff options
author | Nebuleon Fumika | 2013-01-08 15:04:53 -0500 |
---|---|---|
committer | Nebuleon Fumika | 2013-01-08 15:04:53 -0500 |
commit | 1beb671de1d39964ad3453e28fd48a117046a8cb (patch) | |
tree | 8a27664cf771d2a1df399c23acf5546b1e9a2613 /source/nds/entry.cpp | |
parent | 12c5afbe60035f52da6ae33e853ea01fe075d06c (diff) | |
download | snesemu-1beb671de1d39964ad3453e28fd48a117046a8cb.tar.gz snesemu-1beb671de1d39964ad3453e28fd48a117046a8cb.tar.bz2 snesemu-1beb671de1d39964ad3453e28fd48a117046a8cb.zip |
Configurable interrupt interval for the sound timer. Right now, only 22050 Hz audio at 2000-microsecond intervals works.
Diffstat (limited to 'source/nds/entry.cpp')
-rw-r--r-- | source/nds/entry.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/source/nds/entry.cpp b/source/nds/entry.cpp index f14c917..a666a0b 100644 --- a/source/nds/entry.cpp +++ b/source/nds/entry.cpp @@ -538,7 +538,7 @@ int sfc_main (int argc, char **argv) Settings.SoundBufferSize); // Start a timer for the sound initTimer(0 /* timer channel, 0 or 1 */, - 2000 /* period in microseconds */, + INTERRUPT_TIME /* period in microseconds */, NDSSFCProduceSound /* timer function, void (unsigned int) */, 0 /* programmer-specified argument to ^ */); runTimer(0 /* timer channel, 0 or 1 */); @@ -1157,6 +1157,8 @@ void NDSSFCProduceSound (unsigned int unused) /* All data sent. */ } + IsSoundGenerated = FALSE; + so.samples_mixed_so_far -= sample_count; } |