bass.dll - glimmer.bass mod

BlitzMax Forums/BlitzMax Programming/bass.dll - glimmer.bass mod

Docster(Posted 2011) [#1]
Hello ppl! :)

I'm trying out the glimmer.bass module in blitzmax. But, I have a problem.. Loading a tune from my HDD works as expected.

Global channel:Int = BASS.StreamCreateFile(False, "sound/music.ogg", 0, 0, 0)

But, how do I use bass with incbined data?

incbin "sound/music.ogg"

global channel:int = BASS.StreamCreateFile(False, "incbin::sound/music.ogg", 0, 0, 0)

Don't work. Have tried using streams, but, I can't figure out how to do this, anyone?

PS! Is glimmer.bass the only wrapper for bass.dll ?

Thanks in advance
Doc


jkrankie(Posted 2011) [#2]
I've not tried glimmer.bass, but Brucey has a BASS wrapper on his SVN which i've been using for some time. It's pretty good too!

Cheers
Charlie


Jesse(Posted 2011) [#3]
make sure you didn't miss-spell any words. I mean such as capitals incbin is case sensitive for declaration and use.


Gabriel(Posted 2011) [#4]
Oh god, now what have I done? :)

I think you should be using TBassStream.StreamCreateMem if you're loading from IncBin (although I will say right now that I've never loaded from IncBin!)

Here's a line from my Stratos game engine, and I think this is what you're trying to do.

TBassStream.StreamCreateMem(LoadedMusic.Address, LoadedMusic.Length, BASS_SAMPLE_LOOP)


That should give a rough idea of how to use the function. In order to tie that in with IncBin (I'm using zlib there, I think) you'll need to use IncBinPtr and IncBinLen to get the pointer and length of the memory block you're trying to load/stream from, instead of LoadedMusic.Address and LoadedMusic.Length respectively.

Last edited 2011


Docster(Posted 2011) [#5]
I downloaded Brucey's SVN bass package, and it works perfectly!! :D Thanks for all help. :)


Hardcoal(Posted 2016) [#6]
why cant i make this bass mod works?
..

it keeps telling me "Can't find interface for module 'bah.bass'"
im trying to run the exmaples inside the mod..
and it aint working..

its not the first time i try testing this mode.

last time i gave up..

im under windows 7 64 bit.

please tell me what to do.

ill keep trying..

i also tried to build the module on blide and it didnt do the build
without telling why.


Brucey(Posted 2016) [#7]
Have you used any module before?

If not, then you would need to put it in the right place to start with.
For bah.bass it would need to be here :
BlitzMax/mod/bah.mod/bass.mod

bass.mod folder would contain files like bass.bmx, etc.

Once it's in the right place, you will need to build it - either build modules from the ide, or you can build it on the command line from the BlitzMax/bin folder :
bmk makemods -a bah.bass


Once that has worked, you should be able to compile the examples.
Note that you may (if you are using the default bmk) need to copy the bass.dll into the examples folder for the examples to run. It is included in the lib folder as part of the module.


Hardcoal(Posted 2016) [#8]
Yea..
It would be nice if there was a doc
Indicating it should be on the bah
And not on the main mod folder..

I have used modules before. Certainly.

Tnx brucey , ill try it when im on the pc later


Hardcoal(Posted 2016) [#9]
tnx brucey ure the greatest..
obviously it worked.
all i needed to do is put the mod into the bah mod..
and rebuild like u said .

how the hell could i know that by my self.
up till now i though all modules should be on the main mod folder.

but now i know better.


Hardcoal(Posted 2016) [#10]
where can i find documents about this mod?


Brucey(Posted 2016) [#11]
There is a modules section in the IDE documentation that explains how the mods folder structure works.

If you rebuild the documentation, you should also find the BASS docs in Help under Third Party Modules.

Also the examples show you basic setup and some of the APIs.


Hardcoal(Posted 2016) [#12]
I didnt know you can build documents.. Tnx..