0
0

Hopefully aybe is still around. 😮 I haven’t found any address to this problem so I guess I must be the only person to be getting that.

Anyway.

I am making a program in VB.NET 2003. As per the instructions in the Wiki article http://52.88.2.202/wiki/index.php5?title=VB I have created the FMODWrapper.dll file, integrated it to my project, and copied the code snippet to make my new FMOD class. So far so good.

The only hic is in the function PlaySound at the bottom, at the following line:
[code:8vcx22m9]Fresult = Fsystem.createStream(selectedsound, FMOD.MODE.SOFTWARE, sound)[/code:8vcx22m9]

Here, I am being told that FMOD.MODE.SOFTWARE is an integer and cannot be converted into a FMOD.MODE type.

Looking into the code of the wrapper, more specifically at the declaration of the MODE enumaration, I find an explicit conversion to unsigned integer – the only one in the whole code.

Simple and stupid solution: I take out the conversion. This leads me to the last value in the enum: VIRTUAL_PLAYFROMSTART = 0x80000000, where I am told I can’t implicitly convert from [i:8vcx22m9]uint[/i:8vcx22m9] to [i:8vcx22m9]int[/i:8vcx22m9].

Bugger! Am I going to need that feature? I don’t think so. I comment it out along with the conversion and re-export. Now the example code given in the Wiki article works perfectly.

I was wondering if anybody ran into the same sort of problem – I figured it may be a good idea to put it up for discussion in order to better help those few of us fervent defenders of Visual Basic. 😀 Perhaps a workaround exists somewhere that’s more elegant than my crude quick-fix?

  • You must to post comments
0
0

try an old VB trick I used in the vb6 days

Fresult = Fsystem.createStream(selectedsound, (FMOD.MODE.SOFTWARE), sound)

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.