Skip to content

Commit

Permalink
MythArchive: update mythburn.py to work with the new mpeg2video codec…
Browse files Browse the repository at this point in the history
… name

Refs #11299.

Signed-off-by: Stuart Auchterlonie <stuarta@squashedfrog.net>

(cherry picked from 13c3035)
  • Loading branch information
paul-h authored and jyavenard committed Mar 8, 2013
1 parent 4a7667e commit 19bc463
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions mythplugins/mytharchive/mythburn/scripts/mythburn.py
Expand Up @@ -4345,7 +4345,7 @@ def getStreamList(folder):
def isFileOkayForDVD(file, folder):
"""return true if the file is dvd compliant"""

if string.lower(getVideoCodec(folder)) != "mpeg2video":
if string.lower(getVideoCodec(folder)) != "mpeg2video (main)":
return False

# if string.lower(getAudioCodec(folder)) != "ac3" and encodeToAC3:
Expand Down Expand Up @@ -4425,7 +4425,7 @@ def doProcessFile(file, folder, count):
#can only use mythtranscode to cut commercials on mpeg2 files
write("File type is '%s'" % getFileType(folder))
write("Video codec is '%s'" % getVideoCodec(folder))
if string.lower(getVideoCodec(folder)) == "mpeg2video":
if string.lower(getVideoCodec(folder)).startswith("mpeg2video"):
if file.attributes["usecutlist"].value == "1" and getText(infoDOM.getElementsByTagName("hascutlist")[0]) == "yes":
# Run from local file?
if file.hasAttribute("localfilename"):
Expand Down Expand Up @@ -4462,8 +4462,8 @@ def doProcessFile(file, folder, count):
write("File type is '%s'" % getFileType(folder))
write("Video codec is '%s'" % getVideoCodec(folder))

if (alwaysRunMythtranscode == True and
string.lower(getVideoCodec(folder)) == "mpeg2video" and
if (alwaysRunMythtranscode == True and
string.lower(getVideoCodec(folder)).startswith("mpeg2video") and
isFileOkayForDVD(file, folder)):
if file.hasAttribute("localfilename"):
localfile = file.attributes["localfilename"].value
Expand Down

0 comments on commit 19bc463

Please sign in to comment.