ffmpeg-normalize 1.28.3__py2.py3-none-any.whl → 1.29.0__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- ffmpeg_normalize/__main__.py +12 -0
- ffmpeg_normalize/_ffmpeg_normalize.py +3 -0
- ffmpeg_normalize/_media_file.py +2 -0
- ffmpeg_normalize/_version.py +1 -1
- {ffmpeg_normalize-1.28.3.dist-info → ffmpeg_normalize-1.29.0.dist-info}/METADATA +9 -2
- ffmpeg_normalize-1.29.0.dist-info/RECORD +16 -0
- {ffmpeg_normalize-1.28.3.dist-info → ffmpeg_normalize-1.29.0.dist-info}/WHEEL +1 -1
- ffmpeg_normalize-1.28.3.dist-info/RECORD +0 -16
- {ffmpeg_normalize-1.28.3.dist-info → ffmpeg_normalize-1.29.0.dist-info}/LICENSE +0 -0
- {ffmpeg_normalize-1.28.3.dist-info → ffmpeg_normalize-1.29.0.dist-info}/entry_points.txt +0 -0
- {ffmpeg_normalize-1.28.3.dist-info → ffmpeg_normalize-1.29.0.dist-info}/top_level.txt +0 -0
ffmpeg_normalize/__main__.py
CHANGED
|
@@ -303,6 +303,17 @@ def create_parser() -> argparse.ArgumentParser:
|
|
|
303
303
|
"""
|
|
304
304
|
),
|
|
305
305
|
)
|
|
306
|
+
group_acodec.add_argument(
|
|
307
|
+
"-ac",
|
|
308
|
+
"--audio-channels",
|
|
309
|
+
type=int,
|
|
310
|
+
help=textwrap.dedent(
|
|
311
|
+
"""\
|
|
312
|
+
Set the number of audio channels.
|
|
313
|
+
If not specified, the input channel layout will be used.
|
|
314
|
+
"""
|
|
315
|
+
),
|
|
316
|
+
)
|
|
306
317
|
group_acodec.add_argument(
|
|
307
318
|
"-koa",
|
|
308
319
|
"--keep-original-audio",
|
|
@@ -506,6 +517,7 @@ def main() -> None:
|
|
|
506
517
|
audio_codec=cli_args.audio_codec,
|
|
507
518
|
audio_bitrate=cli_args.audio_bitrate,
|
|
508
519
|
sample_rate=cli_args.sample_rate,
|
|
520
|
+
audio_channels=cli_args.audio_channels,
|
|
509
521
|
keep_original_audio=cli_args.keep_original_audio,
|
|
510
522
|
pre_filter=cli_args.pre_filter,
|
|
511
523
|
post_filter=cli_args.post_filter,
|
|
@@ -63,6 +63,7 @@ class FFmpegNormalize:
|
|
|
63
63
|
audio_codec (str, optional): Audio codec. Defaults to "pcm_s16le".
|
|
64
64
|
audio_bitrate (float, optional): Audio bitrate. Defaults to None.
|
|
65
65
|
sample_rate (int, optional): Sample rate. Defaults to None.
|
|
66
|
+
audio_channels (int | None, optional): Audio channels. Defaults to None.
|
|
66
67
|
keep_original_audio (bool, optional): Keep original audio. Defaults to False.
|
|
67
68
|
pre_filter (str, optional): Pre filter. Defaults to None.
|
|
68
69
|
post_filter (str, optional): Post filter. Defaults to None.
|
|
@@ -98,6 +99,7 @@ class FFmpegNormalize:
|
|
|
98
99
|
audio_codec: str = "pcm_s16le",
|
|
99
100
|
audio_bitrate: float | None = None,
|
|
100
101
|
sample_rate: float | int | None = None,
|
|
102
|
+
audio_channels: int | None = None,
|
|
101
103
|
keep_original_audio: bool = False,
|
|
102
104
|
pre_filter: str | None = None,
|
|
103
105
|
post_filter: str | None = None,
|
|
@@ -170,6 +172,7 @@ class FFmpegNormalize:
|
|
|
170
172
|
self.dual_mono = dual_mono
|
|
171
173
|
self.dynamic = dynamic
|
|
172
174
|
self.sample_rate = None if sample_rate is None else int(sample_rate)
|
|
175
|
+
self.audio_channels = None if audio_channels is None else int(audio_channels)
|
|
173
176
|
|
|
174
177
|
self.audio_codec = audio_codec
|
|
175
178
|
self.audio_bitrate = audio_bitrate
|
ffmpeg_normalize/_media_file.py
CHANGED
|
@@ -355,6 +355,8 @@ class MediaFile:
|
|
|
355
355
|
cmd.extend(["-b:a", str(self.ffmpeg_normalize.audio_bitrate)])
|
|
356
356
|
if self.ffmpeg_normalize.sample_rate:
|
|
357
357
|
cmd.extend(["-ar", str(self.ffmpeg_normalize.sample_rate)])
|
|
358
|
+
if self.ffmpeg_normalize.audio_channels:
|
|
359
|
+
cmd.extend(["-ac", str(self.ffmpeg_normalize.audio_channels)])
|
|
358
360
|
|
|
359
361
|
# ... and subtitles
|
|
360
362
|
if not self.ffmpeg_normalize.subtitle_disable:
|
ffmpeg_normalize/_version.py
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
__version__ = "1.
|
|
1
|
+
__version__ = "1.29.0"
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: ffmpeg-normalize
|
|
3
|
-
Version: 1.
|
|
3
|
+
Version: 1.29.0
|
|
4
4
|
Summary: Normalize audio via ffmpeg
|
|
5
5
|
Home-page: https://github.com/slhck/ffmpeg-normalize
|
|
6
6
|
Author: Werner Robitza
|
|
@@ -25,7 +25,7 @@ License-File: LICENSE
|
|
|
25
25
|
Requires-Dist: tqdm
|
|
26
26
|
Requires-Dist: ffmpeg-progress-yield
|
|
27
27
|
Requires-Dist: colorlog
|
|
28
|
-
Requires-Dist: colorama
|
|
28
|
+
Requires-Dist: colorama; platform_system == "Windows"
|
|
29
29
|
|
|
30
30
|
# ffmpeg-normalize
|
|
31
31
|
|
|
@@ -324,6 +324,8 @@ For more information on the options (`[options]`) available, run `ffmpeg-normali
|
|
|
324
324
|
|
|
325
325
|
Will use input sample rate by default, except for EBU normalization, which will change the input sample rate to 192 kHz.
|
|
326
326
|
|
|
327
|
+
- `-ac`, `--audio-channels`: Set the number of audio channels. If not specified, the input channel layout will be used. This is equivalent to `-ac` in ffmpeg.
|
|
328
|
+
|
|
327
329
|
- `-koa, --keep-original-audio`: Copy original, non-normalized audio streams to output file
|
|
328
330
|
|
|
329
331
|
- `-prf PRE_FILTER, --pre-filter PRE_FILTER`: Add an audio filter chain before applying normalization.
|
|
@@ -596,6 +598,11 @@ SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
|
596
598
|
# Changelog
|
|
597
599
|
|
|
598
600
|
|
|
601
|
+
## v1.29.0 (2024-10-14)
|
|
602
|
+
|
|
603
|
+
* Add option to set audio channels directly.
|
|
604
|
+
|
|
605
|
+
|
|
599
606
|
## v1.28.3 (2024-08-16)
|
|
600
607
|
|
|
601
608
|
* Make colorama dependency windows-only.
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
ffmpeg_normalize/__init__.py,sha256=aAhlk93ZE6SQcWUDzZQcw9vJh0bJcKEUNFGhVc5ZIto,453
|
|
2
|
+
ffmpeg_normalize/__main__.py,sha256=ErDBLeHLEKke1Ub_Aj5ZmuxFKhPHEMV3ZKHNs2-E7Oc,18427
|
|
3
|
+
ffmpeg_normalize/_cmd_utils.py,sha256=A6quxjOl5tLHxgcs7SdMXzuOCP_JjUTzL1iUD4G7DJk,5361
|
|
4
|
+
ffmpeg_normalize/_errors.py,sha256=brTQ4osJ4fTA8wnyMPVVYfGwJ0wqeShRFydTEwi_VEY,48
|
|
5
|
+
ffmpeg_normalize/_ffmpeg_normalize.py,sha256=mARUHvgLwcs0yGsuDkkDZYqE2JJmnEZtkADKUS4giRc,10556
|
|
6
|
+
ffmpeg_normalize/_logger.py,sha256=3Ap4Fxg7xGrzz7h4IGuNEf0KKstx0Rq_eLbHPrHzcrI,1841
|
|
7
|
+
ffmpeg_normalize/_media_file.py,sha256=FgLHy1lwfvI1EpEvLioyBD30Pj4XzMYUceJ3-J_mb80,16434
|
|
8
|
+
ffmpeg_normalize/_streams.py,sha256=5zLlSK2vMTBs0HzBTmI5UiJVqSp1Nk19TZXpxNtjkIA,19973
|
|
9
|
+
ffmpeg_normalize/_version.py,sha256=eVlxQqZ7oGpvnt3LTlQf3uAGXW6kYUOGvlYLZn1ordc,23
|
|
10
|
+
ffmpeg_normalize/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
11
|
+
ffmpeg_normalize-1.29.0.dist-info/LICENSE,sha256=zeqAHGWrSIwdPHsZMZv1_N0gGFO1xxjcZEz9CplR4EM,1086
|
|
12
|
+
ffmpeg_normalize-1.29.0.dist-info/METADATA,sha256=t0YoTmIh9Mt5SK5zXb4Wsx-PIjZzJEMOpaAhnShHPlc,56093
|
|
13
|
+
ffmpeg_normalize-1.29.0.dist-info/WHEEL,sha256=fS9sRbCBHs7VFcwJLnLXN1MZRR0_TVTxvXKzOnaSFs8,110
|
|
14
|
+
ffmpeg_normalize-1.29.0.dist-info/entry_points.txt,sha256=X0EC5ptb0iGOxrk3Aa65dVQtvUixngLd_2-iAtSixdc,68
|
|
15
|
+
ffmpeg_normalize-1.29.0.dist-info/top_level.txt,sha256=wnUkr17ckPrrU1JsxZQiXbEBUnHKsC64yck-MemEBuI,17
|
|
16
|
+
ffmpeg_normalize-1.29.0.dist-info/RECORD,,
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
ffmpeg_normalize/__init__.py,sha256=aAhlk93ZE6SQcWUDzZQcw9vJh0bJcKEUNFGhVc5ZIto,453
|
|
2
|
-
ffmpeg_normalize/__main__.py,sha256=Y1iJutUrHyvr6HTM9Hk7r1PEvkPBbaP99kTQRpNVUbw,18104
|
|
3
|
-
ffmpeg_normalize/_cmd_utils.py,sha256=A6quxjOl5tLHxgcs7SdMXzuOCP_JjUTzL1iUD4G7DJk,5361
|
|
4
|
-
ffmpeg_normalize/_errors.py,sha256=brTQ4osJ4fTA8wnyMPVVYfGwJ0wqeShRFydTEwi_VEY,48
|
|
5
|
-
ffmpeg_normalize/_ffmpeg_normalize.py,sha256=zvqxGvyAfx1pZr7kSlhHACx5qJC-atlmQpbVIptVHUQ,10346
|
|
6
|
-
ffmpeg_normalize/_logger.py,sha256=3Ap4Fxg7xGrzz7h4IGuNEf0KKstx0Rq_eLbHPrHzcrI,1841
|
|
7
|
-
ffmpeg_normalize/_media_file.py,sha256=oBZl0wl6XEyJLWNxtyhgZR_9cp22D9-hSUUHDC8LdQo,16310
|
|
8
|
-
ffmpeg_normalize/_streams.py,sha256=5zLlSK2vMTBs0HzBTmI5UiJVqSp1Nk19TZXpxNtjkIA,19973
|
|
9
|
-
ffmpeg_normalize/_version.py,sha256=4WEUaUH8jsAY-R3QLSQJkfbfM276l8HmEK4N_ImQJSo,23
|
|
10
|
-
ffmpeg_normalize/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
11
|
-
ffmpeg_normalize-1.28.3.dist-info/LICENSE,sha256=zeqAHGWrSIwdPHsZMZv1_N0gGFO1xxjcZEz9CplR4EM,1086
|
|
12
|
-
ffmpeg_normalize-1.28.3.dist-info/METADATA,sha256=v8BqX0BtgxXH0FX5DqGj-IlQU-yA54kwr7qtTiGEnh8,55862
|
|
13
|
-
ffmpeg_normalize-1.28.3.dist-info/WHEEL,sha256=-G_t0oGuE7UD0DrSpVZnq1hHMBV9DD2XkS5v7XpmTnk,110
|
|
14
|
-
ffmpeg_normalize-1.28.3.dist-info/entry_points.txt,sha256=X0EC5ptb0iGOxrk3Aa65dVQtvUixngLd_2-iAtSixdc,68
|
|
15
|
-
ffmpeg_normalize-1.28.3.dist-info/top_level.txt,sha256=wnUkr17ckPrrU1JsxZQiXbEBUnHKsC64yck-MemEBuI,17
|
|
16
|
-
ffmpeg_normalize-1.28.3.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|