top of page
- Script Code -

dofile(reaper.AZ_GetLuaInitPath()) 

require("reaper_AZSTOKE_BRONZE")

require("reaper_AZSTOKE_GOLD") 


url = "p4v URL"           

userName = "p4vユーザー名"

password = "p4vパスワード"


workspace = "p4vワークスペース名"

depotPath = "p4vフォルダパス"


setTime = 0


if reaper.AZ_P4_Connect(url, userName, password)  then

  

    fileList = reaper.AZ_P4_ExportAudioToProject(workspace, depotPath, "",  -1, "wav", true)

    

    for i, value in pairs(fileList) do

        item = reaper.AZ_InsertMediaTrackIdSecond(0,1,value,0,setTime)

        endTime = reaper.AZ_GetMediaItemEndTime(item)

        setTime = endTime + 1

    end

    

    reaper.AZ_P4_Disconnect()

end

- Warm Up -

  • Prepare two tracks in advance

- Script Detail -

dofile(reaper.AZ_GetLuaInitPath()) 

require("reaper_AZSTOKE_BRONZE")

require("reaper_AZSTOKE_GOLD") 


・Handle enabling the API


url = "p4vホストのURL"           

userName = "p4vユーザー名"

password = "p4vパスワード"


workspace = "p4vワークスペース名"

depotPath = "p4v取得したい先のパス情報"


・Prepare the required info


setTime = 0


・Prepare the waveform start-set timing


if reaper.AZ_P4_Connect(url, userName, password)  then


・Connect to Perforce

  

    fileList = reaper.AZ_P4_ExportAudioToProject(workspace, depotPath, "",  -1, "wav", true)


・Copy the latest-revision files into the project and output the full-path info

   

    for i, value in pairs(fileList) do


・For loop over the full-path info


        item = reaper.AZ_InsertMediaTrackIdSecond(0,1,value,0,setTime)


・Handle media insertion


        endTime = reaper.AZ_GetMediaItemEndTime(item)


・Get the end time of the placed media


        setTime = endTime + 1


・Set the start position of the next media

    end

    

    reaper.AZ_P4_Disconnect()


・Disconnect P4V


end

- API LINK -

AZ_P4_Connect

AZ_P4_ExportAudioToProject

AZ_InsertMediaTrackIdSecond

AZ_GetMediaItemEndTime

AZ_P4_Disconnect

- API LINK -

Perforce

AZSTOKE_Perforce_latest_Insert_1

Automate retrieving from a specified folder at the latest revision and inserting

01_BRONZE_ss_edited.png
01_SILVER_edited_edited.png
03_GOLD_edited_edited.png
bottom of page