Is it possible to develop a VST using Visual Basic 6?

DSP, Plugin and Host development discussion.
RELATED
PRODUCTS

Post

Hi everyone, I am kind-off new here.

I just have a simple question. I am interested in developing a VST, but to date have only experience in Visual Basic, which I have been doing for over 5 years. Thats Visual Basic 6.

Is it possible to develop a simple VST using VB6. I know that the software development kits are only for C++ and Delphi, but surely I should be able to use those classes. Please correct me if I am wrong.

The other alternative is to learn C++, but how difficult would that be for me? Are there any pointers or guidelines you could provide for me here?

Also, is there any book or literature which can help in how to develop VSTs.

Many Thanks
OrangeMan

Post

VB isn't OO, so it will be pritty hard. Normaly you simply derive a class from AudioEffectX. This isn't possible in VB (correct me if I'm wrong). So, sorry I don't see how to do it.
The other alternative is to learn C++, but how difficult would that be for me? Are there any pointers or guidelines you could provide for me here?
Hm, pretty hard? OK, you could continue the procedural style of coding in C++, but that's very uncommon and I wouldn't recomend to do so. But changing the coding style is hard (at least it was for me a long time ago).
Of course it worth learning C++, but it's very complicated.

Post

Delphi is another choice. The transition from VB to Dellphi shouldn't be so hard. Tobybear uses Delphi and FLStudio is written in Delphi too if I'm not wrong.

Post

Actually, there's something a bit more fundamental. The whole VST API works by exposing C method calls. This you can do in Delphi, but not in VB, C#, Java or much else. So, you could write bits that way, but you'd need to write a wrapper. And the effort involved would be better spent learning enough C++ anyway.

Post

VST = C++ sdk

What about dxi?

Best regards,

Spe3d

:O)

Post

Spe3D wrote:VST = C++ sdk

What about dxi?

Best regards,

Spe3d

:O)
Tobybear is porting the DX sdk from c++ to Delphi as we speak :) And the VST sdk is already ported.

Post

Well...whether VB is OO or not is debateable these days, and largely irrelevent...

And you *can* call C/C++ API's from VB (with some provisos)...been doing for years. So it may well be possible to do it from VB. As always sample code is useful in these scenarios, but don't know if any VB stuff sorry.

So I think it's worth a try, let us know how you go!

cheers.

Post

Banjostar wrote:
Spe3D wrote:VST = C++ sdk

What about dxi?

Best regards,

Spe3d

:O)
Tobybear is porting the DX sdk from c++ to Delphi as we speak :) And the VST sdk is already ported.
I should have looked in this forum – it’s only two threads down about the new Delphi port by tobybear :oops:

Thanks Banjo :)

Best regards,

Spe3d

:O)

Post

And you *can* call C/C++ API's
You can call C APIs, but not C++, as C++'s namemangling isn't specified by the ISO-standard.

Post

husker wrote:And you *can* call C/C++ API's from VB (with some provisos)...been doing for years.
Same here. But the emphasis should be on the word "call". Because you, the VSTi implementer, have to expose these methods. And that you can't do.

Now, tobybear is a development god, but he's only just started on DXi, having done VSTi years ago. I'd follow his example... :)

Post

Hi guys, thanks everyone for the reply.

I would like to say that I've always considered VB to be object oriented to a certain extent. Okay, it doesn't really support inheritence, but it certainly isn't procedural as far as I have experienced.

I have always used class structures and COM architecture. I have always taken an OOP approach in my programming as far as VB allows.

I never thought that it was so important which language one used to make use of a type library and interface. I thought that was the whole point of a type library and interface. Just expose the functions and methods available and any programming environment should be able to make use of it. You know 'black-box' software engineering.

I only want to write a very simple VST with not much processing at all. That's why I thought I should be able to do it in VB.

OrangeMan

Post

goto http://sourceforge.net/ and search for VST, you will find open source instruments and some VST wrappers including Java:
http://sourceforge.net/projects/jvstwrapper/

Post

OrangeMan wrote: I never thought that it was so important which language one used to make use of a type library and interface. I thought that was the whole point of a type library and interface. Just expose the functions and methods available and any programming environment should be able to make use of it. You know 'black-box' software engineering.
Yeah, there's a couple of problems with that. One is that Microsoft got it wrong with COM (there's no sensible way to implement the NewEnum method, for instance). .NET is much cleaner in that regard.

The next problem is that COM don't work on Macs, except within Microsoft products.

And finally...
...the VST SDK doesn't use COM. It uses C extern functions, because (sadly) they're a lot more portable, and they care about PC and Mac a lot more than C++ and VB.

Post

I've been told VB is just way too slow for audio...

Post

I've been told VB is way too slow any number of times by C++ coders whose code goes slower than mine. Structs, doubles and ints are just as fast in VB as in Microsoft C++ (they ought to be, they use the same damn compiler). It's good code that makes things go fast.

Not that I'd recommend VB as a way to go. Read "The C programming language" by K&R. It's dead easy, and it should give you

Sooner or later, though, complicated stuff gets into SSE territory. And then using an environment (like Microsoft C++) that can have embedded assembler is a real win.

Post Reply

Return to “DSP and Plugin Development”