Old 17th February 2004, 22:23   #1
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
USING a dll to play music

im interested in using this dll to play Mod's, XM's, and S3m's
http://www.un4seen.com/
spacifically bassmod 1.6
http://www.un4seen.com/bass.html#stuff
it uses a dll called BASSMOD.dll

how do i go about loading that dll up and calling it to play my music in the NSIS install? i just want it to start the music and loop until closed the application.

im not really a great programmer with all this stuff. i did a search and all it came up with is playing music with bgimage or whatever... and that was only for WAV files
can anyone help me out? i posted a topic at the forums at the other location, but im sure i need more help from your guys end of things.

im sure i can find out what functions need to be called when needed, but how would i integreat that into NSIS script?
MindlessOath is offline   Reply With Quote
Old 17th February 2004, 23:10   #2
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
I am currently working on a NSIS plugin for playing OGG files and possibly later MP3s. I have not come across the formats you listed before therefore I'm not certain of how this dll works but a starting point would be to get the list of exported funtions and their c prototypes so that they can be called using the system plugin.

Vytautas
Vytautas is offline   Reply With Quote
Old 18th February 2004, 00:00   #3
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
just to let you know...
http://www.un4seen.com/
has a dll that will play mp3's ogg's and etc.. aswell.. they have source code for it i belive in vb, c++, and probably delphi.

hope that helps you out.

ok.. so once i know these functions.. how do i implement them into the NSIS scrip??? im a total noob at NSIS right at the moment.. i know only basic functions and whatever is in the help file.

anyone know how i go about implimenting these functions and such from a dll to play music?
MindlessOath is offline   Reply With Quote
Old 18th February 2004, 00:04   #4
Yathosho
Forum King
 
Yathosho's Avatar
 
Join Date: Jan 2002
Location: AT-DE
Posts: 3,368
hehe, mp3s/oggs are kinda against the nature of lean installers (that applies to downloadable files of course). but tracker formats would definitely be cool

however, i'd be interested to know, if your dll (Vytautas) can play the files looped (gapless?).
Yathosho is offline   Reply With Quote
Old 18th February 2004, 00:38   #5
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
ya thats what i was thinking.. why use mp3, wav, ogg, or other HUGE music files??? unless you install is huge already than a 3MB file added wont make much of a differnce, but using tracker music would be great... like mod's and XM's etc. www.modcentral.com i belive will clue you in on some of the music their. or is it www.modplug.com - ya thats it.

they are idea cause they are only kilobytes in size, and their for dont take up much at all space, problem is, not many applications or programmers know how to impliment tracker playing in applications. but some do, and thats where we get these dll's etc. hopefully someone could impliment this trackers support. i have seen one installer that provides support using this.... but i dont like it as much as NSIS, to much bloat if ya ask me.

i just went searching through the archive.. and it looks like IM not going to be able to program this function into my scripts at all.. so if someone could do this for me (and many many others) it would be greatly appreciated!!!
MindlessOath is offline   Reply With Quote
Old 18th February 2004, 01:45   #6
Vytautas
Major Dude
 
Vytautas's Avatar
 
Join Date: May 2003
Location: Victoria, Australia
Posts: 643
Send a message via ICQ to Vytautas
Can you convert wav file to mod files?

You see the main reason for the plugin was also the ability to compress wave file into ogg format for distribution and the decode them during setup. As a added functionality, since the decoding engine is already in the plugin I will add the ability to play the files aswell.

Looped play is in the todo list, very close to the top of it actually. Will most likely be in the first release.

Also thanks for the link I will check out their code and see if I can improve on mine

Vytautas
Vytautas is offline   Reply With Quote
Old 18th February 2004, 06:17   #7
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
well all i ask is when trying to improve on your script... try and add the MOD play support if at all possible.

i do belive Mod's can be converted into any format.. usually mp3, probably wav and most likely if it can go in either or of those two.. it can get into ogg format.

a MOD is basically a buncha really small wav file samlples played in a list that tunes the tones up and down to make music. its very advanced, and its REAL MUSIC since you HAVE to compose it. thats what makes it so unique. and thats what makes it so small too.
MindlessOath is offline   Reply With Quote
Old 5th March 2004, 14:19   #8
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
Here are the functions I made to play MOD files using BASSMOD.dll (version 1.6):
$filename is the file to load
$songtitle is the song title (doh)

attachment: example with multiple mod files in a dropdown list

if any1 knows how to put play/stop buttons within the bottom of the MUI, please PM/Mail me!! (i want to skip the MOD page)

oh yeah, the defines for BASS_MUSIC_LOOP etc are in the example...
-------------------------------------------------------------------------------

Function BASSMOD_MusicGetName
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicGetName()t.r0'
StrCpy $songtitle $0
FunctionEnd

Function BASSMOD_Init
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_Init(i,i,i) (-1,44100,0)'
FunctionEnd

Function BASSMOD_MusicStop
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicStop'
FunctionEnd

Function BASSMOD_MusicLoad
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicLoad(i,t,i,i,i) (0,"$PLUGINSDIR\$filename",0,0,${BASS_MUSIC_LOOP}|${BASS_MUSIC_RAMPS}|${BASS_MUSIC_SURROUND}|${BASS_MUSIC_POSRESET})'
FunctionEnd

Function BASSMOD_Rewind
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicSetPosition(i) (0)'
FunctionEnd

Function BASSMOD_MusicFree
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicFree'
FunctionEnd

Function BASSMOD_Free
System::Call 'BASSMOD::BASSMOD_Free'
FunctionEnd

Function BASSMOD_MusicPlay
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicPlay'
FunctionEnd
Attached Files
File Type: zip bassmod_nsis_example.zip (86.9 KB, 827 views)

@p0ll0
apollo51 is offline   Reply With Quote
Old 5th March 2004, 21:02   #9
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
YOU ARE GOD!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

thank you so much man. im sure to give u credits! woot
MindlessOath is offline   Reply With Quote
Old 5th March 2004, 21:05   #10
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
no problem, I made it for myself and got the topic from Kichik

@p0ll0
apollo51 is offline   Reply With Quote
Old 5th March 2004, 21:09   #11
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
im just so really glad you decided to share with us. you are so kind, and i am very appreciative of the work you had done.

btw to let others know.. you have to have the dll basemod.dll in the directory.


also your bug report...
code:
Function .onGUIEnd
Call BASSMOD_Free
;HelpButton::end
System::Free 0
FunctionEnd


as you can see i had to comment out ;HelpButton::end
dunoo why or what it does, but it compiled after i removed it.
MindlessOath is offline   Reply With Quote
Old 5th March 2004, 21:14   #12
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
hehe yes, I forgot to remove it, I was trying to add Play/Stop controls to the bottom of the MUI pages, but didn't work out.

I updated the code with XM/IT/MOD/S3M/MTM listing and functions for BASSMOD instead of System Calls

Don't know if the functions are in the test.nsi that I've uploaded here.

@p0ll0
apollo51 is offline   Reply With Quote
Old 5th March 2004, 21:16   #13
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
omg omg omg ... you would be so kind and let us into that?

whenever you want that is

hrm.. i have to go right now, get back to ya later.
MindlessOath is offline   Reply With Quote
Old 5th March 2004, 21:23   #14
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
The link to the latest version is: http://www.apollo51.demon.nl/nsis/nsis%20test.zip

@p0ll0
apollo51 is offline   Reply With Quote
Old 6th March 2004, 00:13   #15
Fl0ppy
Junior Member
 
Join Date: Feb 2004
Posts: 7
music installing

Great work!! but maybe you can helpme with this:

I want a installer with a .mod playing.

With the next sentences (l00k the attachment)

I mind, just a: play music while installing the files.

Thanks
Attached Files
File Type: zip sentry.zip (932 Bytes, 460 views)
Fl0ppy is offline   Reply With Quote
Old 6th March 2004, 06:02   #16
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
it does just play music when installing files. it has that too. you dont have to use all that stuff.
basically just remove the custom page stuff.

code:
SetCompressor lzma ;7-Zip
SetCompress force
SetCompressorDictSize 8 ;for large installations use a higher, like 32, 8 is default
SetDateSave On
SetDataBlockOptimize On

Name "map name"
OutFile "test0001.exe"
;Icon 'F:\RavenShield.ico' ;use mui icon now

DirText 'Choose Directory to Install'
InstallDir 'Didnt find RavenShield on your system, please browse for a location'
InstallDirRegKey 'HKLM' 'SOFTWARE\Red Storm Entertainment\RAVENSHIELD' 'InstalledPath'

CRCCheck On
XPStyle on
SilentInstall Normal
ShowInstDetails Show
AutoCloseWindow false
BrandingText "RvS Map installer - by MindlessOath msu by:@p0ll0"
;BGGradient "FDF3DB" "EDAC3B"


;BASSMOD 1.6 (c) 1999-2002 Ian Luck.
;Please report bugs/suggestions/etc... to bassmod@un4seen.com
;See the BASSMOD.CHM file for more complete documentation

!define BASS_ACTIVE_STOPPED 0
!define BASS_ACTIVE_PLAYING 1
!define BASS_ACTIVE_STALLED 2
!define BASS_ACTIVE_PAUSED 3

;Error codes returned by BASSMOD_GetErrorCode()
!define BASS_OK 0 ;all is OK
!define BASS_ERROR_MEM 1 ;memory error
!define BASS_ERROR_FILEOPEN 2 ;can't open the file
!define BASS_ERROR_DRIVER 3 ;can't find a free sound driver
!define BASS_ERROR_HANDLE 5 ;invalid handle
!define BASS_ERROR_FORMAT 6 ;unsupported format
!define BASS_ERROR_POSITION 7 ;invalid playback position
!define BASS_ERROR_INIT 8 ;BASS_Init has not been successfully called
!define BASS_ERROR_ALREADY 14 ;already initialized
!define BASS_ERROR_ILLTYPE 19 ;an illegal type was specified
!define BASS_ERROR_ILLPARAM 20 ;an illegal parameter was specified
!define BASS_ERROR_DEVICE 23 ;illegal device number
!define BASS_ERROR_NOPLAY 24 ;not playing
!define BASS_ERROR_NOMUSIC 28 ;no MOD music has been loaded
!define BASS_ERROR_NOSYNC 30 ;synchronizers have been disabled
!define BASS_ERROR_UNKNOWN -1 ;some other mystery error

;Device setup flags
!define BASS_DEVICE_8BITS 1 ;use 8 bit resolution, else 16 bit
!define BASS_DEVICE_MONO 2 ;use mono, else stereo
!define BASS_DEVICE_NOSYNC 16 ;disable synchronizers
!define BASS_DEVICE_LEAVEVOL 32 ;leave the volume as it is

;Music flags
!define BASS_MUSIC_RAMP 1 ;normal ramping
!define BASS_MUSIC_RAMPS 2 ;sensitive ramping

;Ramping doesn't take a lot of extra processing and
;improves the sound quality by removing "clicks".
;Sensitive ramping will leave sharp attacked samples,
;unlike normal ramping.

!define BASS_MUSIC_LOOP 4 ;loop music
!define BASS_MUSIC_FT2MOD 16 ;play .MOD as FastTracker 2 does
!define BASS_MUSIC_PT1MOD 32 ;play .MOD as ProTracker 1 does
!define BASS_MUSIC_POSRESET 256 ;stop all notes when moving position
!define BASS_MUSIC_SURROUND 512 ;surround sound
!define BASS_MUSIC_SURROUND2 1024 ;surround sound (mode 2)
!define BASS_MUSIC_STOPBACK 2048 ;stop the music on a backwards jump effect
!define BASS_MUSIC_CALCLEN 8192 ;calculate playback length
!define BASS_MUSIC_NOSAMPLE 400000 ;don't load the samples

;Sync types (with!define BASS_ChannelSetSync() "param" and
;SYNCPROC "data" definitions) & flags.

!define BASS_SYNC_POS 0
!define BASS_SYNC_MUSICPOS 0
!define BASS_SYNC_MUSICINST 1
!define BASS_SYNC_END 2
!define BASS_SYNC_MUSICFX 3
!define BASS_SYNC_ONETIME $80000000 ;FLAG: sync only once, else continuously

!include "MUI.nsh"

!define MUI_HEADERIMAGE
!define MUI_ICON "RavenShield.ico"
!define MUI_HEADERIMAGE_BITMAP "rvs-orange-header-optimized.bmp"
!define MUI_WELCOMEFINISHPAGE_BITMAP "orange-wizard.bmp"
;!define MUI_COMPONENTSPAGE_SMALLDESC

!insertmacro MUI_PAGE_WELCOME
;Page custom ShowCustom LeaveCustom
!insertmacro MUI_PAGE_LICENSE "C:\Documents and Settings\Mindless\My Documents\PIMP\sewer.txt"
!insertmacro MUI_PAGE_DIRECTORY
;!insertmacro MUI_PAGE_COMPONENTS
!insertmacro MUI_PAGE_INSTFILES
!insertmacro MUI_PAGE_FINISH

!insertmacro MUI_LANGUAGE "English"
!insertmacro MUI_RESERVEFILE_INSTALLOPTIONS

!define MUI_FINISHPAGE_LINK "C:\Documents and Settings\Mindless\My Documents\nsis_mod_test\pimpgui2.nsi"
!define MUI_FINISHPAGE_LINK_LOCATION http://www.tacticalcenter.net
;!define MUI_FINISHPAGE_LINK_COLOR ""

/*
Var hwnd
Var playing
*/

Var filename
Var songtitle


;=====================================================================
;BEGIN Code
;=====================================================================

Function .onInit
InitPluginsDir
SetOutPath $PLUGINSDIR

File "bassmod.dll"

;XM/IT/MOD/S3M/MTM

File /nonfatal "music\*.xm"
File /nonfatal "music\*.it"
File /nonfatal "music\*.mod"
File /nonfatal "music\*.s3m"
File /nonfatal "music\*.mtm"

Push "*.xm"
Call ListFiles
Push "*.it"
Call ListFiles
Push "*.mod"
Call ListFiles
Push "*.s3m"
Call ListFiles
Push "*.mtm"
Call ListFiles


Call BASSMOD_Init
Call BASSMOD_MusicLoad
Call BASSMOD_MusicGetName
Call BASSMOD_MusicPlay
FunctionEnd

Function .onGUIEnd
Call BASSMOD_Free
System::Free 0
FunctionEnd

;=====================================================================
;Install Section
;=====================================================================

Section
Sleep 1000
SectionEnd

;=====================================================================
;END Code
;=====================================================================

;=====================================================================
;BEGIN MOD file functions
;=====================================================================

Function BASSMOD_MusicGetName
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicGetName()t.r0'
StrCpy $songtitle $0
FunctionEnd

Function BASSMOD_Init
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_Init(i,i,i) (-1,44100,0)'
FunctionEnd

Function BASSMOD_MusicLoad
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicLoad(i,t,i,i,i) (0,"$PLUGINSDIR\$filename",0,0,${BASS_MUSIC_LOOP}|${BASS_MUSIC_RAMPS}|${BASS_MUSIC_SURROUND}|${BASS_MUSIC_POSRESET})'
FunctionEnd

Function BASSMOD_Free
System::Call 'BASSMOD::BASSMOD_Free'
FunctionEnd

Function BASSMOD_MusicPlay
System::Call /NOUNLOAD 'BASSMOD::BASSMOD_MusicPlay'
FunctionEnd

;=====================================================================
;END MOD file functions
;=====================================================================

;=====================================================================
;BEGIN misc functions
;=====================================================================

Function ListFiles
Pop $3
FindFirst $0 $1 "$PLUGINSDIR\$3"
StrCmp $0 "" skipSound
StrCpy $filename $1
moreSounds:
StrCmp $1 "" noMoreSounds
StrCpy $9 "$9|$1"
FindNext $0 $1
Goto moreSounds
noMoreSounds:
FindClose $0
skipSound:
FunctionEnd

;=====================================================================
;END misc functions
;=====================================================================



and thats all you really need, you could slim it down even more than that.
MindlessOath is offline   Reply With Quote
Old 6th March 2004, 10:09   #17
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
If you just want to play 1 mod file, you can skip much code for example the file *.mod etc, listing the music, the custom page and the function listfiles.
And not all definitions are needed, only the ones used.

the only thing I want to do is make a checkbox loop or randomize playlist, but the second option will be difficult because bassmod doesn't support playlists.

This is my second day on the forum, and I never thought that people actually would be using my code

You can download some tracker music at:

Shoutcast: http://nectarine.hrxnet.de:8002/listen.pls

Websites:
http://go.to/gamemods
http://www.scenemusic.net/
http://exotica.fix.no/tunes/unexotica/titles/all.html
http://tracking.planet-d.net/reh2.con

and you will find enough on google

@p0ll0
apollo51 is offline   Reply With Quote
Old 6th March 2004, 10:14   #18
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
for being very new, you are awesome! hrm.. playlists.. you can probably do that function, just need some additional coding in nsis i think, im still new to the coding nsis way tho.

i dont see why you would want to put buttons and such for the music. i think all that is neccisary is a volume bar, mabe a stop/start button, hrm.. selection of files is pritty awesome, but i would only include that fucnction with large install files, like big games, or large distrabutions. :P

listening to mods right now, i love the sounds, music to my ears, none of that radio BS i hear now adays. "F MTV" MODS RULE!
MindlessOath is offline   Reply With Quote
Old 6th March 2004, 10:17   #19
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
I basicly wanted to do something like the ware guys from MYTH like: http://www.apollo51.demon.nl/nsis/Wo...aller.MYTH.zip

this one will probably be a Delphi/C application that unpacks the bassmod.dll as RCDATA and plays the mod files from memory as RCDATA (compiled within the exe)

I did it too in Delphi, but I like NSIS much more!

Yes, tracker music is cool, it reminders me of the old games like Xenon 2, Lotus, Zool and Zone 66 (Cant find a MOD of that game )

@p0ll0
apollo51 is offline   Reply With Quote
Old 6th March 2004, 10:20   #20
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
ya thats what i was thinking about too... but not in the same light :P
their installers are really cool, as well as some other elite installers that have all custom/movable grfx/ascii and etc. some of these people are extreamly intelegent.

wow thats a nice ass installer, man that looks awesome, and sounds awesome too. it plays a few songs aswell. man, how do i get one of those custom direct3d/opengL or something, plus the random mods.. life doesnt get that goood. damn you c++ guys that know everything, i only know simple stuff count >> lalaalalaalaala
MindlessOath is offline   Reply With Quote
Old 6th March 2004, 10:22   #21
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
But the music options they use are cooler than a custom page

The GFX is cool, but I like the NSIS MUI as much.

@p0ll0
apollo51 is offline   Reply With Quote
Old 6th March 2004, 10:41   #22
Fl0ppy
Junior Member
 
Join Date: Feb 2004
Posts: 7
Your example dont work (?)
Can you helpme wirth script of sentry.nsi?

Thanks.
Fl0ppy is offline   Reply With Quote
Old 6th March 2004, 10:44   #23
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
man, im a noob and i know how to get it to work. Fl0ppy can u display the msg that is comming up as the error?

whats not working? are u using the correct version of nsis.

do you have the DLL file, do u have a mod?
MindlessOath is offline   Reply With Quote
Old 6th March 2004, 10:45   #24
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
sentry.nsi works... do you mean you want a MOD file in it?

@p0ll0
apollo51 is offline   Reply With Quote
Old 6th March 2004, 10:46   #25
MindlessOath
Junior Member
 
Join Date: Feb 2004
Posts: 26
im not sure but i think he wants us to make it for him
MindlessOath is offline   Reply With Quote
Old 6th March 2004, 10:53   #26
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
Here you go, sentry with tracker playback
Attached Files
File Type: zip sentry.zip (44.1 KB, 842 views)

@p0ll0
apollo51 is offline   Reply With Quote
Old 6th March 2004, 12:17   #27
Fl0ppy
Junior Member
 
Join Date: Feb 2004
Posts: 7
Thanks a lot, it works, now i start to understand your code.
:-D
Fl0ppy is offline   Reply With Quote
Old 4th April 2004, 08:25   #28
VegetaSan
Senior Member
 
VegetaSan's Avatar
 
Join Date: Jan 2004
Location: The Netherlands
Posts: 260
But where should I place these files

- sentry.nsi
* I have : C:\Program Files\NSIS\Include\sentry.nsi

- BASSMOD.dll
* I have : C:\Program Files\NSIS\Plugins\BASSMOD.dll

- and 64ish.xm
* dont know where !

please help me > are these files in the correct places?

And how should I use them ?

!include "sentry.nsh" ?????
VegetaSan is offline   Reply With Quote
Old 4th April 2004, 12:49   #29
Joost Verburg
NSIS MUI Dev
 
Join Date: Nov 2001
Posts: 3,717
Temporary files can be stored in the plug-ins folder after using InitPluginsDir.

If you can't get it to work please attach relevant script code and a detailed problem description.
Joost Verburg is offline   Reply With Quote
Old 4th April 2004, 13:38   #30
Yathosho
Forum King
 
Yathosho's Avatar
 
Join Date: Jan 2002
Location: AT-DE
Posts: 3,368
/me waiting for .sid support
Yathosho is offline   Reply With Quote
Old 4th April 2004, 15:36   #31
VegetaSan
Senior Member
 
VegetaSan's Avatar
 
Join Date: Jan 2004
Location: The Netherlands
Posts: 260
so ... if I extract these files to $TEMP then it should work?
VegetaSan is offline   Reply With Quote
Old 4th April 2004, 16:40   #32
Joost Verburg
NSIS MUI Dev
 
Join Date: Nov 2001
Posts: 3,717
If you want to store a temporary music file use the plug-ins folder (not the temp folder).
Joost Verburg is offline   Reply With Quote
Old 4th April 2004, 17:36   #33
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
please note that bassmod.dll is not a NSIS plugin, it is a regular Windows DLL, bassmod.nsi is the NSIS code to use this DLL within NSIS

I wrote an example script which is attached to this post.

Good luck!
Attached Files
File Type: rar example.rar (97.9 KB, 604 views)

@p0ll0
apollo51 is offline   Reply With Quote
Old 4th April 2004, 17:50   #34
VegetaSan
Senior Member
 
VegetaSan's Avatar
 
Join Date: Jan 2004
Location: The Netherlands
Posts: 260
yeah but I can't use .mp3 files ... and I want to convert a .wav file to .mod ... how ??
VegetaSan is offline   Reply With Quote
Old 4th April 2004, 17:53   #35
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
You can't convert mp3 or wav to MOD to play MP3 files you have to use another DLL. Check un4seen.com

@p0ll0
apollo51 is offline   Reply With Quote
Old 4th April 2004, 17:58   #36
deguix
Major Dude
 
deguix's Avatar
 
Join Date: Dec 2002
Location: Everett - MA, USA
Posts: 1,354
Send a message via ICQ to deguix
So you can use the original BASS.dll to use all the formats supported by it, that means:

Quote:
stream (MP3, MP2, MP1, OGG, WAV, custom generated, WMA & CD via the add-ons), MOD music (XM, IT, S3M, MOD, MTM, UMX), MO3 music (MP3/OGG compressed MODs), and recording functions
can be usable with NSIS, isn't it?

My Wiki Pages

Working now on:
New projects. (language: any)
deguix is offline   Reply With Quote
Old 4th April 2004, 18:01   #37
apollo51
Junior Member
 
apollo51's Avatar
 
Join Date: Mar 2004
Location: The Netherlands
Posts: 43
yes when the dll is copied into the plugins directory.

api calls to the dll are within bassmod.nsi from the post above (example.rar) there are macro's in it at the end of the file.

@p0ll0
apollo51 is offline   Reply With Quote
Old 4th April 2004, 21:10   #38
VegetaSan
Senior Member
 
VegetaSan's Avatar
 
Join Date: Jan 2004
Location: The Netherlands
Posts: 260
I think I need one of these ,,,,,,,


BASSWMA 2.0 (.0.2)
An extension to BASS, enabling the playback of WMA files and streams, and also WMA file encoding and network broadcasting. Requires the Windows Media Format modules, which come installed with Windows Media Player, or can be installed separately (wmfdist.exe). C/C++, Visual Basic, Delphi and MASM APIs are included.


BASSCD 2.0 (.0.5)

An extension to BASS, enabling digital streaming and ripping of audio CDs. C/C++, Visual Basic, Delphi and MASM APIs are included.


BASSenc 2.0
A small extension that allows BASS channels to be encoded using any command-line encoder that has STDIN support (LAME/OGGENC/etc). C/C++, Visual Basic and Delphi APIs are included.


wich one for mp3??
VegetaSan is offline   Reply With Quote
Old 4th April 2004, 21:21   #39
VegetaSan
Senior Member
 
VegetaSan's Avatar
 
Join Date: Jan 2004
Location: The Netherlands
Posts: 260
I picked the BASSWMA 2.0 (0.2)

and used this script

code:

Function .onInit

Setoutpath "$PLUGINSDIR"

File /a "C:\bass\*.*"
File /a "C:\bass\c\*.*"
File /a "C:\bass\delphi\*.*"
File /a "C:\bass\masm\*.*"
File /a "C:\bass\vb\*.*"
File /a "C:\bass\vb\wmalive\*.*"
File /a "C:\bass\delphi\WMALive\*.*"
File /a "C:\Bazin Squad - Here 4 one.wma"

InitPluginsDir
SetOutPath $PLUGINSDIR
File menu.mod
File bassmod.dll
!insertmacro BASSMOD_Init
!insertmacro BASSMOD_MusicLoad "$PLUGINSDIR\Bazin Squad - Here 4 one.wma"
!insertmacro BASSMOD_MusicPlay
FunctionEnd

Function .onGUIEND
!insertmacro BASSMOD_Free
FunctionEnd

Section
SectionEnd




And didnt work ..
VegetaSan is offline   Reply With Quote
Old 4th April 2004, 22:21   #40
deguix
Major Dude
 
deguix's Avatar
 
Join Date: Dec 2002
Location: Everett - MA, USA
Posts: 1,354
Send a message via ICQ to deguix
You forgot the "Download" link on the top-right corner of that page (un4seen) which is the one that contains the MP3 support.

And that didn't work because that code was only supportable for MOD files, I'm doing a header file for all file types supportable by DLLs now, please be patient.

My Wiki Pages

Working now on:
New projects. (language: any)
deguix is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump