PDA

View Full Version : I'd like to try coding a special-purpose sampler plug-in


Consul
06-13-2009, 01:19 PM
I'm trying to find some guidance on how I might possibly accomplish a design for a sampler I have in mind. Here are the basic ideas I'm after:

1) Using the Elastique engine to do the pitch shifting of the loaded sample(s), instead of just resampling it.
2) A cross-faded looping mode with a couple of other tricks to smooth out amplitude variations in the original sample.

After all that, I might add on a filter or two.

The idea behind this is to facilitate a more musique concrète approach to sampling, so samples can be tuned and looped in any way and have them be immediately playable as instruments.

So, I guess my questions are:

1) Can an instrument (VSTi) plug-in use the Reaper SDK for access to the pitch-shifting engine? Can I use Reaper's wave file playback as well?
2) Does the Reaper SDK provide GUI widgets and engine or do I need to use something like WDL?
3) Besides Visual Studio C++ Express, is there anything else I'll need code-wise?

I have some experience with C++, but I'll be taking this thing one small step at a time, starting with making a window pop up. ;)

Thank you for the help!

Xenakios
06-14-2009, 04:21 PM
So, I guess my questions are:

1) Can an instrument (VSTi) plug-in use the Reaper SDK for access to the pitch-shifting engine? Can I use Reaper's wave file playback as well?
2) Does the Reaper SDK provide GUI widgets and engine or do I need to use something like WDL?
3) Besides Visual Studio C++ Express, is there anything else I'll need code-wise?

I have some experience with C++, but I'll be taking this thing one small step at a time, starting with making a window pop up. ;)

Thank you for the help!

1) Both should be doable. In a VST plugin I've tested the audio file reading APIs but not the pitch shifting engine interface. In Reaper extension plugins, both work fine.
2) The GUI things will be painful work you must mostly do on your own. WDL does have schwa's iPlug framework though which provides some basic GUI widget classes for VST/AU plugins. (You'll need to do your own bitmaps for them etc...) I don't remember now how comprehensive the framework is, it might not for example provide dropdown menu widgets (comboboxes).
3) Visual Studio Express should be fine as long as you don't need to do old style win32 dialogs, as the Express edition doesn't allow visual editing of the dialog resources. It does allow visual editing of .NET based Windows forms though (for "managed C++" etc) , but you likely don't want to go that route for a VST plugin.

Consul
06-14-2009, 09:14 PM
Thank you, Xenakios, for your reply here and in IRC. Because of that conversation, I don't think I'm going to pursue this project at this point. If I really want to do musique concrète, then I may as well try just throwing clips on the timeline and pitching them by hand.

Xenakios
06-14-2009, 09:47 PM
Thank you, Xenakios, for your reply here and in IRC. Because of that conversation, I don't think I'm going to pursue this project at this point. If I really want to do musique concrète, then I may as well try just throwing clips on the timeline and pitching them by hand.

Well the plugin is an interesting idea in any case, you should not forget about it completely. ;)

NAS
06-15-2009, 05:42 AM
Gutted
I was hoping to see something come of this
Sounded uber mad interesting :(

NAS

Consul
06-15-2009, 06:53 AM
NAS: The main issue has to do with the fact that the Elastique engine introduces large amounts of latency to the core sound engine once it's introduced. Well, that's what Xen and others explained to me, anyway. I have no direct experience with that, but these are pretty smart guys I'm talking to.

In short, unless I have some sort of guarantee I can make this work, I don't want to spend hundreds of hours on it. A little selfish of me, maybe, but I just want some tools to make music. I'm not out to be the world's next great music app coder.

Xenakios
06-15-2009, 07:48 AM
NAS: The main issue has to do with the fact that the Elastique engine introduces large amounts of latency to the core sound engine once it's introduced. Well, that's what Xen and others explained to me, anyway. I have no direct experience with that, but these are pretty smart guys I'm talking to.



Well the latency would not happen globally in Reaper, but for the plugin using the elastique processing, and I am not aware if there actually is a mechanism for VST instruments to avoid that by using plugin delay compensation mechanisms in the host. And even if there was the ability for that compensation, it would not apply for live monitoring of what's played into the instrument, only for existing media (MIDI items in this case). (Like it works for audio fx.)

It unfortunately looks like you'd need to try it before you can know how it all could fit together. Admittedly a big undertaking for no guarantee on suitable results... :(

plamuk
07-13-2009, 11:02 PM
i love this idea.

crossfades? yes. elastique, however? no. forget elastique - do it in a playback rate , tune up/down type of way ala turntable.

use the audio signal from incoming vinyl code off of control records like Serato Scratch Live, Finalscratch and Ms Pinky to control the playback rate.

there are a couple applications for the electronic turntablist like final scratch, serato scratch live, or djdecks, but there's no vsti sampler plugin that lets you control a sample's playback rate via turntable controller to use in the daw of your choice.

i've been waiting for this for years.