I'm trying to run this code that should open the selected mp3 with VLC, use Line 1 as the audio output, and close when it's done. But the arguments don't all seem to be getting through.
Python code
import subprocess
vlcpath = "C:\\Program Files (x86)\\VideoLAN\\VLC\\vlc.exe"
audiopath = "C:\\Users\\Aidan\\Desktop\\test.mp3"
args = [vlcpath, audiopath, "--aout=waveout", '--waveout-audio-device="Line 1 (Virtual Audio Cable) ($1,$64)"', "--play-and-exit"]
subprocess.call(args, shell=True)
for i in args: #for diagnostic purposes
print(i)
Which should run similarly to this command line input
"C:\Program Files (x86)\VideoLAN\VLC\vlc.exe" C:\Users\Aidan\Desktop\test.mp3 --aout=waveout --waveout-audio-device="Line 1 (Virtual Audio Cable) ($1,$64)" --play-and-exit
The command line input plays and exits properly, and plays to Line 1. The python code plays and exits, but not to Line 1.
Edit: I should mention I'm using python 3.4.4