- API -
dofile(reaper.AZ_GetLuaInitPath())
require("reaper_AZSTOKE_SILVER")
retval,inputList = reaper.AZ_GetUserInputList("AZWavList",1,"Path :","D:\\")
fileList = reaper.AZ_GetFilePathList(inputList[1],"wav")
startPos = 0
for i, value in pairs(fileList) do
reaper.AZ_SetPlayCursorPosition(0,0,startPos)
item = reaper.AZ_InsertMediaOutItem(0,value)
endPos = reaper.AZ_GetMediaItemEndTime(item)
startPos = endPos + 1
end
- API Detail-
Prepare a wav file in the specified folder
- SCRIPT -
dofile(reaper.AZ_GetLuaInitPath())
require("reaper_AZSTOKE_SILVER")
・Enable use of SilverAPI
retval,inputList = reaper.AZ_GetUserInputList("AZWavList",1,"Path :","D:\\")
- Display SimpleUI and assign input values to inputList
fileList = reaper.AZ_GetFilePathList(inputList[1],"wav")
- Get the full path of the file from the path information and assign it to an array
startPos = 0
・Assign 0 as the initial value of startPos
for i, value in pairs(fileList) do
・Play the number of files in the fileList in a For loop
reaper.AZ_SetPlayCursorPosition(0,0,startPos)
・Move the cursor to the startPos position
item = reaper.AZ_InsertMediaOutItem(0,value)
・Insert media, output mediaItem and assign it to item
endPos = reaper.AZ_GetMediaItemEndTime(item)
-Get the end point of the media item and assign it to endPos
startPos = endPos + 1
・Set the starting point one second after endPos to startPos
end