Re: [music-dsp] phase vocoder

2018-10-15 Thread Eugene Cherny
Someone already pointed you to Soundpipe: https://github.com/PaulBatchelor/Soundpipe/blob/master/examples/ex_pshift.c -- Kind regards,Eugene Chernyhttps://eugn.ch   15.10.2018, 19:53, "Alex Dashevski" :I need the good example: easy to undersand and to integrate to other code. Thanks,Alex ‫בתאריך יום ב׳, 15 באוק׳ 2018 ב-19:43 מאת ‪Eugene Cherny‬‏ <‪m...@eugn.ch‬‏>:‬Alex, There’re enough examples on GitHub: https://github.com/search?q=pitch+shifting+real+timehttps://github.com/search?q=pitch+shifting+realtime -- Kind regards,Eugene Chernyhttps://eugn.ch   15.10.2018, 19:38, "Alex Dashevski" :I need the code for pitch shifting on RealTime. Could you help ? ‫בתאריך יום ב׳, 15 באוק׳ 2018 ב-15:15 מאת ‪Eder Souza‬‏ <‪ederwan...@gmail.com‬‏>:‬Some time ago I posted some code in matlab, this is not real-time, you can see the basic math of an standard phase vocoder. https://dsp.stackexchange.com/questions/40101/audio-time-stretching-without-pitch-shifting/40367#40367 This code just change the time, you can pitch shift using a combination of the code above and resampler... The core code is the same for real-time or off-line, the only thing that you need to worry about is how deal with input and output buffer (do you need ensure output buffer continuity, learn about Circular Buffer). PS: Prepare to latency lol   Eder de Souza♪♫                                                                ♫♪     ▇ ▅ █ ▅ ▇ ▂ ▃ ▁ ▁ ▅ ▃ ▅ ▅ ▄ ▅ ▇Sent From The Moon and Written With My Thumbs ! On Sun, Oct 14, 2018 at 2:11 AM Alex Dashevski  wrote:Hi,Which library?Thanks,Alex On Sat, Oct 13, 2018, 22:42 he can jog  wrote:The library is easy to work with. Having enough of a working knowledge of phase vocoders to make use of an existing implementation and implementing one from scratch are two different levels of complexity. On Sat, Oct 13, 2018 at 2:31 PM Daniel Varela  wrote:Complex stuff have no easy fix El sáb., 13 oct. 2018 20:43, he can jog  escribió:Paul Batchelor has a great port of the csound 'mincer' phase vocoder in his SoundPipe library: https://github.com/PaulBatchelor/Soundpipe/blob/master/modules/mincer.c That's definitely beyond my understanding to re-implement, but his library is designed to be embedded and has a really nice API, I've found it easy to work with in my own projects. On Sat, Oct 13, 2018 at 1:31 PM Alex Dashevski  wrote:Hi, Where can I find a simple explanation and code example(supported RealTime and multi threading) ?I found https://breakfastquay.com/rubberband/index.html but it very difficult undersand how it work, I need to integrate this code into android that should run on an audio buffer. Thanks,Alex___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp,___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp,___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] phase vocoder

2018-10-15 Thread Eugene Cherny
Alex, There’re enough examples on GitHub: https://github.com/search?q=pitch+shifting+real+timehttps://github.com/search?q=pitch+shifting+realtime -- Kind regards,Eugene Chernyhttps://eugn.ch   15.10.2018, 19:38, "Alex Dashevski" :I need the code for pitch shifting on RealTime. Could you help ? ‫בתאריך יום ב׳, 15 באוק׳ 2018 ב-15:15 מאת ‪Eder Souza‬‏ <‪ederwan...@gmail.com‬‏>:‬Some time ago I posted some code in matlab, this is not real-time, you can see the basic math of an standard phase vocoder. https://dsp.stackexchange.com/questions/40101/audio-time-stretching-without-pitch-shifting/40367#40367 This code just change the time, you can pitch shift using a combination of the code above and resampler... The core code is the same for real-time or off-line, the only thing that you need to worry about is how deal with input and output buffer (do you need ensure output buffer continuity, learn about Circular Buffer). PS: Prepare to latency lol   Eder de Souza♪♫                                                                ♫♪     ▇ ▅ █ ▅ ▇ ▂ ▃ ▁ ▁ ▅ ▃ ▅ ▅ ▄ ▅ ▇Sent From The Moon and Written With My Thumbs ! On Sun, Oct 14, 2018 at 2:11 AM Alex Dashevski  wrote:Hi,Which library?Thanks,Alex On Sat, Oct 13, 2018, 22:42 he can jog  wrote:The library is easy to work with. Having enough of a working knowledge of phase vocoders to make use of an existing implementation and implementing one from scratch are two different levels of complexity. On Sat, Oct 13, 2018 at 2:31 PM Daniel Varela  wrote:Complex stuff have no easy fix El sáb., 13 oct. 2018 20:43, he can jog  escribió:Paul Batchelor has a great port of the csound 'mincer' phase vocoder in his SoundPipe library: https://github.com/PaulBatchelor/Soundpipe/blob/master/modules/mincer.c That's definitely beyond my understanding to re-implement, but his library is designed to be embedded and has a really nice API, I've found it easy to work with in my own projects. On Sat, Oct 13, 2018 at 1:31 PM Alex Dashevski  wrote:Hi, Where can I find a simple explanation and code example(supported RealTime and multi threading) ?I found https://breakfastquay.com/rubberband/index.html but it very difficult undersand how it work, I need to integrate this code into android that should run on an audio buffer. Thanks,Alex___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp,___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp

Re: [music-dsp] WSOLA on RealTime

2018-10-01 Thread Eugene Cherny
Hi Alex, Your question was “why buffers will collide” in response to the Robert’s answer: “time-scaling is not normally thought of as real-time because your input and output buffer pointers will collide”. Did I understand correctly, that you want to understand why time stretching can’t be implemented in real-time? I assume you do for the rest of this letter. First of all, Robert said “buffer pointers will collide” and not “buffers will collide” — this is essential. You can think of buffer pointers as play-heads that move through audio. SOLA methods basically define such movements. Time stretching means you move the play-head slower than real-time. To do time compression you need to move this play-head faster than real-time. In case of pre-recorded audio this makes sense: you have the whole recording available and you may move your play-head any way you want. In the real-time case, however, if you try to move the play-head faster than sampling rate (i.e. do time compression), you'll exhaust your input buffer before you fill in the output buffer. IIUC, this is what Robert meant by colliding pointers (I may be wrong, as I don’t have much low-level DSP coding experience). And even if you create a big buffer of incoming audio before doing this operation, you’ll have to wait for the input buffer at some point. You can simulate time stretching in the real-time case by buffering input and moving the play-head through it slower than real-time. But in this case you’ll exhaust your memory at some point. Hope this helps. -- Kind regards,Eugene Chernyhttps://eugn.ch   01.10.2018, 20:07, "Alex Dashevski" :Hi,Yes. I have seen it but I didn't find the answer on my question.re or less samples and you must figure out how to remove the extra or add samples to be the correct number of samples in order for it to work on a  Thanks,Alex ‫בתאריך יום ב׳, 1 באוק׳ 2018 ב-19:46 מאת ‪Nuno Santos‬‏ <‪nunosan...@imaginando.pt‬‏>:‬Hey Alex, Have you seen this article before? https://www.surina.net/article/time-and-pitch-scaling.html It has a complete and detailed description on how time and pitch scaling works. Hope it helps!  Best regards, Nuno  On 1 Oct 2018, at 17:30, Alex Dashevski  wrote: Hi, I got this answer from Robert:WSOLA fundamentally does time-scaling.  time compression or time stretching without changing pitch.  time-scaling is not normally thought of as real-time because your input and output buffer pointers will collide.  My question is:Why buffers will collide ? Thanks,Alex___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp ,___dupswapdrop: music-dsp mailing listmusic-dsp@music.columbia.eduhttps://lists.columbia.edu/mailman/listinfo/music-dsp___
dupswapdrop: music-dsp mailing list
music-dsp@music.columbia.edu
https://lists.columbia.edu/mailman/listinfo/music-dsp