BASS_FX 2.4.12.1

Started by (: JOBnik! :),

Renegade

Quote from: (: JOBnik! :)Hi ;D

Please try again, the website was down for a few minutes today :)

Still no love. Same error. :(

I can download it no problem - I just can't extract anything.

(: JOBnik! :)

Hi ;D

Please try downloading with different browser.
I myself tried with Chrome and IE and could extract without any problem.
Maybe your antivirus is blocking it?

victor

Quote from: (: JOBnik! :)Here's the latest beta to test (Win32 and Win64), it includes "Freeverb" effect and C/C++ API with example.
http://www.jobnik.org/files/beta/bass_fx24109-beta.zip

I guess on next week I'll release it as final 2.4.11 version for all platforms.
when will you release the 2.4.11?
Could you please make a download with an OSX beta?

Thanks.

devid1988

Hi  ;D
Works well with me
  But how does it work on Delphi

freeverb

Thank you very much

(: JOBnik! :)

Hi ;D

there's now version 2.4.11 is released

2.4.11 - 02/09/2014
* BASS_FX:
   * Fixed an issue on OSX (The Xcode project's "Installation Directory" setting set to "@loader_path" instead of "@executable_path").
   * Tempo/Reverse fixed a thread-safety crash.
   * Tempo/Reverse added CTYPE info for these streams.
   * Android, added "x86" architecture support (some effects are buggy, will be fixed soon).
   * iOS, added "arm64" architecture support.
   * Fixed Delphi/Pascal unit by changing "FLOAT" to "Single".
   * Added C/C++ "freeverb" example.

* Tempo:
   * Updated to latest SoundTouch library version 1.8.0
   * Fixed a crash when using syncs on tempo, as described in this thread: http://www.un4seen.com/forum/?topic=15708.0
   * Added 3 interpolation algorithms to set using BASS_FX_TEMPO_ALGO_XXX flags (BASS_FX_TempoCreate):
      * BASS_FX_TEMPO_ALGO_LINEAR
      * BASS_FX_TEMPO_ALGO_CUBIC   (default)
      * BASS_FX_TEMPO_ALGO_SHANNON

* DSP:
   * Fixed a bug in BASS_FX_BFX_VOLUME_ENV effect with the "bFollow" option on mobile devices,
     as described in this thread http://www.un4seen.com/forum/?topic=15866
   * Added new effects:
     * BASS_FX_BFX_PITCHSHIFT, that uses FFT for its pitch shifting while maintaining duration.
     * BASS_FX_BFX_FREEVERB, a reverb effect.

BenMaas

Hi.

I think the Delphi version of bass_fx.pas has some minor mistakes.

   // Freeverb
const
   BASS_BFX_FREEVERB_MODE_FREEZE = 1;

type
   BASS_BFX_FREEVERB = record
      fDryMix: Single;                 // dry (unaffected) signal mix            [0........1], def. 0
      fWetMix: Single;                 // wet (affected) signal mix            [0........3], def. 1.0f
      fRoomSize: Single;               // room size                        [0........1], def. 0.5f
      fDamp: Single;                   // damping                           [0........1], def. 0.5f
      fWidth: Single;                  // stereo width                        [0........1], def. 1
      lMode: DWORD;                   // 0 or BASS_BFX_FREEVERB_MODE_FREEZE, def. 0 (no freeze)
      lChannel: Integer;              // BASS_BFX_CHANxxx flag/s
   end;

Also :

   // tempo algorithm flags
   BASS_FX_TEMPO_ALGO_LINEAR  = $200 ;      
   BASS_FX_TEMPO_ALGO_CUBIC   = $400  ;            // default
   BASS_FX_TEMPO_ALGO_SHANNON = $800 ;

Red stuff was missing.

BenMaas

hi again.

Some posts earlier Ian @ Un4seen posted a way to add silent padding to a sample. Since i am a delphi user and never got into C i have a bit trouble to convert it. Would be really nice if someone could help me.

decoder=BASS_StreamCreateFile(FALSE, filename, 0, 0, BASS_STREAM_DECODE); // create decoder for audio file
BASS_CHANNELINFO ci;
BASS_ChannelGetInfo(decoder, &ci); // get sample format
output=BASS_StreamCreate(ci.freq, ci.chans, ci.flags&~BASS_STREAM_DECODE, StreamProc, 0); // create stream to play decoded data + silent padding
padding=BASS_ChannelSeconds2Bytes(output, paddingseconds); // length of silent padding
BASS_ChannelPlay(output, 0); // start the output

...

DWORD CALLBACK StreamProc(HSTREAM handle, void *buffer, DWORD length, void *user)
{
int r=BASS_ChannelGetData(decoder, buffer, length); // get data from the decoder
if (r<0 || !BASS_ChannelIsActive(decoder)) { // end of file, add padding...
if (r<0) r=0;
int c=min(length-r, padding); // amount of padding to add
memset(((BYTE*)buffer)+r, 0, c); // add the padding
r+=c;
padding-=c; // decrease padding counter
if (!padding) r|=BASS_STREAMPROC_END; // no more padding, end of stream
}
return r;
}

I know most of the equivalent syntax but i don't know what the counterpart for memset is.

(: JOBnik! :)

Hi ;D

Thanks, Delphi/Pascal unit is fixed now :)

Quote from: BenMaasHi.

I think the Delphi version of bass_fx.pas has some minor mistakes.

   // Freeverb
const
   BASS_BFX_FREEVERB_MODE_FREEZE = 1;

type
   BASS_BFX_FREEVERB = record
      fDryMix: Single;                 // dry (unaffected) signal mix            [0........1], def. 0
      fWetMix: Single;                 // wet (affected) signal mix            [0........3], def. 1.0f
      fRoomSize: Single;               // room size                        [0........1], def. 0.5f
      fDamp: Single;                   // damping                           [0........1], def. 0.5f
      fWidth: Single;                  // stereo width                        [0........1], def. 1
      lMode: DWORD;                   // 0 or BASS_BFX_FREEVERB_MODE_FREEZE, def. 0 (no freeze)
      lChannel: Integer;              // BASS_BFX_CHANxxx flag/s
   end;

Also :

   // tempo algorithm flags
   BASS_FX_TEMPO_ALGO_LINEAR  = $200 ;      
   BASS_FX_TEMPO_ALGO_CUBIC   = $400  ;            // default
   BASS_FX_TEMPO_ALGO_SHANNON = $800 ;

Red stuff was missing.

devid1988

#648
Thank you very much
It works successfully


 ;D

BenMaas

#649
Effecttails for Delphi users :

I managed to get Ians example making effecttails possible to work under Delphi and thought that i can share it.

var

    decoder,chan : Dword;
    silentpadding : Qword;
    ci : Bass_channelinfo;

 decoder := BASS_StreamCreateFile(FALSE, pchar(filename), 0, 0, BASS_STREAM_DECODE or BASS_UNICODE);
  BASS_ChannelGetInfo(decoder, ci);

  chan := BASS_StreamCreate(ci.freq, ci.chans, ci.flags and not BASS_STREAM_DECODE, @effecttailcallback, 0);
  silentpadding := BASS_ChannelSeconds2Bytes(chan, 10);  //a maximum freeverb effect has an effecttail of about 9 seconds, so 10 seconds should be enough for any setting

  BASS_ChannelPlay(chan, FALSE);

function  effecttailcallback (handle: HSTREAM; buffer: Pointer; length: DWORD; user: Pointer): DWORD; stdcall;
var r,c : integer;
      buffer2 : pointer;
      buf2car : cardinal;

begin
//
r := BASS_ChannelGetData(decoder, buffer, length); // get data from the decoder
if ((r < 0) or (BASS_ChannelIsActive(decoder) = BASS_ACTIVE_STOPPED)) then  // end of file, add padding...
begin
                if (r<0) then r:=0;
c := min(length-r, silentpadding); // amount of padding to add

                buf2car := cardinal (buffer);
                buffer2 := pointer (buf2car + r)
                fillchar (buffer^, c , #0);

r := r + c;
silentpadding := silentpadding - c; // decrease padding counter

if silentpadding <= 0 then r := BASS_STREAMPROC_END; // no more padding, end of stream
end;

result := r;
end;

Plummm

Thanks for BASS_FX first,it works very well.
Now,I have a question that can I save the adjusted audio?

Ian @ un4seen

If you want to write a BASS channel's output (including any DSP/FX that are set on it) to a file, the BASSenc add-on is the easiest way to do that. Please see the BASS_Encode_Start documentation for details.

Daniel S.

Hi,

first of all, thank you for making Bass FX. It's great and really easy to use!
When I try to download the new iOS Version using the link in the first post of this thread (http://www.jobnik.org/BASS_FX/bass_fx24-ios.zip) I get a 404 error. Did you remove the file on purpose? Are you going to put it back up?

Thanks for your time!

(: JOBnik! :)

Hi ;D

You can download it now, it was by mistake named as "bass_fx24-iphone.zip" on server ;)

jnyang

Hi,

I found there are some typos in BASS_FX.java (Android) for version 2.4.11.

On line 22 and 23, semicolons are missing.
public static final int BASS_CTYPE_STREAM_TEMPO = 0x1f200;
public static final int BASS_CTYPE_STREAM_REVERSE = 0x1f201;

On line 294 and 308, "public static" should be replaced to "public static class" like this:
public static class BASS_BFX_PITCHSHIFT {
   ...
}
public static class BASS_BFX_FREEVERB {
   ...
}

Btw, I really appreciate for your great support of BASS FX!  :D

(: JOBnik! :)

Hi ;D

Thanks, an android BASS_FX.java is fixed now :)
I've also added safeseh BASS_FX.LIB to the windows package.

tlgkccampbell

Hi Jobnik,

Either I'm overlooking something obvious, or I've run into what seems to be a bug in the 64-bit version of bass_fx 2.4.11 on Linux (Ubuntu 14.04).  The following code works as expected when compiled against the 32-bit version of the library, but produces a segmentation fault in BASS_FX_TempoCreate() when compiled against the 64-bit version of the library.

#include <stdlib.h>
#include <stdio.h>
#include "bass.h"
#include "bass_fx.h"

int main()
{
int result = BASS_Init(-1, 44100, 0, 0, 0);
if (result == 0)
{
printf("BASS_Init() failed: %i\n", BASS_ErrorGetCode());
return 1;
}

DWORD stream = BASS_StreamCreateFile(FALSE, "Example.ogg", 0, 0, BASS_SAMPLE_LOOP | BASS_STREAM_DECODE);
if (stream == 0)
{
printf("BASS_StreamCreateFile() failed: %i\n", BASS_ErrorGetCode());
return 1;
}

stream = BASS_FX_TempoCreate(stream, BASS_FX_FREESOURCE);
if (stream == 0)
{
printf("BASS_FX_TempoCreate() failed: %i\n", BASS_ErrorGetCode());
return 1;
}

if (!BASS_ChannelSetAttribute(stream, BASS_ATTRIB_TEMPO_PITCH, -12.0f))
{
printf("BASS_ChannelSetAttribute() failed: %i\n", BASS_ErrorGetCode());
return 1;
}

if (!BASS_ChannelPlay(stream, FALSE))
{
printf("BASS_ChannelPlay() failed: %i\n", BASS_ErrorGetCode());
return 1;
}

printf("Playing stream, press any key...\n");
getchar();

return 0;
}

Thanks for all the time you've put into this library!

(: JOBnik! :)

#657
Hi ;D

Please let me know if this works fine:
http://www.jobnik.net/files/beta/libbass_fx24111-x64-linux.zip

DrummerB

Hi Jobnik,

I would like to recommend the RubberBand time stretching library. It seems to have very good audio quality, but it "just" provides the processing algorithms, no player functionality. It's free with a GNU license (but you can buy commercial licenses as well).

I've been trying to integrate it with BASS, but I don't quite understand how I could apply an effect that returned more data than it received (i.e. stretch the audio). The DSP functions just provide a way to modify the data in place.

Do you think you could add this library as an option, similarly to SoundTouch? That would be great!

Thanks!

rv

wow ! The RubberBand exemples sounds so good....
Arthur need to listen to them :)