-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Thanks for making this!! #11
Comments
Excellent work!!! |
Sorry to use this as a strange way to get in touch with you, great little project, well done! :) EDIT : It looks like the original flanger from Alex Veltsistas, but with a precomputed delay table. -Mat |
The chorus implementation is taken from the textbook "Sound programming in C - Signal processing for sound effects". http://floor13.sakura.ne.jp/book03/book03.html "ex9_1.c" in "chapter09.zip" is the original chorus implementation. #include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include "wave.h"
int main(void)
{
MONO_PCM pcm0, pcm1;
int n, m;
double d, depth, rate, t, tau, delta;
mono_wave_read(&pcm0, "sample06.wav"); /* Read the mono sound data from the WAVE file */
pcm1.fs = pcm0.fs; /* The sample rate */
pcm1.bits = pcm0.bits; /* The bit depth */
pcm1.length = pcm0.length; /* The length of the sound data */
pcm1.s = calloc(pcm1.length, sizeof(double)); /* Memory allocation */
d = pcm1.fs * 0.025; /* 25ms */
depth = pcm1.fs * 0.01; /* 10ms */
rate = 0.1; /* 0.1Hz */
/* Chorus */
for (n = 0; n < pcm1.length; n++)
{
pcm1.s[n] = pcm0.s[n];
tau = d + depth * sin(2.0 * M_PI * rate * n / pcm1.fs);
t = (double)n - tau;
m = (int)t;
delta = t - (double)m;
if (m >= 0 && m + 1 < pcm1.length)
{
pcm1.s[n] += delta * pcm0.s[m + 1] + (1.0 - delta) * pcm0.s[m];
}
}
mono_wave_write(&pcm1, "ex9_1.wav"); /* Output the mono sound data to the WAVE file */
free(pcm0.s); /* Free memory */
free(pcm1.s); /* Free memory */
return 0;
} |
Thank you! That looks like such a good book. Too bad i cant read it, but i can read code. -Mat |
Just wanted to add my own thank you here. I've been wanting to add general midi synthesis to my x86/dos emulator for years, and it was trivially easy to plug MeltySynth in. Fantastic work! |
Very nice 😄 |
Thank you so much for this library ! I was able to replace WinMM with a cross platform solution in this project here: http://github.com/OpenRakis/Spice86 Along with a small GM SoundFont with a suitable license (CC0), this works perfectly ! :) |
Glad to hear that 😊 |
A big thank you from me too. I always dreamed of adding something like this to NAudio but never had the time (there is a semi-complete SoundFont parser in there, but no sequencer or soundfont player). Really impressed with what you've made, and how easy it is to use. |
Thanks! I'm also grateful for your work on NAudio 😊 |
https://markheath.net/post/naudio-midi-playback-soundfont-meltysynth blog coverage =) |
I made a Dart port of MeltySynth =) Just wanted to let you know of its existence!
https://github.com/chipweinberger/DartMeltySoundFont
I looked around for days for a good SoundFont implementation to port to Dart, and yours is incredibly clean and well written. Really impressive! I looked in depth to at least 4 different implementations!
Really happy I found your implementation, and for all your work making this high quality library!
The text was updated successfully, but these errors were encountered: