Author Topic: BASS for Linux  (Read 206096 times)

fredvs

  • Posts: 327
Re: BASS for Linux
« Reply #50 on: 20 Dec '08 - 12:07 »
Hi everybody, hello Ian.
I have tried to compile a demo prog using bass in Lazarus for Linux.
If i add BASS in USES (from your Pascal Linux pre Release), it compile with no problem but when i execute the compiled prog, nothing appends...even if i dont use any of the bass function.

Maybe i forgot to do something with the bass library?

Thanks for your help.

fredvs

  • Posts: 327
Re: BASS for Linux
« Reply #51 on: 21 Dec '08 - 11:30 »
Re-hello everybody.
I use Lazarus for Windows and Linux, (it is a RAD Pascal free).
I have developped a bass-test prog, if i compile it with Lazarus on a Windows system, everything perfect, compilation with no stress and a exe-file working.

If i compile it on a Linux system, compilation OK, a executable is created but it does not work. If i dont insert Bass in USES, it execute perfectly but without access at bass procedures of course.

Why do it crash if i add in USES bass, even if i dont use any Bass procedure ?

What must i do with the libbass.so ?

Thanks to all of the Linux Champions. :-*

fredvs

  • Posts: 327
Re: BASS for Linux
« Reply #52 on: 21 Dec '08 - 13:20 »
Im the Champion.... ;D

To install the bass lib in linux :

sudo cp libbass.so /usr/local/lib   (to copy bass library into linux lib)

sudo chmod a+rx /usr/local/lib/libbass.so   (to load the lib)

sudo ldconfig  (to autoconfig)

And my first Bass prog compiled with Lazarus on Linux works like a charm.

Thanks Ian, lot a thinks to translate now and Viva Ubuntu.



saga

  • Posts: 2181
Re: BASS for Linux
« Reply #53 on: 21 Dec '08 - 14:35 »
not all steps are neccessary, i think. I myself copied libbass.so to /lib and that's it. I was able to use it inside FreeBASIC without any further configuration.

fredvs

  • Posts: 327
Re: BASS for Linux
« Reply #54 on: 21 Dec '08 - 14:57 »
Hi Saga.
Whouaw, its so simple....

Any idea how to bild a script to install it automatic ?  ::)

Maybe with a .sh script..?

saga

  • Posts: 2181
Re: BASS for Linux
« Reply #55 on: 21 Dec '08 - 15:11 »
I don't know much about linux myself. but yeah, either you use bash or you create a packet (for example a DEB packet for ubuntu and debian).

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #56 on: 24 Dec '08 - 16:35 »
Hmm.. any plans for linux-amd64 version? ;)

I have now added an x64 build to the beta package (in the "x64" directory). Please report how you get on with it.

bega

  • Posts: 22
Re: BASS for Linux
« Reply #57 on: 25 Dec '08 - 11:54 »
Hi to all. ;D
More simple example using Basic RAD-GAMBAS 2.9 ( VB for Linux ). ;)
http://gambas.sourceforge.net/

Help for termination BASS.module.

Thanks to Ian for Bass for Linux. ;D
Thanks to all

File: http://rapidshare.com/files/176631622/BASStest.tar.gz.html

fredvs

  • Posts: 327
Re: BASS for Linux
« Reply #58 on: 28 Dec '08 - 14:39 »
Hello Ian, hello everybody.
Im working with Bass for Linux.
With Lazarus, everything OK but.... i have problems with  BASS_ChannelSetDSP. (same problems with your example Ian).

I have used your example DSPtest and when i compile it :

rotdsp := BASS_ChannelSetDSP(chan, @Rotate,0, 2);


 i get the error :

Error: Incompatible type for arg no. 3: Got "ShortInt", expected "Pointer"

I have tryed with

rotdsp := BASS_ChannelSetDSP(chan, @Rotate,nil, 2);

but also error...

What is the problem ??????

Otherwise, thanks a lot Ian to care about Linux.

PS. Is it possible to use the DX effects with Linux (linux dont use DX).


saga

  • Posts: 2181
Re: BASS for Linux
« Reply #59 on: 28 Dec '08 - 16:34 »
since the dx effects are built into dx8 and later, i don't expect them to work.

fredvs

  • Posts: 327
Re: BASS for Linux
« Reply #60 on: 28 Dec '08 - 17:40 »
Hi folks, i get it  ;D

Of course i work now on Linux then....

procedure Rotate(handle: HDSP; channel: DWORD; buffer: Pointer; length: DWORD; user:Pointer); stdcall;

must become

procedure Rotate(handle: HDSP; channel: DWORD; buffer: Pointer; length: DWORD; user:Pointer); cdecl;

And then all the DSP effect works more than charms.

Thanks Ian

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #61 on: 29 Dec '08 - 13:33 »
Yep, all functions (including callbacks) use the "cdecl" calling convention in the Linux version (same as the OSX version). The "stdcall" calling convention is only used in the Windows version.

fredvs

  • Posts: 327
Re: BASS for Linux
« Reply #62 on: 2 Jan '09 - 17:04 »
Hi Ian.
For me, XXXXX OK, i have tried +- all of your bass functions and everything works perfectly with Lazarus on Ubuntu 8.
Goog job Ian. ;)

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #63 on: 2 Jan '09 - 17:46 »
Jolly good :)

saga

  • Posts: 2181
Re: BASS for Linux
« Reply #64 on: 6 Jan '09 - 17:07 »
Are there any plans about OSS support? A friend of mine tried to run my game in linux but since he had to uninstall ALSA, he doesn't get any sound.

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #65 on: 7 Jan '09 - 14:46 »
I'm afraid there aren't any plans for OSS support at the moment, but perhaps in future should the demand arise.

saga

  • Posts: 2181
Re: BASS for Linux
« Reply #66 on: 19 Feb '09 - 14:30 »
Are there any plans about an "official" release date yet? :)

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #67 on: 20 Feb '09 - 17:44 »
I'm still waiting for a bug to show up; there must be at least one :)

It would also be good to have an "mp3-free" version. I don't think any of the Linux distros include an MP3 decoder as standard, but libmad seems to be the most readily available via 3rd-party repos. Please let me know if you know of any others that are more widespread.

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #68 on: 26 Feb '09 - 17:18 »
Actually, libmad is under the GPL licence, so it's probably best to avoid that (as BASS isn't GPL). But libmpg123 is under the more relaxed LGPL licence, so I've built an "mp3-free" version that uses that, which is now included in the beta package (see 1st post). The libmpg123 library comes with mpg123 (a command-line player), but can also be installed separately (although that seems to be less common). Of course, the "mp3-free" BASS will still function without libmpg123 installed, but MP3 stream creation will fail with a BASS_ERROR_CODEC error.

It hasn't been tested much yet, so please report any problems that you encounter.

The standard BASS version has also been rebuilt to include the latest stuff.

saga

  • Posts: 2181
Re: BASS for Linux
« Reply #69 on: 28 Feb '09 - 12:39 »
Thanks for the update. I'll try out the mp3-free version, but I normally only use OGG samples... =)

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #70 on: 2 Mar '09 - 16:40 »
If nothing else, the "mp3-free" version could save you some space in that case :)

saga

  • Posts: 2181
Re: BASS for Linux
« Reply #71 on: 2 Mar '09 - 16:49 »
That's true. :) I wasn't really able to test it thoroughly yet as I have some problems with the freebasic gfxlib under linux - my game is starting and I can hear sound, but it doesn't run very well on my old laptop... I'll have to try the examples then.

Speaking of which, where can I find the latest mp3-free "stuff" version for windows? The "stable" mp3-free version is too old for me because of the new MOD order list features.
« Last Edit: 2 Mar '09 - 16:54 by saga »

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #72 on: 2 Mar '09 - 16:58 »
A fairly recent Win32 "mp3-free" version update is available here...

   www.un4seen.com/stuff/bass.dll-mp3free

Ian @ un4seen

  • Administrator
  • Posts: 20437
Re: BASS for Linux
« Reply #73 on: 18 Mar '09 - 17:39 »
As there don't appear to be any problems, the debug stuff has now been removed, and "release candidate" versions of BASS and the add-ons are now up (see 1st post). If there are still no problems, the final release shouldn't be too far off.

fredvs

  • Posts: 327
Re: BASS for Linux
« Reply #74 on: 18 Mar '09 - 20:08 »
Hi Ian, XXL OK for your new release.
And, by the way, i annonce you the birth of MiXimum, the DJ's best friend.
Beta version for Linux, Windows and Mac avalaible soon...