Commit Graph

19 Commits

Author SHA1 Message Date
Lukas W
1bbf7455a4 Rename a lot… 2014-11-26 10:09:49 +01:00
Lukas W
5b77abd9a5 Rename fixes 2014-11-26 01:46:12 +01:00
Garrett
205056621c Fixed release samples never being deleted
I removed code in a previous commit that deleted ended samples since
that sometimes caused issues when the samples had loop points. However,
removing the code caused issues with the release samples. Thus, now it
removes ended samples only if they are release samples. Otherwise, the
keyup event and ADSR handle ending the note.
2014-11-23 14:24:51 -08:00
Garrett
366e799791 More What's This messages 2014-11-23 10:31:18 -08:00
Garrett
76e182e586 Release only one note on keyup
Previously if you release a C4 then all C4 notes would be released. Now
it stores the pointer to the plugin data which is unique for each key
press and determines which to release based on the matching pointers.
2014-11-18 09:02:50 -08:00
Garrett
3f641c2c55 Make it work with MemoryManager 2014-11-18 08:30:31 -08:00
Garrett
702e2a1ee3 Added loop support and fixed fine tunings
Now it'll honor the loop regions specified in the file and it'll
properly use the fine tuning for the samples if specified. Also,
modified the exponential decay code again since it was glitching at the
end of some notes for some reason.
2014-11-18 08:05:28 -08:00
Garrett
71b6814729 Change pitch of notes if PitchTrack is set
Now if a Gig file provides a few samples per octave, it'll change the
pitch of the sample specified for a note instead of just assuming it is
the right pitch.

Also, fixed issue where if attack length was zero the note would never
sound.
2014-11-18 08:05:28 -08:00
Garrett
2c0b1ef4b0 Use stack array for buffer instead of gig::buffer_t 2014-11-18 08:05:28 -08:00
Garrett
8693623758 Fixed resampling glitches when deleting notes
Moving the code to detect the sample rates of the currently used samples
after the code deleting notes seemed to fix these glitches. Also, fixed a
few ADSR issues that could have resulted in clipping in the attack or
glitching after the release.
2014-11-18 08:05:27 -08:00
Garrett
a251391249 Always use linear interpolation for resampling 2014-11-18 08:05:27 -08:00
Garrett
4e8508b8a3 Exponential decay for release instead of linear
It now sounds much more like the release in Linux Sampler.
2014-11-18 08:05:27 -08:00
Garrett
822a3c52bb Convert 24-bit data if on big endian system
This is needed since libgig returns 24-bit data in a little endian.
Note: untested as I don't have a big endian system.
2014-11-18 08:05:27 -08:00
Garrett
c0ad77dfca Stack buffers instead of allocating on the heap 2014-11-18 08:05:27 -08:00
Garrett
d1bf19ef4a Don't use "note" as a variable name 2014-11-18 08:05:27 -08:00
Garrett
d0a821947a Fixed resampling issues
When providing extra frames, libsamplerate stores the extras internally
and outputs them in the next period. But, when it has enough internally
to output a whole period, it just outputs the internal buffer while not
using any more input frames. Now I provide some extra frames, check to
see how many frames we used actually used, and update the sample
positions and ADSR accordingly.
2014-11-18 08:05:27 -08:00
Garrett
a679e4e938 Fixed detuned resampling
Apparently the most noticeable detuning issues were caused by rounding
error by integer division.
2014-11-18 08:05:27 -08:00
Garrett
07032260e8 configManager to ConfigManager rename 2014-11-18 08:05:27 -08:00
Garrett
3aaa7ac6c4 Coding style fixes 2014-11-18 08:05:27 -08:00