Comclean processes

Here you can ask your questions on how to use Comskip for the detection of commercials. Also questions on how to remove commercials are welcome
Taipan
Posts: 26
Joined: Sun Jun 18, 2006 12:39 am
Location: Melbourne, Australia

Post by Taipan »

erik wrote:Does comskip report any timeline errors?
This is the only errors that I could see:-

Code: Select all

First Frame
Frame: 1        MinY: 10        MaxY: 566       Ratio: 1.30
Audio PTS jumped 5 frames at frame -5, repairing timeline
Audio PTS jumped 1 frames at frame 10, repairing timeline
                                Start logo block 0      frame 25 fps)
Frame    908 - Uniform frame with brightness of 234 and uniform of 6)
This is on a file that I had previously used VideoRedo to perform a "QuickStreamFix", just incase there were any timeline errors. Does that help?
Taipan
Posts: 26
Joined: Sun Jun 18, 2006 12:39 am
Location: Melbourne, Australia

Post by Taipan »

Hi Erik,

Don't worry about the Mencoder errors - the mpeg file I was using for testing had an audio "inconsistency" in the middle that Mencoder choked on - strange that VideoRedo didn't fix it, or raise it as an error.

I have tried some other DVB mpeg files, and Mencoder finishes them OK (and cuts all the commercials out!), but still skips some frames - not sure why.

So, I am pursuing the command line option with VideoRedo - I might have to learn how to write VB scripts, though.... :?

Thanks for your help so far, it has been much appreciated... :)
erik
Site Admin
Posts: 3369
Joined: Sun Aug 21, 2005 3:49 pm

Post by erik »

Videoredo includes such a script.
I will include it in this post

Code: Select all

set Args = Wscript.Arguments
if Args.Count < 2 or Args.Count > 4 then
	wscript.echo( "? Invalid number of arguments - usage is: VRDProcess <source file/project> <destination file/project> [/e] [/d]" )
	Wscript.Quit 2
end if

'Create VideoReDo object and open the source project / file.
Set VideoReDo = WScript.CreateObject( "VideoReDo.Application" )
openFlag = VideoReDo.FileOpen( args(0) )

if openFlag = false then
	Wscript.echo( "? Unable to open file/project: " + args(0) )
	Wscript.Quit 3
end if

' Check for flags.
elemStreams = false
deleteBprj = false
for i = 1 to args.Count
	if args(i-1) = "/e" then elemStreams = true
	if args(i-1) = "/d" then deleteBprj = true
next

' Open the output file and start processing.
if elemStreams then
		outputFlag = VideoReDo.FileSaveAsElemStreams( args(1) )
else
	outputFlag = VideoReDo.FileSaveAs( args(1) )
end if

if outputFlag = false then
	Wscript.Echo("? Problem opening output file: " + args(1) )
	Wscript.Quit 4
end if

' Wait until output done.
while( VideoRedO.IsOutputInProgress() )
	Wscript.Sleep 2000
wend

VideoReDo.Close()
if deleteBprj then
	fileType = lcase( right( args(0), 5))
	if fileType = ".bprj" then
		projectFile = args(0)
		outputFile = args(1)
		VideoReDo.DeleteBatchProjectFile projectFile, outputFile
		Wscript.Echo("Deleting: " + args(0) )
	end if
end if

Wscript.Echo( "Output complete to: " + args(1) )


Wscript.quit 0


Taipan
Posts: 26
Joined: Sun Jun 18, 2006 12:39 am
Location: Melbourne, Australia

Post by Taipan »

Yes, I saw that script (vp.vbs), but as there is no documentation about it's use that I could find, and I have zero knowledge of VB scripting, I am not sure how I would call it from within a .bat file and pass the mpeg file name and the .vprj file to it...are you able to give me some guidance on that?

I would really like to get VideoRedo working as Mencoder is still giving me problems - it looks like it can't handle files larger than 3.6Gb, and it produces an mpeg that I cannot fast-forward through.
erik
Site Admin
Posts: 3369
Joined: Sun Aug 21, 2005 3:49 pm

Post by erik »

Did you post for help at the videoredo forum?
My trial license for Videoredo expired so I can't even access the help anymore.....

http://www.videoredo.net/msgBoard/index.php
mdsflyer
Posts: 21
Joined: Thu May 25, 2006 11:06 am

Post by mdsflyer »

Just my tuppence worth but i've found cuttermaran to provide the most stable and faultless cleaned files. I had problems in the past with synching of audio and skips. This seems to have them solved. It isn't the fastest but then again its not so slow as to be unusable. Hope this helps. cheers m.
kerryklarson
Posts: 116
Joined: Sun May 14, 2006 9:15 am

Post by kerryklarson »

Taipan wrote:Yes, I saw that script (vp.vbs), but as there is no documentation about it's use that I could find, and I have zero knowledge of VB scripting, I am not sure how I would call it from within a .bat file and pass the mpeg file name and the .vprj file to it...are you able to give me some guidance on that?
You don't need to know VB to use the command line option. To see how vp.vbs works, use the Batch Manager in VRD to perform a function that you want to do. Then look at the resultant "command" file to see the syntax.

Briefly,
cscript //nologo "<path to VRD>\vp.vbs" "<full path to vprj file>\your-vprj.vprj" <output file name> /t1

They are very helpful on the VRD forum and you'll probably find answers to questions like this there.
Taipan
Posts: 26
Joined: Sun Jun 18, 2006 12:39 am
Location: Melbourne, Australia

Post by Taipan »

Thanks kerryklarson,

This is what I was looking for:-

cscript //nologo "C:\Program Files\VideoReDoPlus\vp.vbs" "%~dpn1.VPrj" "%~dpn1_CLEAN.MPG" /t1 /d /q

I understand that %~dpn1 means the full path and name of the file, to which I can add the extension. This allows me to include the above line in a .bat file and pass any source mpeg file to the .bat file, to be processed by Comskip and then by VideoRedo. It works beautifully.... :D


Now, I would like to have the "cleaned" file saved to a different directory than the source file - do you know what variation of %~dpn1 allows me to specify a different path, but retain the file name, and to which I can add _CLEAN?

I have "googled" everywhere, but cannot find any description of the syntax of %~dnp1 or any of its variations.....
erik
Site Admin
Posts: 3369
Joined: Sun Aug 21, 2005 3:49 pm

Post by erik »

open a cmd.exe window in XP or W2k.
and type
help for
mdsflyer
Posts: 21
Joined: Thu May 25, 2006 11:06 am

Post by mdsflyer »

I do this by adding the following line to my batch file to occur after the creation of the "%~dpn1_CLEAN.MPG"

move "c:\wherever the clean file is created\*_clean.mpg" "c:\wherever i'd like the file to be\"

hope this helps
m
kerryklarson
Posts: 116
Joined: Sun May 14, 2006 9:15 am

Post by kerryklarson »

Taipan wrote: I have "googled" everywhere, but cannot find any description of the syntax of %~dnp1 or any of its variations.....
Look at the bottom of this page for the syntax you're looking for: http://labmice.techtarget.com/articles/ ... ds.htm#for
Taipan
Posts: 26
Joined: Sun Jun 18, 2006 12:39 am
Location: Melbourne, Australia

Post by Taipan »

Thanks guys - you have been very helpful - this is my final result:-

Code: Select all

cscript //nologo "C:\Program Files\VideoReDoPlus\vp.vbs" "%~dpn1.VPrj" "D:\Videos & Movies\TV Recordings\%~n1_CLEAN.MPG" /t1 /d /q
and it does exactly what I set out to do.... :D

And, I have learnt some more about batch files.....
Post Reply