Author Topic: Help with bass_net.vst  (Read 647 times)

edasps2

  • Posts: 6
Help with bass_net.vst
« on: 22 Mar '19 - 21:27 »
I need an code example of how to use bass_vst.net in vb.net (visual studio 2017), I need to load a vsti (virtual instrument) and I'm not getting it, someone can send me a code ready for me to use as an example. Thank you!

Windows 8.1 x86
« Last Edit: 22 Mar '19 - 21:31 by edasps2 »

edasps2

  • Posts: 6
Re: Help with bass_net.vst
« Reply #1 on: 25 Mar '19 - 09:51 »
This code is attached, but it is in C # and I am not able to make it work in VB.NET, if anyone can get this template in VB.NET I am very grateful, who knows someone who knows how to convert platforms.

I need this code working in VB.NET please.

edasps2

  • Posts: 6
Re: Help with bass_net.vst
« Reply #2 on: 26 Mar '19 - 05:17 »
Bass_VST does not work with VB.NET? I can not use the Un4seen.Bass.AddOn.Vst.BassVst.BASS_VST_ChannelCreate command (44100, 2, m_plugIn1DLLFilename, BASSFlag.BASS_DEFAULT)

And how much do I try to add to the bass_vst reference of this error:

Ian @ un4seen

  • Administrator
  • Posts: 21987
Re: Help with bass_net.vst
« Reply #3 on: 26 Mar '19 - 16:06 »
I'm not a .Net user myself, but I don't think you need to add a reference to BASS_VST.DLL like that. You can just place the file alongside your EXE.

edasps2

  • Posts: 6
Re: Help with bass_net.vst
« Reply #4 on: 26 Mar '19 - 20:41 »
Thanks for the help Ian. So I've tried copying the dll in the EXE folder and it did not work, funny that I have this code in C # that works perfectly, but in VB.NET it does not. Does bass_vst not work with vb.net?

Ian @ un4seen

  • Administrator
  • Posts: 21987
Re: Help with bass_net.vst
« Reply #5 on: 27 Mar '19 - 16:40 »
I don't see why it wouldn't work with VB.Net. Are you sure the VB.Net code is doing exactly the same thing as the working C# code? Are you checking the return values to see which (if any) calls are failing? If not, please do that.

edasps2

  • Posts: 6
Re: Help with bass_net.vst
« Reply #6 on: 5 Apr '19 - 07:38 »
Yeah, I checked it, really weird. The code I'm using is this:

Imports Un4seen.Bass
Imports Un4seen.Bass.AddOn.Vst

Public Class Tela

    Private Sub Tela_Load(sender As Object, e As EventArgs) Handles MyBase.Load
        Dim m_plugIn1DLLFilename
        Dim m_stream1Handle
        m_plugIn1DLLFilename = "C:\Program Files\Vstplugins\sfz+.dll"
        m_stream1Handle = BassVst.BASS_VST_ChannelCreate(44100, 2, m_plugIn1DLLFilename, BASSFlag.BASS_DEFAULT)
    End Sub


radio42

  • Posts: 4655
Re: Help with bass_net.vst
« Reply #7 on: 5 Apr '19 - 08:08 »
I am also not a VB.Net user, but the code works fine here in C#.
Note, that you do not need a reference to BASS_Vst.dll (as this is a native lib) - but you need to place that dll into your runtime directory, e.g. ./Debug/bin !

edasps2

  • Posts: 6
Re: Help with bass_net.vst
« Reply #8 on: 7 Apr '19 - 18:02 »
I did this, I copied the library into the bin folder but unfortunately it did not work, I did a little routine in C # and copied the library and it worked. I would need an example code written in vb.net to compare with my codes to see what I might be doing wrong.