BrettF
MVPs-
Posts
7,400 -
Joined
-
Last visited
-
Days Won
1
BrettF last won the day on April 27 2013
BrettF had the most liked content!
About BrettF
- Birthday 04/06/1992
Profile Information
-
Member Title
My Drunk Monkey Guerilla is gonna getcha!
-
Location
Brisbane, Australia
-
WWW
http://www.signa5.com
Recent Profile Visitors
3,898 profile views
BrettF's Achievements
Universalist (7/7)
30
Reputation
-
simplercoder000 reacted to a post in a topic: MultiLang.au3
-
AGlassman reacted to a post in a topic: How get file extension?
-
atetester132 reacted to a post in a topic: Get Text From Message Box
-
Privacy reacted to a post in a topic: how to assign 'a' to 'z' to an array
-
Xandy reacted to a post in a topic: Frequently Asked Questions (FAQs)
-
behdadsoft reacted to a post in a topic: How do I delete a Treeview child?
-
Xandy reacted to a post in a topic: BASS Function Library (Sound and Music Functions)
-
Skysnake reacted to a post in a topic: MultiLang.au3
-
mLipok reacted to a post in a topic: Learning To Script with AutoIt V3
-
ssamko reacted to a post in a topic: MultiLang.au3
-
BASS Function Library (Sound and Music Functions)
BrettF replied to BrettF's topic in AutoIt Example Scripts
_BASS_CD_GetInfo($drive) should return an array and I assume you are going and retrieving the 4 element in the array successfuly. You should be able to do something like... If BitAnd ($RetturnValue[4], $flag) <> 0 Then ... or something similar. I'll try find my example for recording. I think eukalyptus might have one too? I'll ask him for you and if I can't find one, then I'll make one. Cheers, Brett -
Learning To Script with AutoIt V3
BrettF replied to BrettF's topic in AutoIt General Help and Support
Hi there! Late reply because my work is insane. Christmas time is busy for retail... I just downloaded the release zip on 3 different computers running different OSs. My testing steps: File initially downloaded. It was a .zip. Fine. Extracted .zip. Fine. Opened main .PDF. Fine. Opened Exercise PDF. Fine. So no problems here...? What OS? Merry Christmas! (Well where I am it is...) Cheers, Brett -
Learning To Script with AutoIt V3
BrettF replied to BrettF's topic in AutoIt General Help and Support
Hi wangnjj, Apologies for my late reply, I have been very busy as of late. I see I made a few slip ups there. Noted in my copy, and will release when I have the time. Cheers! Brett -
Learning To Script with AutoIt V3
BrettF replied to BrettF's topic in AutoIt General Help and Support
Oh wow... Almost hit 20250... I meant to give a cookie to the lucky 20,000... -
Try this: #Include <WinAPI.au3> #include <Bass.au3> #include <BassSFX.au3> #include <BassConstants.au3> #include <BassSFXConstants.au3> ;Vizualization to use $viz = "LightMagick.uvs" ;MP3 to use $file = "example.mp3" ;Update period $update = 20;ms ;Create the GUI $Form1 = GUICreate("Form1", 800, 600) ;Startup Bass.dll and BassSDX.dll _BASS_SFX_Startup (@ScriptDir & "\Bass_SFX.dll") _Bass_Startup (@ScriptDir & "\Bass.dll") ;Initialize both libraries _BASS_SFX_Init($Form1) _BASS_Init(0, -1, 44100, 0, "") ;Load MP3 File $MusicHandle = _BASS_StreamCreateFile(False, $file, 0, 0, 0) ;Create a picture to use as the visualization holder $picutre_viz = GUICtrlCreatePic(@ScriptDir & "\music_icon.jpg", 0, 0, 800, 600) ;Get the HNDL $VISUAL_WIN_HANDLE = GUICtrlGetHandle($picutre_viz) ;Create the plugin $VISUAL_HANDLE = _BASS_SFX_PluginCreate(@ScriptDir & "\" & $viz, $VISUAL_WIN_HANDLE, 800, 600, 0) ;Show GUI GUISetState(@SW_SHOW) ;Start playing audio _BASS_ChannelPlay($MusicHandle, 1) ;Start the plugin _BASS_SFX_PluginStart($VISUAL_HANDLE) $timer = TimerInit () While 1 $Msg = GUIGetMsg() ;Render the visualization If TimerDiff ($timer) >= $update Then _BASS_SFX_PluginRender($VISUAL_HANDLE, $MusicHandle, _WinAPI_GetWindowDC($VISUAL_WIN_HANDLE)) $timer = TimerInit () EndIf Switch $Msg Case -3 _Bass_Stop() _BASS_SFX_PluginStop($VISUAL_HANDLE) _BASS_SFX_PluginFree($VISUAL_HANDLE) _BASS_Free() Exit EndSwitch WEnd You will need to update BassLib to the latest version (as found in my sig). You need to update the visualization in a loop (with a timer) like shown. Also you need to use the Bass functions for music- SoundPlay does not interface in any way with BassLib. Cheers, Brett
-
Newb needs help recursing so he will stop cursing.
BrettF replied to EBJoe's topic in AutoIt General Help and Support
It can do most things, you just don't know how to make it do what you want it to... -
No idea if I have the latest copy, but here is one I have from 2008... BASSMOD.au3 Download BassMod.dll from un4seen. If you have any more problems give us a yell and I'll fix it up, or BassLib will do the same thing in the end... Cheers, Brett
-
Suggestion noted... Will update to make it valid and add a few little extras with the next version. Could you just upload the edited XML file please? What you've pasted doesn't display correctly in Firefox... Thanks, Brett
-
BASS Function Library (Sound and Music Functions)
BrettF replied to BrettF's topic in AutoIt Example Scripts
Under beta until the help file is finished... That's going to take a while! -
You can find the UDF here. This should work. Untested. #include <iTunes.au3> #Include <Date.au3> $PlayList_Name = "Hip-Hop" $nTimeout = 30*1000 ; 30 seconds $nTimeout = 2*1000 ; 2 seconds $sLoaded = "" ;Start the object _iTunes_Start() ;Play the first song in the playlist _iTunes_Playlist_PlayFirst($PlayList_Name) $sLoaded = _GetSongNameID() ;Start the timer $timer = TimerInit () OnAutoItExitRegister ("iTunesExit") While 1 ;Check to see if the loaded song is the same. If Not Reset the timer. $sNow = _GetSongNameID () If $sLoaded <> $sNow Then ;So we don't reset the timer again $sLoaded = $sNow ;Reset the timer $timer = TimerInit () EndIf ;See if the elapsed is greater than the timeout If TimerDiff ($timer) >= $nTimeout Then ;Play the next song. _iTunes_Next() Else ;Conserve CPU Sleep(500) EndIf WEnd Func iTunesExit() _iTunes_Unload() EndFunc Func _GetSongNameID () $aInfo = _iTunes_Current_GetInfo() Return $aInfo[2] EndFunc
-
Well you could create your playlist and make each of the songs only play for 30 seconds... RightClick -> Get Info on the particular song. Cheers, Brett
-
Fatalcoder, if you can't accurately describe what your problem is, we can't help. No one here is mind readers. I mean we've done pretty well so far to working out what you want, but if you can't tell us what your final outcome is, we can't help you achieve that. Next time you post I do expect a better explaination of what you want help with. That does mean typing it all out (using google translate if you need to ), showing any examples of code, files. Basically so we can replicate what you need. #include <GuiConstantsEx.au3> #include <GuiListView.au3> Global $hListView If FileExists("botlist.txt") Then GUICreate("ListView Add Item", 400, 300) $hListView = GUICtrlCreateListView("", 50, 15, 300, 270) _GUICtrlListView_SetUnicodeFormat($hListView, False) _GUICtrlListView_InsertColumn($hListView, 0, "User ID", 145) _GUICtrlListView_InsertColumn($hListView, 1, "Password", 145) loadbots() GUISetState() $msg = GUIGetMsg() While $msg <> $GUI_EVENT_CLOSE $msg = GUIGetMsg() WEnd Else MsgBox(0, "ERROR!", "File Not Found") EndIf Func loadbots() $delim = Opt("GUIDataSeparatorChar", ":") $sFile = FileRead("botlist.txt") $aList = StringSplit($sFile, @CRLF, 1) For $iX = 1 To $aList[0] If StringInStr($aList[$iX], ":") Then GUICtrlCreateListViewItem($aList[$iX], $hListView) EndIf Next Opt("GUIDataSeparatorChar", $delim) EndFunc ;==>loadbots Cheers, Brett