05-12-2015 02:41 PM - edited 05-12-2015 03:01 PM
Hello All:
This question is about using Published .net wrappers in LabVIEW, and How to hand Enums to them correctly.
After review of these knowledge base documents, I have been trying to implement BASS.NET in LabVIEW.
So Far so good, but I have run into a problem implementing THIS Method to the same effect as the following code.
// setup the encoder int encoder = BassEnc.BASS_Encode_Start(dummy, null, BASSEncode.BASS_ENCODE_PCM | BASSEncode.BASS_ENCODE_NOHEAD, null, IntPtr.Zero);
The Method needs to be provided muliple flags, BASSEncode.BASS_ENCODE_PCM | BASSEncode.BASS_ENCODE_NOHEAD,
But Can only accept one Enum/Flag.
Have you solved a similar problem in the past? Will post any additional information upon request. Until nessesary I am not going to attach the project file as it is a very finiky x64 build of the related .net/.dll objects. I doubt it would actually load execute/ on any system without the 4-5 coffee cups worth of time it took me to do the same.
Side note, this is my first discussion forum post in a long while. Please comment on how to better relay the nature of the problem.
Solution: (by NathanD) Hand the terminal the equivlent of a bitwise OR function, using the Boolean OR or the Compound arythmatic terminal.
Solved! Go to Solution.
05-12-2015 02:54 PM
You should use a boolean OR, not build array. The | function in C# is a bitwise OR. If you need to combine more than 2 flags, you can use the Compound Arithmetic node set to the OR mode, and expand it to more terminals.