25 May '13 - 12:00
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Home
Help
Search
Login
Register
Un4seen Developments Forum
>
Developments
>
BASS
> Topic:
Recording with BASSAsio and VB.NET
Pages: [
1
]
« previous
|
next »
Reply
|
Print
Author
Topic: Recording with BASSAsio and VB.NET (Read 317 times)
chris_p
Posts: 1
Recording with BASSAsio and VB.NET
«
on:
7 May '12 - 17:47 »
Quote
I am trying to record an input from a soundcard to a .wav file using ASIO and VB.net. The asiorecording C# example works on my system so I assume the hardware and drivers are OK. When I run my VB code no .wav file is created. The declarations are:
Private wav As Un4seen.Bass.Misc.EncoderWAV
Private enc As Un4seen.Bass.Misc.BaseEncoder
Private AsioInfo As Un4seen.BassAsio.BASS_ASIO_INFO
Private myasio As Un4seen.BassAsio.BassAsioHandler
and the code:
Dim info As Un4seen.BassAsio.BASS_ASIO_CHANNELINFO = New Un4seen.BassAsio.BASS_ASIO_CHANNELINFO
Dim chan As Integer = 0
Do While True
If Not Un4seen.BassAsio.BassAsio.BASS_ASIO_ChannelGetInfo(False, chan, info) Then
Exit Do
End If
chan += 1
Loop
myasio = New Un4seen.BassAsio.BassAsioHandler(True, 0, 0, 2, Un4seen.BassAsio.BASSASIOFormat.BASS_ASIO_FORMAT_16BIT, 44100)
myasio.setmirror(0)
AsioInfo = Un4seen.BassAsio.BassAsio.BASS_ASIO_GetInfo()
Dim IsOK As Boolean
IsOK = myasio.Start(AsioInfo.bufmax)
If Not IsOK Then
MsgBox("Could not start ASIO : " & Un4seen.BassAsio.BassAsio.BASS_ASIO_ErrorGetCode().ToString())
End If
wav = New Un4seen.Bass.Misc.EncoderWAV(myasio.InputChannel)
wav.InputFile = Nothing
wav.OutputFile = "d:\test.wav"
wav.Start(Nothing, IntPtr.Zero, False)
enc = wav
The code is modeled on that in the C# example. Any help is appreciated.
Thanks
Chris
Logged
Pages: [
1
]
Reply
|
Print
Un4seen Developments Forum
>
Developments
>
BASS
> Topic:
Recording with BASSAsio and VB.NET
« previous
|
next »
Jump to:
Please select a destination:
-----------------------------
Developments
-----------------------------
=> BASS
=> XMPlay
=> MO3
-----------------------------
Off Topic
-----------------------------
=> General Discussion
Loading...