[mythtv-users] H264 conversion of interlaced MPEG2?

John Pilkington J.Pilk at tesco.net
Tue May 12 20:53:15 UTC 2015


On 12/05/15 21:19, Michael Stucky wrote:
> On Tue, May 12, 2015 at 2:10 PM, Michael Stucky <mike at stucky.us
> <mailto:mike at stucky.us>> wrote:
>
>     On Tue, May 12, 2015 at 11:02 AM, Jay Foster
>     <jayf0ster at roadrunner.com <mailto:jayf0ster at roadrunner.com>> wrote:
>
>         On 5/11/2015 6:49 PM, Michael Stucky wrote:
>>
>>
>>         On May 11, 2015 4:17 PM, "Jay Foster"
>>         <jayf0ster at roadrunner.com <mailto:jayf0ster at roadrunner.com>>
>>         wrote:
>>         >
>>         > On 5/11/2015 12:46 PM, Michael Stucky wrote:
>>         >>
>>         <deletia>
>>         >> Sorry for the delay, it was a busy weekend+... I am not an
>>         ffmpeg expert so all the syntax came either from the original
>>         shell script or searches for a better way to deinterlace. But
>>         I have done some additional searching and testing have updated
>>         my script on the wiki accordingly.
>>         >>
>>         >> "yadif=1" has become "yadif=0:-1:1" (mode 0 = one frame out
>>         for one frame in, parity -1 = autodetect, and deint 1 = only
>>         deinterlace frames marked as interlaced). "sws_flags spline"
>>         is removed (only applies when scaling content?). "-r
>>         60000/1001" is removed (this actually caused every frame to be
>>         duplicated for interlaced content). "threads 0" is removed
>>         (the h264 encoder uses all available threads by default).
>>         "-c:a copy" replaced with "-strict -2" to use the internal AAC
>>         encoder.
>>         >>
>>         >> This works and produces good quality output for all my
>>         content, 1080i, 720p, and 480i all OTA to HDHomerun tuners.
>>         >>
>>         >> Mike
>>         >>
>>         >>
>>         >>
>>         >
>>         > I took a look at the script on the wiki and had a question.
>>         Does this break commercial skipping?  The script does not
>>         appear to reschedule a commflag job after the transcoding.
>>         > Jay
>>         >
>>         >
>>
>>         The script was designed to prepare a recording for export to
>>         the Video Library where it can be played by different
>>         players/devices (vlc, mplayer, android, ios, etc.). As such
>>         commercial skipping wasn't a consideration. The script will
>>         remove a cutlist if it exists (so leaders/trailers/commercials
>>         should all be automatically removed before the transcoding
>>         takes place).
>>
>>         If it is helpful, please take the script and modify it to do
>>         what you want it to and create a new wiki page for your script
>>         so we all can benefit from it!
>>
>>         Mike
>>
>>
>>
>>         _______________________________________________
>>         mythtv-users mailing list
>>         mythtv-users at mythtv.org  <mailto:mythtv-users at mythtv.org>
>>         http://lists.mythtv.org/mailman/listinfo/mythtv-users
>>         http://wiki.mythtv.org/Mailing_List_etiquette
>>         MythTV Forums:https://forum.mythtv.org
>         My thinking was that this script was meant as a user job to be
>         run after a TV recording is made to convert the MPEG2 recording
>         to H.264 for the purpose of viewing these recordings on a low
>         powered device like an Android tablet.  My concern here was that
>         it would auto remove commercials based on commflagging (not
>         good, since the commflagging is not good enough to just auto
>         cut) or that it would not preserve the commflagging (so there
>         would be no commercial skipping watching the transcoded
>         recording).  If this was not the purpose of the script then
>         never mind.
>
>         How does one watch recordings on a tablet then?  I tried the
>         android Mythtv frontend and Mythtv viewer apps, but could not
>         get them to play any recordings.  I came to the conclusion that
>         all recordings had to be pre-transcoded first, which is what I
>         thought this script was all about.
>
>         Jay
>
>
>     I guess I don't understand what you are trying to accomplish. I
>     don't use commflagging for all of the reasons discussed in this
>     forum many times before. Commflagging is completely disabled on my
>     MythTV system. I manually edit my recordings (yes it is time
>     consuming but at least I know everything is correctly flagged) which
>     creates a "cutlist". My script does two separate things, first it
>     uses "mythtranscode" to remove everything in the "cutlist". With all
>     of the content that I don't want already removed
>     (leaders/trailers/commercials/etc.) the script now uses "ffmpeg" to
>     transcode what remains from "mpeg2" to "h264". The resulting video
>     (it is technically no longer a MythTV recording) contains only the
>     show/movie I want and it plays on all my devices and on all of my
>     players (MythTV frontend, vlc, mplayer, android tablet, Amazon
>     FireTV stick, etc.)
>
>     Mike
>
>
> I should have been more clear about how the "cutlist" is created. I use
> my MythTV Frontend to manually edit my recordings which creates a
> "cutlist"...

I've been a little confused here by your statement that you 'remove the 
cutlist'; at first (without looking again at your script) I read it as 
the equivalent of 'mythutil --clearcutlist' but it's now clear that you 
are using it in the sense of 'mythtranscode --honorcutlist' to actually 
remove the sections that you have marked with the 'cutlist editor'.

Thanks for making your script available;  I've been intending, for a 
long time, to modify mine in the light of it, but somehow it still 
hasn't happened :-)

John




More information about the mythtv-users mailing list