update Sox to Sox NG
This commit is contained in:
@@ -32,7 +32,7 @@ class Tee:
|
||||
|
||||
def check_tools():
|
||||
"""Checks if all required command-line tools are in the system's PATH."""
|
||||
required_tools = ["ffmpeg", "ffprobe", "mkvmerge", "sox", "opusenc", "mediainfo"]
|
||||
required_tools = ["ffmpeg", "ffprobe", "mkvmerge", "sox_ng", "opusenc", "mediainfo"]
|
||||
print("--- Prerequisite Check ---")
|
||||
all_found = True
|
||||
for tool in required_tools:
|
||||
@@ -78,9 +78,9 @@ def convert_audio_track(stream_index, channels, temp_dir, source_file, should_do
|
||||
ffmpeg_args.extend(["-c:a", "flac", str(temp_extracted)])
|
||||
run_cmd(ffmpeg_args)
|
||||
|
||||
# Step 2: Normalize the track with SoX
|
||||
print(" - Normalizing with SoX...")
|
||||
run_cmd(["sox", str(temp_extracted), str(temp_normalized), "-S", "--temp", str(temp_dir), "--guard", "gain", "-n"])
|
||||
# Step 2: Normalize the track with SoX NG
|
||||
print(" - Normalizing with SoX NG...")
|
||||
run_cmd(["sox_ng", str(temp_extracted), str(temp_normalized), "-S", "--temp", str(temp_dir), "--guard", "gain", "-n"])
|
||||
|
||||
# Step 3: Encode to Opus with the correct bitrate
|
||||
bitrate = "192k" # Fallback
|
||||
|
||||
Reference in New Issue
Block a user