Logo Cutter is intended for users of TV-recording
applications like GB-PVR or
SageTV. It is able to cut
mpeg files according to picture given as a still image.
Usually when you have scheduled recording, the show will
not start exactly on time, so you have to skip a couple of minutes when you view
Logo Cutter is able to do it automatically for you!
All you need is a show logo picture. Many TV-series have
some kind of logo that is displayed right in the beginning. Given such logo as a
still image, Logo Cutter will search for it in the recorded show, and once it is
found, cut the show from the beginning up to the logo frame.
Logo Cutter consists of two main components:
- FindFrame Avisynth plugin, that is able to search for
a frame given as a still image.
- logoCutter.vbs VBScript, which can execute FindFrame
and cut the video accordingly. It should be configured as a post processing
tool in TV recording application.
- Download and install:
- Open logoCutter.vbs in text editor. You will see at
'DGMPGDec directory (should contain dgindex.exe and dgdecode.dll)
Const DGMPGDEC_DIR = "c:\Program Files\dgindex"
Const AVS_PLAYER = "c:\Program Files\Windows Media Player\mplayer2.exe"
Const MENCODER = "d:\Video\mencoder\mencoder.exe"
Update the installation path of
the tools above.
Quick start guide
Extract logo from video file as a still image
Fist, you need to find logo frame number. Do it with your
favorite media player (given it has the ability to show frame number), or you
can use the following command:
The configured video player will open with frame number
shown in the top left corner. Now you can find logo frame number. After this
perform the following command:
saveFrame.cmd <movie_file> <logo_frame_number>
will be saved as logo.ebmp in the movie directory.
View logo from .ebmp file
Cut the video up to the logo
The basic way is just
script will use logo.ebmp in the movie directory as a logo to search for. The
cut version will be saved with ‘_cut’ suffix in the file name.
Run cut.cmd without any parameters to see the list of all
available options. Any parameter of the form ‘param=value’ will be used to run
FindFrame Avisynth plugin (note no space before or after the ‘=’). Read
FindFrame description for more information.
Here is an example of command I’m using in GB-PVR
call d:\utils\logoCutter\cut.cmd %1 /overwrite threshold=13
allow_over_threshold=10 chroma=false upto_minute=10
- Check for Avisynth errors: run
parameter. Media Player will open when FindFrame start working (note: it may
take a couple of minutes before the player start responding). If there are
Avisynth errors, you will see them in the player window. Additionally, you
may see FindFrame progress information using
- FindFrame is working but logo frame is not found:
threshold and allow_over_threshold parameters
need to be adjusted. Find frame number that looks like logo and then run
File log.txt will contain 3
columns. First column is a threshold value; it is going from 1 to 15. For each
threshold, you can find what there should have been the
allow_over_threshold value, in the following
allow_over_threshold = 100 - <third column value>
Try to keep both parameters as
low as possible.