Show Posts
|
|
Pages: [1] 2 3 ... 7
|
|
1
|
Developments / BASS / Re: BASS.NET API 2.4.9.1
|
on: 16 Dec '12 - 20:32
|
Please Ignore. Problem was an old BassFx.dll  When I compile this piece of code in Debug mode, the code runs perfect. static void Main(string[] args) { Bass.BASS_Init(0, 44100, 0, IntPtr.Zero);
int stream = Bass.BASS_StreamCreateFile(@"C:\test.mp3", 0, 0, BASSFlag.BASS_STREAM_DECODE); if (stream != 0) { float newBPM = BassFx.BASS_FX_BPM_DecodeGet(stream, 0, 0, 0, BASSFXBpm.BASS_FX_BPM_BKGRND | BASSFXBpm.BASS_FX_FREESOURCE | BASSFXBpm.BASS_FX_BPM_MULT2, null, IntPtr.Zero); Console.Write(newBPM.ToString()); }
Bass.BASS_Free(); }
Where I change the output to Release, I get : A call to PInvoke function 'Bass.Net!Un4seen.Bass.AddOn.Fx.BassFx::BASS_FX_BPM_DecodeGet' has unbalanced the stack. This is likely because the managed PInvoke signature does not match the unmanaged target signature. Check that the calling convention and parameters of the PInvoke signature match the target unmanaged signature.
|
Reply
Quote
|
|
|
3
|
Developments / BASS / Re: BASS.NET API 2.4.9.1
|
on: 4 Oct '12 - 09:00
|
|
Hi,
I just found out that the flag WaveForm.MARKERDRAWTYPE.NamePositionAlternate fails to work when you have 2 markers at the same position. Instead of drawinf the text at alternating positions, they are drawn at the same position. If I change the position of either one of the markers, they are drawn at alternating positions.
Is there a workaround for this problem?
|
Reply
Quote
|
|
|
6
|
Developments / BASS / Re: BASS.NET API 2.4.9.0
|
on: 19 Sep '12 - 20:00
|
Hi, Can anybody tell me why the resulting MP3 is completly silent. If I use the FlacEncoder all works well. int channel = BassCd.BASS_CD_StreamCreate(driveNum, cddbTrack.TrackNumber-1, Un4seen.Bass.BASSFlag.BASS_STREAM_DECODE);
lameEncoder = new EncoderLAME(channel); lameEncoder.InputFile = null; //STDIN lameEncoder.OutputFile = "C:\\test.mp3"; lameEncoder.LAME_Bitrate = 320; lameEncoder.LAME_Mode = EncoderLAME.LAMEMode.Default; lameEncoder.LAME_TargetSampleRate = (int)EncoderLAME.SAMPLERATE.Hz_44100; lameEncoder.LAME_Quality = EncoderLAME.LAMEQuality.Q0; lameEncoder.Start(null, IntPtr.Zero, false);
while (Bass.BASS_ChannelIsActive(channel) != BASSActive.BASS_ACTIVE_STOPPED && !abort) { totalBytes += Bass.BASS_ChannelGetData(channel, buffer, dwBytes); progressHandler(((float)totalBytes / (float)length), ref abort); }
|
Reply
Quote
|
|
|
8
|
Developments / BASS / Re: BASS.NET API 2.4.9.0
|
on: 8 Jul '12 - 22:09
|
|
Problem is solved by downloading the newer 2.4.9.0 version of Bass .Net (The previous version with the wrong version number had this problem).
When you save a WaveForm to disk using the function :
... waveForm.FileName = "C:\\Test_File.MP3"; waveForm.WaveFormSaveToFile("C:\\TEST.WF", true);
And load the WaveForm back using the function :
... waveForm.WaveFormLoadFromFile("C:\\TEST.WF", true);
the waveForm.FileName field is empty.
When I look in the file C:\TEST.WF I can see the given filename (C:\Test_File.mp3).
Is there something broken? I can recall this used to work, since I stored the original gain information in the filename property.
|
Reply
Quote
|
|
|
10
|
Developments / BASS / BassEnc recording first 2 channels from an 8 channel Mixer
|
on: 4 Jul '12 - 22:22
|
|
Hello,
I have got an 8 channel Decoding Mixer. I would like to record the first 2 channels.
I feed the decoding channel from the Mixer into a BassAsioHandler. When I also feed this decoding channel in the encoder it records the output from all 8 channels.
I tried to feed the decoding channel into a new Mixer and use a MatrixMixer ot only select the first 2 channels, but then the encoded file is empty. When I Use BASS_ChannelGetData the encoded output is filled, but this steals samples from the ASIO output.
Any help would be appreciated.
|
Reply
Quote
|
|
|
11
|
Developments / BASS / Re: BASS_DSHOW Video Library
|
on: 30 May '12 - 22:53
|
|
Hi,
I tried the .Net Demo on a Windows 7 machine and I don't hear any audio, the video is playing. When I try the Demo on a Windows XP machine all is working fine. Am I doing something wrong?
|
Reply
Quote
|
|
|
12
|
Developments / BASS / Re: BASS.NET API 2.4.9.0
|
on: 22 May '12 - 10:36
|
|
Hi,
Is it true that you have to create a new waveform everytime? I am trying to re-use a created waveform, but it refuses to calculate the waveform.
I create a WaveForm in the formload en using it in a button press.
if I run this code 1 time, the peakfile is created an has data inside the file.
waveForm.RenderStart(decodeStream, false, false); waveForm.WaveFormSaveToFile("c:\\temp\\peak.wf", true); waveForm.Reset();
If I run this code a second time RenderStart returns immediately, the peakfile is updated, but apart from the header it contains only 0's.
What am I doing wrong?
|
Reply
Quote
|
|
|
13
|
Developments / BASS / Re: BASS.NET API 2.4.8.4
|
on: 17 Jan '12 - 14:28
|
|
I tried to use the waveform class using this code :
WaveForm _wf;
private void Initialize() { _wf = new WaveForm; }
private void LoadFile(string fileName) { WaveForm.FileName = fileName; WaveForm.RenderStart(true, BASSFlag.BASS_DEFAULT); if (WaveForm.NotifyHandler == null) WaveForm.NotifyHandler = new WAVEFORMPROC(WaveFormUpdate); }
The first time everything works fine, but I can't get it to work the second time. either with the same or a different filename. If I create a new WaveForm everytime it works.
Is this meant to work like this? Or am I missing something?
|
Reply
Quote
|
|
|
15
|
Developments / BASS / Re: BASS.NET API 2.4.5.1
|
on: 9 Oct '09 - 13:27
|
Hello, I'm looking for the .NET examples. I Once downloaded them (or got them in a Bass.Net installation). Where can I get the newest examples (If there are any  )? gr. Harold
|
Reply
Quote
|
|
|
16
|
Developments / BASS / Re: BassMix
|
on: 26 Nov '08 - 13:06
|
The first example works and return 1500, but that's without playing. The second example return 0 as position instead of 1500. aDecodingChannel := BASS_StreamCreateFile( False, PChar(sFilename), 0, 0, BASS_STREAM_DECODE ); BASS_Mixer_StreamAddChannel(aMixingChannel, aDecodingChannel, BASS_MIXER_MATRIX); BASS_ChannelSetPosition( aDecodingChannel, 1500, BASS_POS_BYTE); BASS_Mixer_ChannelSetPosition( aMixingChannel, 0, BASS_POS_BYTE); ShowMessage(IntToStr(BASS_Mixer_ChannelGetPosition( aDecodingChannel, BASS_POS_BYTE))); aDecodingChannel := BASS_StreamCreateFile( False, PChar(sFilename), 0, 0, BASS_STREAM_DECODE ); BASS_Mixer_StreamAddChannel(aMixingChannel, aDecodingChannel, BASS_MIXER_MATRIX); BASS_ChannelPlay( aMixingChannel, True ); BASS_ChannelPause( aMixingChannel ); BASS_ChannelSetPosition( aDecodingChannel, 1500, BASS_POS_BYTE); BASS_Mixer_ChannelSetPosition( aMixingChannel, 0, BASS_POS_BYTE); ShowMessage(IntToStr(BASS_Mixer_ChannelGetPosition( aDecodingChannel, BASS_POS_BYTE))); Anything I have missed? Kind regards, Harold Oudshoorn
|
Reply
Quote
|
|
|
17
|
Developments / BASS / BassMix
|
on: 25 Nov '08 - 08:14
|
Hello, In this example BASS_ChannelPlay( aMixChannel, True );
// Wait for position 3000
BASS_ChannelPause( aMixChannel ); BASS_Mixer_ChannelSetPosition( aOutputChannel, 15000, BASS_POS_BYTE);
NewPos := BASS_Mixer_ChannelGetPosition( aOutputChannel,BASS_POS_BYTE ); Newpos returns with 3000 instead of 15000. Is there any way to make the function return 15000. ie Flushing the mixer buffer? Kind regards, Harold Oudshoorn
|
Reply
Quote
|
|
|
19
|
Developments / BASS / Re: Two BassMix questions
|
on: 19 Nov '08 - 21:36
|
Hi, Here's a sample which shows the problem. The problem shows with both the Mixing and Decoding channel. BassMix.dll version 2.4.0.2, Bass.dll version 2.4.2.2 .. .. public aDecodingChannel : HStream; aMixingChannel : HStream; .. ..
procedure TForm2.Button1Click(Sender: TObject); var sFilename : String; begin BASS_Init(1, 44100, 0, 0, nil); aMixingChannel := BASS_Mixer_StreamCreate( 44100, 2, 0 ); if PromptForFileName(sFilename) then begin aDecodingChannel := BASS_StreamCreateFile( False, PChar(sFilename), 0, 0, BASS_STREAM_DECODE ); BASS_Mixer_StreamAddChannel(aMixingChannel, aDecodingChannel, BASS_MIXER_MATRIX); BASS_ChannelPlay( aMixingChannel, True ); tmrVuMeter.Enabled := True; end; end;
procedure TForm2.tmrVuMeterTimer(Sender: TObject); var iVuLevel : Integer; begin iVuLevel := LoWord(BASS_Mixer_ChannelGetLevel( aDecodingChannel )); ProgressBar1.Position := Round( ProgressBar1.Max * (iVuLevel/ 32768 ) ); end;
Kind Regards, Harold Oudshoorn
|
Reply
Quote
|
|
|
20
|
Developments / BASS / Re: Two BassMix questions
|
on: 19 Nov '08 - 20:44
|
|
Hi,
The Sync is working, thanks. I wasn't aware of the BASS_Mixer_ChannelSetSync funtion.
The ChannelGetLevel I already tried with both the Decoding and the MixingChannel. The result is all the same. Anymore ideas? Samples? Snippits?
Kind Regards, Harold
|
Reply
Quote
|
|
|