Browse Source

remove dependancy on mpegts... just won't get audio filtering if

it doesn't exist.. (not even sure how good audio filtering is..)

[git-p4: depot-paths = "//depot/": change = 840]
v0.3
John-Mark Gurney 19 years ago
parent
commit
0a06c32ab7
1 changed files with 8 additions and 3 deletions
  1. +8
    -3
      dvd.py

+ 8
- 3
dvd.py View File

@@ -9,7 +9,12 @@ import sets

import sys
sys.path.append('/Users/jgurney/p4/bktrau/info')
import mpegts
try:
import mpegts
audiofilter = lambda x, y: mpegts.DVDAudioFilter(x, y)
except ImportError:
print >>sys.stderr, 'module mpegts could not be loaded, not filtering audio'
audiofilter = lambda x, y: x

from pydvdread import *

@@ -105,8 +110,8 @@ class DVDChapter(VideoItem):
del kwargs['dvdtitle'], kwargs['chapter']

audio = self.dvdtitle.selectaudio(default_audio_lang)
kwargs['content'] = DVDChapterResource(mpegts.DVDAudioFilter(
self.chapter, 0x80 + audio.pos))
kwargs['content'] = DVDChapterResource(
audiofilter(self.chapter, 0x80 + audio.pos))
VideoItem.__init__(self, *args, **kwargs)

self.url = '%s/%s' % (self.cd.urlbase, self.id)


Loading…
Cancel
Save