<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <br>
    <blockquote
cite="mid:CAKpY+argdWBDB7oBsPqt7eKzbCuJQeYX5LxqwMD6sqEQc-A68g@mail.gmail.com"
      type="cite">
      <div class="gmail_extra">
        <div class="gmail_quote">
          <blockquote class="gmail_quote" style="margin:0 0 0
            .8ex;border-left:1px #ccc solid;padding-left:1ex">
            <div class="gmail_quote">
              <div class="im">On 25 November 2012 21:30, John <span
                  dir="ltr">&lt;<a moz-do-not-send="true"
                    href="mailto:reidjr@lineone.net" target="_blank">reidjr@lineone.net</a>&gt;</span>
                wrote:<br>
                <br>
                <blockquote class="gmail_quote" style="margin:0 0 0
                  .8ex;border-left:1px #ccc solid;padding-left:1ex">
                  <div bgcolor="#FFFFFF" text="#000000">I have been
                    playing around with <a moz-do-not-send="true"
                      href="http://www.mythtv.org/wiki/Mythcommflag-wrapper"
                      target="_blank">Mythcommflag-wrapper</a>. It
                    needed some simple changes to work on 0.26. It also
                    lost the&nbsp; dependency on myth-export ( In fact I
                    couldn't get it to work properly with myth-export to
                    find total no frames). I've moved what I can to
                    mythutil, and deleted the comments that are no
                    longer relevent. I added a few callsigns to the
                    whitelist, but you need to make sure your own
                    callsigns match !! [ on Freeview its ITV1 +1, on
                    Freesat its ITV1+1 ]<br>
                    <br>
                    I've added my edited version to . I have been
                    testing on 0.26, but it probably works on 0.25.<br>
                    <br>
                    My changes are superficial, and are just an update
                    of the previous script(s). It works for me, and on
                    some programs its excellent, others its not so
                    lucky, but its a great deal better than the built in
                    mythcommflag for UK TV.<span><font color="#888888"><br>
                        <br>
                        John</font></span><br>
                  </div>
                </blockquote>
              </div>
            </div>
          </blockquote>
        </div>
      </div>
    </blockquote>
    <br>
    For those interested, I have updated <a moz-do-not-send="true"
      href="http://www.mythtv.org/wiki/Mythcommflag-wrapper"
      target="_blank">http://www.mythtv.org/wiki/Mythcommflag-wrapper</a>
    with a few minor changes:<br>
    <br>
    The final cut was being set as x-0, as i couldn't work out how to
    get the final frame value. This worked for skipping, but caused
    lossless_cut to fail. Now set to x-999999, which seems to do no
    harm.<br>
    <br>
    It does work on HD, as long as the HD has an full mpa sound track.
    DVB-S2 (Freesat) in the UK has a secondary mpa channel on
    ITV/Channel 4 HD, so I have added them to the whitelist. <br>
    <br>
    I have found where the channel has main program and adverts, (ITV3
    for instance) silence detect is spot on, as the silences are right
    at the "back soon" " welcome back" screens they often use on ITV3.<br>
    <br>
    advert-(silence)-program part
    1-backsoon-(silence)-adverts-(silence)-welcome back-[program part 2]<br>
    <br>
    which skips/cuts to<br>
    <br>
    program part 1-backsoon-welcome back-program part 2<br>
    <br>
    Other channels such as E4 tend to have a lot of trailers around the
    programs I am recording, and these are treated as main program. They
    also often have "sponsored by" clips before and after<br>
    <br>
    advert - (silence) - Trailer - sponsored by - program part 1 -
    sponsored by - Trailer - silence - advert-silence - sponsored by -
    program part 2 <br>
    <br>
    which skips/cuts to:<br>
    <br>
    Trailer - sponsored by - program part 1 - sponsored by - Trailer -
    sponsored by - program part 2 <br>
    <br>
    Not as clean, but you still lose the real adverts, but you have to
    manually skip the trailers and sponsorship statements.<br>
    <br>
    <br>
    I assume from other comments that the DVB-T2 (Freeview) versions are
    AC3 only, and will need to be removed from the whitelist for DVB-T2
    users. I don't have a DVB-T2 card so can't test.<br>
    <br>
    I have replaced ffmpeg -i with avconv -i . DVB-S channels usually
    have 2 audio channels. main mpa and audio descriptive mpa, or AC3
    and mpa. Occasionally ffmpeg -i was picking the audio descriptive
    track, which is mostly silence. No idea why, but changing to avconv
    seems to fix it, and ffmpeg is deprecated in favor of avconv, so its
    all good.<br>
    <br>
    I have been experimenting with this updated mythcommflag-wrapper
    script in conjunction with the lossless_cut script from Doug
    Vaughan. I am getting good results, but it needed a few tweaks due
    to peculiarities of UK TV, and my DVB-T card. I am getting good
    results flagging and cutting HD on DVB-S2. <br>
    <br>
    Lossless_cut needs a tweak to ensure the audio descriptive track
    present on UK DVB-S channels doesn't become the default after
    cutting. The tweak can be applied from the conf file (documented in
    the conf file), thanks to additional work from Doug.<br>
    <br>
    John<br>
  </body>
</html>