This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#-*- coding:utf-8 -*- | |
# Webm converter for audio streams and video streams (can only convert audio to audio and video to video) | |
import subprocess | |
import sys | |
def convert_to_audio(filename): | |
command = ['ffmpeg', '-i', filename , 'out.mp3'] | |
subprocess.run(command,stdout=subprocess.PIPE,stdin=subprocess.PIPE) |