problems with bass_fx 1.2

Started by kaen,

kaen

Hi Ian, hi JOBnik,
I've problems when I try to control the tempo (not pitch) of a stream. All streams are playing too fast. By modifying the parameters I neither can't adjust it to regular tempo nor to a slower tempo. All I can do is to make it even faster. All other effects work perfect. What can be the reason for my tempo problem?

Thanks kaen

(: JOBnik! :)

Hi ;D

What about the precompiled Tempo example? Is it working fine?

Have fun!

8) JOBnik! 8)

Chris

#2
Hi are your sure that you have setup the temposlider with a SmallInt and not with a DWORD ???
example
procedure TPlayerA.TempoSet (aValue : DWORD);
begin
 if (Bass_ChannelIsActive(Bass_FX_TempoGetResampledHandle(Channel))= 0 ) then exit;
      Bass_FX_TempoSet(channel,aValue,-1,-100);
end;

Thats wrong because DWORD cannot be set as a negative Value

This will work

procedure TPlayerA.TempoSet (aValue : Shortint);
begin
 if (Bass_ChannelIsActive(Bass_FX_TempoGetResampledHandle(Channel))= 0 ) then exit;
      Bass_FX_TempoSet(channel,aValue,-1,-100);
end;

This will work   ( Shortint -128..127      )

or a better way (This have i make)

type

TTempo = -24..24;


procedure TPlayerA.TempoSet (aValue : TTempo);
begin
 if (Bass_ChannelIsActive(Bass_FX_TempoGetResampledHandle(Channel))= 0 ) then exit;
      Bass_FX_TempoSet(channel,aValue,-1,-100);
end;

Greets chris

  

kaen

Hi, JOBnik,
thanks for that fast anser. Yes the precompiled example works fine, the VB source code too.
Unfortunately I'm not at home at the moment, so I will continue testing on monday. If it helps I can post a peace of source code that shows how I did it.

Thanks to Chris too for the guesses. I will check that, but I'm using VB6. Anyway, I will take a look at the function definitions, maybe there is a mistake.

have a nice weekend
kaen

kaen.

In the last days I've solved my tempo problem. It was caused by a timer controlled call to BASS_ChannelGetData to get fft-data for a level meter.
I used a call like "BASS_ChannelGetData stream,..." where stream is the handle returned by BASS_StreamCreateFile. When you use a resampled stream for the tempo control, you have to use "BASS_ChannelGetData BASS_FX_TempoGetResampledHandle(stream),..."
Now it works perfect.