2007-12-14, 03:33 PM
I had been using a script originally posted here by reboot using videoredo to automatically edit my recordings to cut the commercials. I could not get the cscript part to run on my Vista machine, when called from postprocessing.bat, no matter what I tried. Probably something to do with users or permissions. :confused:
I finally gave up and came up with another method which I am actually liking better. It isn't automatic, in that it requires some action from me on each recording, but it is very simple to do and since all the recordings are made by my regular desktop pc it fits into my normal morning work routine.
After each recording finishes postprocessing.bat runs comskip and then creates a shortcut to the recording in a designated folder on my desktop. Clicking on the shortcut opens videoredo showing the proposed cuts. I can either accept the cuts as they are or edit any of the cuts easily at this point. I do this with all the files in the folder. Next I click on another shortcut on the desktop which calls the batch files needed to process the recording. This whole process takes only a couple minutes and requires no interaction from me once the recordings are edited.
I use a little utility called shortcut.exe from here to create the link on my desktop. I downloaded this and unzipped it to a folder called shortcut in the third party folder of gbpvr.
My postprocessing.bat now looks like this:
REM If you use Showanalyzer, unREM the next line
REM "C:\Program Files\Dragon Global\ShowAnalyzer\ShowAnalyzer.exe" %1
REM If you use comskip, unREM the next line
"C:\Program Files\devnz\gbpvr\comskip.exe" %1
"C:\Program Files\devnz\gbpvr\Third Party\Shortcut\shortcut.exe" /F:"C:\Users\Doug\Desktop\New.Videos\%~n1.lnk" /A:C /T:"%~dpn1.vprj"
I also have 2 batch files in a folder called SemiAutoBat in the third party folder of gbpvr.
do_post_proc.bat
REM This will recursively step through the Videos directory and find each vprj file created by postprocessing.bat.
REM Then call a script to process those files.
FOR /R C:\Users\Public\Videos\ %%f IN (*.vprj) DO postpostprocessing.bat "%%f"
Note: My default recordings directory in GBpvr is C:\Users\Public\Videos\
postpostprocessing.bat
Rem This script runs Videoredo to edit the recording using the .vprj project file.
cscript //nologo "C:\Program Files\VideoReDoTVSuite\vp.vbs" "%~dpn1.VPrj" "%~dpn1_cleaned.mpg" /t1 /q
Rem RENAME the old .mpg file to name_original.mpg
move "%~dpn1.mpg" "%~dpn1_original.mpg"
REM Rename the cleaned file to the name of the original recording.
move "%~dpn1_cleaned.mpg" "%~dpn1.mpg"
REM These previous two lines don't do anything if the original file is in dvr-ms format.
REM The following lines cleanup the directory.
move "%~dpn1.dvr-ms" "C:\Users\Public\Recorded TV\ORIGINALS"
move "%~dpn1_original.mpg" "C:\Users\Public\Recorded TV\ORIGINALS"
REM Delete Comskip's working files.
del "%~dpn1.txt"
del "%~dpn1.log"
del "%~dpn1.logo.txt"
REM Save the VideoReDo file with the original to make a re-edit easier
move "%~dpn1.VPrj" "C:\Users\Public\Recorded TV\ORIGINALS"
REM Delete the shortcut in the New.Videos folder.
del "C:\Users\Doug\Desktop\New.Videos\%~n1.lnk"
REM Rename the recording using zrename.
"C:\Program Files\devnz\gbpvr\Third Party\ZRename.exe" "%~dpn1.mpg"
I created a folder on my desktop called New.Videos where the shortcuts are stored and a shortcut to the file âdo_post_proc.batâ which I renamed to Cut Commercials. I changed my desktop properties to display âMedium Iconsâ. This changes the folder's image to show me when it contains a new recording shortcut. Also be sure to set the line in comskip.ini to: output_videoredo=1
Newly recorded video ready for editing.
I finally gave up and came up with another method which I am actually liking better. It isn't automatic, in that it requires some action from me on each recording, but it is very simple to do and since all the recordings are made by my regular desktop pc it fits into my normal morning work routine.
After each recording finishes postprocessing.bat runs comskip and then creates a shortcut to the recording in a designated folder on my desktop. Clicking on the shortcut opens videoredo showing the proposed cuts. I can either accept the cuts as they are or edit any of the cuts easily at this point. I do this with all the files in the folder. Next I click on another shortcut on the desktop which calls the batch files needed to process the recording. This whole process takes only a couple minutes and requires no interaction from me once the recordings are edited.
I use a little utility called shortcut.exe from here to create the link on my desktop. I downloaded this and unzipped it to a folder called shortcut in the third party folder of gbpvr.
My postprocessing.bat now looks like this:
REM If you use Showanalyzer, unREM the next line
REM "C:\Program Files\Dragon Global\ShowAnalyzer\ShowAnalyzer.exe" %1
REM If you use comskip, unREM the next line
"C:\Program Files\devnz\gbpvr\comskip.exe" %1
"C:\Program Files\devnz\gbpvr\Third Party\Shortcut\shortcut.exe" /F:"C:\Users\Doug\Desktop\New.Videos\%~n1.lnk" /A:C /T:"%~dpn1.vprj"
I also have 2 batch files in a folder called SemiAutoBat in the third party folder of gbpvr.
do_post_proc.bat
REM This will recursively step through the Videos directory and find each vprj file created by postprocessing.bat.
REM Then call a script to process those files.
FOR /R C:\Users\Public\Videos\ %%f IN (*.vprj) DO postpostprocessing.bat "%%f"
Note: My default recordings directory in GBpvr is C:\Users\Public\Videos\
postpostprocessing.bat
Rem This script runs Videoredo to edit the recording using the .vprj project file.
cscript //nologo "C:\Program Files\VideoReDoTVSuite\vp.vbs" "%~dpn1.VPrj" "%~dpn1_cleaned.mpg" /t1 /q
Rem RENAME the old .mpg file to name_original.mpg
move "%~dpn1.mpg" "%~dpn1_original.mpg"
REM Rename the cleaned file to the name of the original recording.
move "%~dpn1_cleaned.mpg" "%~dpn1.mpg"
REM These previous two lines don't do anything if the original file is in dvr-ms format.
REM The following lines cleanup the directory.
move "%~dpn1.dvr-ms" "C:\Users\Public\Recorded TV\ORIGINALS"
move "%~dpn1_original.mpg" "C:\Users\Public\Recorded TV\ORIGINALS"
REM Delete Comskip's working files.
del "%~dpn1.txt"
del "%~dpn1.log"
del "%~dpn1.logo.txt"
REM Save the VideoReDo file with the original to make a re-edit easier
move "%~dpn1.VPrj" "C:\Users\Public\Recorded TV\ORIGINALS"
REM Delete the shortcut in the New.Videos folder.
del "C:\Users\Doug\Desktop\New.Videos\%~n1.lnk"
REM Rename the recording using zrename.
"C:\Program Files\devnz\gbpvr\Third Party\ZRename.exe" "%~dpn1.mpg"
I created a folder on my desktop called New.Videos where the shortcuts are stored and a shortcut to the file âdo_post_proc.batâ which I renamed to Cut Commercials. I changed my desktop properties to display âMedium Iconsâ. This changes the folder's image to show me when it contains a new recording shortcut. Also be sure to set the line in comskip.ini to: output_videoredo=1
Newly recorded video ready for editing.
Server: Windows 10 - ASrock N3150DC -ITX Fanless Celeron
Clients: Shield TV with X-newa on Kodi, Asus chromebox - openelec - X-newa on Kodi
Clients: Shield TV with X-newa on Kodi, Asus chromebox - openelec - X-newa on Kodi