Skip to content

Commit

Permalink
Fixed an incorrect timer processing when using a real-time interface
Browse files Browse the repository at this point in the history
  • Loading branch information
Wohlstand committed Oct 10, 2020
1 parent dd253e5 commit 40ccbe1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,9 @@ To remove MIDI Sequencer, define `OPNMIDI_DISABLE_MIDI_SEQUENCER` macro and remo
* [OPNMIDI Player for Android](https://github.com/Wohlstand/OPNMIDI-Player-Java/) - a little MIDI-player for Android which uses libOPNMIDI to play MIDI files and provides flexible GUI with ability to change bank, flags, number of emulated chips, etc.

# Changelog
## 1.5.0.1 2020-10-11
* Fixed an incorrect timer processing when using a real-time interface

## 1.5.0 2020-09-28
* Drum note length expanding is now supported in real-time mode (Thanks to [Jean Pierre Cimalando](https://github.com/jpcima) for a work!)
* Added support for OPNA chip with Neko Project II Kai YM2602 emulator usage (Thanks to [Jean Pierre Cimalando](https://github.com/jpcima) for a work!)
Expand Down
2 changes: 1 addition & 1 deletion src/opnmidi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1134,7 +1134,7 @@ OPNMIDI_EXPORT int opn2_generateFormat(struct OPN2_MIDIPlayer *device, int sampl
ssize_t n_periodCountStereo = 512;

int left = sampleCount;
double delay = double(sampleCount) / double(setup.PCM_RATE);
double delay = double(sampleCount / 2) / double(setup.PCM_RATE);

while(left > 0)
{
Expand Down

0 comments on commit 40ccbe1

Please sign in to comment.