0

I am running the following code segment:

import pydub
from pydub import AudioSegment
from pydub.playback import play
from datetime import datetime

blast_file = AudioSegment.from_mp3(
    "/Users/ME/Desktop/Current Work/CRTT study - 2022/radio_static.mp3"
)

blast_file_1 = blast_file
blast_file_l1 = blast_file_1.pan(-1)
blast_file_r1 = blast_file_1.pan(1)

play(blast_file_l1)
play(blast_file_r1)

It runs perfectly fine on my mac, playing only out of the left ear with l1 and only the right with r1. The same code on my PC (windows 10) runs the program without any error messages, but it does not pan the audio (both files play out of both ears).

I have messed around with changing the dBs in either channel, which works fine on the PC. I have also tried variations like .pan(-1.0), .pan(+1.0), .pan(-0.99), etc. to no avail. As far as I can tell, everything but pan works just fine on both systems. Any advice?

  • It is worth noting that I can hear that the left/right channel is quieter when it should be silent so panning is doing something... – Annah.Grace Feb 03 '23 at 16:58

0 Answers0