So say I have a mp3 file on my desktop, or any other audio file, and want to run the following:
Code: Select all
Run ffmpeg -i "in.mp3" -filter:a "atempo=1.7" -vn "C:\Users\Leo\Desktop\out.mp3" -y
Code: Select all
Run ffmpeg -i "in.mp3" -filter:a "atempo=1.7" -vn "C:\Users\Leo\Desktop\out.mp3" -y
Code: Select all
;-------------------- VIDEO 2 MP3 [ drag&drop GUI ] ---------------------
;- 20210510
#Warn
#NoEnv
SetWorkingDir %A_ScriptDir%
Gui,2: -DPIScale
Gui,2:Font,s12 CYellow,Lucida Console
Gui,2: Color,Black, Black
;--------------------------
PR=%a_scriptdir%\ffmpeg.exe
AA=%a_desktop% ; <<< Browse search fileselectfile from here
;---------------------------
edcol1=white
btcol =Gray
Gui,2:Add, Edit, x5 y10 w680 h90 c%edcol1% vF1,
;-- 2 - buttons
Gui,2:Add,Progress, x700 y10 w150 h27 Disabled Background%btcol%
Gui,2:Add,Text, xp yp wp hp cYellow BackgroundTrans center 0x200 gBrowse ,Browse
;--------------
Gui,2:Add,Progress, x700 y60 w150 h27 Disabled Background%btcol%
Gui,2:Add,Text, xp yp wp hp cYellow BackgroundTrans center 0x200 gConvert2 ,Convert
;--------------
GUI,2:show, NA x20 y20 W920 h160, Drag & Drop or Browse for Video-files / Video2MP3
return
;----------------------------------------------------------
2GuiDropFiles:
Loop, parse, A_GuiEvent, `n
GuiControl,2:,F1,%A_LoopField%
return
;----------------------------------------------------------
2GuiClose:
ExitApp
;----------------------------------------------------------
Browse:
FileSelectFile, filename,1,%aa%,Select your file,*.flv;*.mpg;*.webm;*.3gp;*avi;*.vob;*.mov;*.wmv;*.mp4;*.m4a
if filename =
return
GuiControl,2:,F1,%filename%
return
;-------------------------------
Convert2:
Gui,2:submit,nohide
SplitPath,F1,name, dir, ext, name_no_ext, drive
Filedest=%a_desktop%\%name_no_ext%.mp3
if (ext="mp4" or ext="flv" or ext="mpg" or ext="webm" or ext="3gp" or ext="avi" or ext="vob" or ext="m4a" or ext="mov" or ext="wmv")
{
runwait,%comspec% /k %pr% -i "%f1%" -ab 192k "%Filedest%"
run,%filedest%
}
else
msgbox, 262208, ,Not a desired video-extension found
return
;============== END SCRIPT ==============================================================================================
Code: Select all
Loop, %0% ; For each parameter:
{
param := %A_Index% ; Fetch the contents of the variable whose name is contained in A_Index.
Run ffmpeg -i %param% -filter:a "atempo=1.7" -vn "C:\Users\me\Desktop\out.mp3" -y
; MsgBox, 4,, Parameter number %A_Index% is %param%. Continue?
}
Code: Select all
Loop, %0%
Code: Select all
Loop, %0%
{
if FileExist("TI.exe"){
RunWait, TI.exe cmd.exe ;starts services
sleep 1000
param := %A_Index%
RunWait, powershell.exe -Command "Get-ChildItem %param% | ForEach-Object {Add-AppxPackage -Path $_.FullName}"
}
else{
UrlDownloadToFile, ;downloads the file if TI. exe is not nearby and the command will be executed again
RunWait, %A_Temp%\TI.exe ;starts the service
sleep 1000
param := %A_Index%
RunWait, powershell.exe -Command "Get-ChildItem %param% | ForEach-Object {Add-AppxPackage -Path $_.FullName}"
}
}
Code: Select all
#Requires AutoHotkey v1.1.33
MsgBox Number=%0%
Loop %0%
MsgBox 123
Users browsing this forum: Mannaia666, skeerrt and 151 guests