- self.do_exec([
- "mencoder",
- "-o", self.opts.output + ".avi",
- "-oac", "copy", "-ovc", "copy",
- "-noskip", "-mc", "0",
- "-audiofile", self.audio_tmp,
- self.video_tmp,
- ])
+ os.mkfifo("video.y4m")
+ os.mkfifo("audio.wav")
+ cmd = []
+ cmd += ["mplayer", self.opts.input]
+ cmd += ["-benchmark", "-noconsolecontrols", "-noconfig", "all"]
+ cmd += ["-vo", "yuv4mpeg:file=video.y4m"]
+ cmd += ["-ao", "pcm:waveheader:file=audio.wav"]
+ insert_mplayer_options(cmd, self.opts)
+ cmd += self.profile.extra
+ self.do_exec(cmd, wait=False)
+
+
+class X264(Command):
+ def init(self):
+ self.check_command("x264")
+ self.profile.video_tmp = "video.h264"
+
+ def run(self):
+ p = self.profile
+ cmd = []
+ cmd += ["x264", "--no-progress"]
+ cmd += p.x264opts
+ cmd += ["-o", p.video_tmp]
+ cmd += ["video.y4m"]
+ self.do_exec(cmd, wait=False)
+
+
+class Lame(Command):
+ def init(self):
+ self.check_command("lame")
+ self.profile.audio_tmp = "audio.mp3"
+
+ def run(self):
+ p = self.profile
+ cmd = []
+ cmd += ["lame", "--quiet"]
+ cmd += p.lameopts
+ cmd += ["audio.wav"]
+ cmd += [p.audio_tmp]
+ self.do_exec(cmd, wait=False)
+
+
+class Faac(Command):
+ def init(self):
+ self.check_command("faac")
+ self.profile.audio_tmp = "audio.aac"