[mythtv-users] commercial skipping recorded shows

Chris Pinkham cpinkham at bc2va.org
Fri May 9 12:57:20 EDT 2003


> >>> if i've watched the show 'live' while its being recorded, then the
> >>> commercial skip sucks, taking 10s of seconds to skip through minutes of
>

<snip>

> what you describe is consistent with the lack of a "seektable".
 
<snip again>

> So it's not the fact that you are watching the recording in
> progress that's slowing things down, it's the fact that the
> recording hasn't finished.

Isaac already responded to this, but I wanted to throw in my $0.02 as
well.  Since the seektable is available to the frontend while watching
LiveTV or an in-progress recording, then seeks can happen very fast.

The slowdown occurs when you try to use the commercial skip feature
before a recording is finished since the commercial skip information is
not saved to the database until the recording completes.  During recording,
blank frames are detected and a list is kept.  That list gets saved to
the database immediately after the recording finishes so if you start
watching right away you can get fairly accurate commercial skips based
upon just the blank frames.  Then another thread is fired off which
plays back through the recorded video and does the commercial detection.
Currently the only method used for detection is blank-frame, so the
commercial skip list generated by the FlagCommercials thread should
be equivalent to the skip list that is generated on-the-fly by the player
if a blank frame list exists but no commercial skip list exists.  I am
currently tossing around a few ideas on what to proceed with next to
add some better/additional detection methods to the FlagCommercials
thread, so that will get better as time goes by.

The blank frame list that is saved by the recorder is used to allow
the player to do some fairly accurate commercial skipping before the
actual commercial skip list is generated by the post-processing
FlagCommercials thread.

If no blank frame list or commercial skip list exists for a video,
then the player has to manually scan frame-by-frame to find blank frames.
This is SLOWWWWWWWWWW and is the pause that is being seen.  I believe
that I can eliminate this by adding code to allow the frontend to query
the current blank frame list from the recorder the same way it queries
the seektable.  This blank frame list could then be used to generate
a quick commercial skip list to allow nearly instantaneous skipping.

It's on my TODO list which means it's running as a nice-ed background
process in my brain right now. :)  This should be pretty easy to do, so
it should be implemented in the near future.

Chris



More information about the mythtv-users mailing list