Ticket #11758: mythburn.patch

File mythburn.patch, 2.1 KB (added by Raymond Wagner, 11 years ago)
  • mythplugins/mytharchive/mythburn/scripts/mythburn.py

    diff --git a/mythplugins/mytharchive/mythburn/scripts/mythburn.py b/mythplugins/mytharchive/mythburn/scrip
    index f0c96ea..335c1a5 100755
    a b import ImageFont 
    8888import ImageColor
    8989import unicodedata
    9090import time
    91 import datetime
    9291import tempfile
    9392from fcntl import ioctl
    9493import CDROM
    9594from shutil import copy
    9695
    9796import MythTV
     97from MythTV import datetime
    9898from MythTV.altdict import OrdDict
    9999
    100100# media types (should match the enum in mytharchivewizard.h)
    def runMythtranscode(chanid, starttime, destination, usecutlist, localfile): 
    16961696    """Use mythtranscode to cut commercials and/or clean up an mpeg2 file"""
    16971697
    16981698    rec = DB.searchRecorded(chanid=chanid, starttime=starttime).next()
     1699    starttime = rec.starttime.utcisoformat()
    16991700    cutlist = rec.markup.getcutlist()
    17001701
    17011702    cutlist_s = ""
    def encodeNuvToMPEG2(chanid, starttime, mediafile, destvideofile, folder, profil 
    21342135           qdiff = value
    21352136
    21362137    if chanid != -1:
     2138        utcstarttime = datetime.duck(starttime).utcisoformat()
    21372139        if (usecutlist == True):
    21382140            PID=os.spawnlp(os.P_NOWAIT, "mythtranscode", "mythtranscode",
    21392141                        '--profile', '27',
    21402142                        '--chanid', chanid,
    2141                         '--starttime', starttime,
     2143                        '--starttime', utcstarttime,
    21422144                        '--honorcutlist',
    21432145                        '--fifodir', folder)
    21442146            write("mythtranscode started (using cut list) PID = %s" % PID)
    def encodeNuvToMPEG2(chanid, starttime, mediafile, destvideofile, folder, profil 
    21462148            PID=os.spawnlp(os.P_NOWAIT, "mythtranscode", "mythtranscode",
    21472149                        '--profile', '27',
    21482150                        '--chanid', chanid,
    2149                         '--starttime', starttime,
     2151                        '--starttime', utcstarttime,
    21502152                        '--fifodir', folder)
    21512153
    21522154            write("mythtranscode started PID = %s" % PID)