Skip to content

Commit 7366424

Browse files
committed
Force stereo videos to solve issue with 5.1 sound videos
1 parent 91f1100 commit 7366424

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1010
### Changed
1111

1212
- Upgrade to wombat 3.8.8 and other Python/JS dependencies (#249)
13+
- Force stereo videos to solve issue with 5.1 sound videos (#250)
1314

1415
## [5.1.0] - 2025-01-21
1516

src/zimscraperlib/video/presets.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ class VoiceMp3Low(Config):
2222
"-codec:a": "mp3", # audio codec
2323
"-ar": "44100", # audio sampling rate
2424
"-b:a": "48k", # target audio bitrate
25+
"-ac": "2", # force stereo even if input is higher
2526
}
2627

2728

@@ -49,6 +50,7 @@ class VideoWebmLow(Config):
4950
"-codec:a": "libvorbis", # audio codec
5051
"-b:a": "48k", # target audio bitrate
5152
"-ar": "44100", # audio sampling rate
53+
"-ac": "2", # force stereo even if input is higher
5254
}
5355

5456

@@ -77,6 +79,7 @@ class VideoMp4Low(Config):
7779
"-ar": "44100", # audio sampling rate
7880
"-b:a": "48k", # target audio bitrate
7981
"-movflags": "+faststart", # extra flag
82+
"-ac": "2", # force stereo even if input is higher
8083
}
8184

8285

@@ -101,6 +104,7 @@ class VideoWebmHigh(Config):
101104
"-codec:a": "libvorbis", # audio codec
102105
"-b:a": "48k", # target audio bitrate
103106
"-ar": "44100", # audio sampling rate
107+
"-ac": "2", # force stereo even if input is higher
104108
}
105109

106110

0 commit comments

Comments
 (0)