C# as a front end for JUCE

OK, this might sound a bit kooky, but…

Suppose one wanted to take advantage of parts of JUCE such as audio, VST and ASIO support, etc. from within a C# .NET program. Possible? If so, how? Would it violate the JUCE license? Would this just be a can of worms (latency problems with garbage collection, etc)? Is it just a Bad Idea[size=59]TM[/size]?

Does anybody have any suggestions or links to supporting VST/ASIO/etc in C#, i.e. examples with source? (I realize this is getting OT for this forum, but I know many of you here are experts :wink:).

I’m a .NET newbie, but have C++ exp, and have written a couple of simple JUCE apps using VC6.


I don’t know about the license issues with JUCE but technically you can.
And it’s not even that hard :wink: The trick is to attach a WinForms User Control as a child to the parent hWnd passed in the editorOpen method.
You do that by using the SetParent Win32 API call.

For a working example you can check out VST.NET.

VST.NET allows you to write a VST plugin (2.4) in any .NET language. It bridges the gap between C/C++ and .NET by using the managed extensions of the Microsoft C/C++ compiler. It also provides a framework to build your plugin on top of, that simplifies and structures the VST interface.

There are a couple of samples that demonstrate how to do some typical plugin constructs. There is a fully working Delay, complete with Parameters, Programs and Persistence. And there are two Midi samples: a Note Mapper and a Sampler (instrument).

You might want to check out the CorePlugin sample that cleanly demonstrates how to use your WinForms User Control as editor UI.

Hope it helps,
Marc Jacobi