I have 2 sets of headphones connected to my laptop via an audio jack splitter. I am using Pydub in Python and I want to be able to play audio in one set of headphones at a time. I expected to be able to do this by using pan, assuming that the splitter would basically make one pair of headphones the right channel, and the other the left. But, when I run the following code, I get audio coming out of the right side only of both headsets.
import pydub
from pydub import AudioSegment
from pydub.playback import play
blast_file = AudioSegment.from_mp3(
"file.mp3"
)
blast_file_left = blast_file.pan(-1)
blast_file_right = blast_file.pan(1)
play(blast_file_right)
Do you know a.) if there is a way to code around this problem for my desired result, or b.) if there is different hardware that will split the headsets into a right and left channel?
TYIA