diff --git a/src/ffx/audio_layout.py b/src/ffx/audio_layout.py index 27cc1a8..99e8ab8 100644 --- a/src/ffx/audio_layout.py +++ b/src/ffx/audio_layout.py @@ -9,6 +9,7 @@ class AudioLayout(Enum): LAYOUT_7_1 = {"label": "7.1", "index": 4} #TODO: Does this exist? LAYOUT_6CH = {"label": "6ch", "index": 5} + LAYOUT_5_0 = {"label": "5.0(side)", "index": 6} LAYOUT_UNDEFINED = {"label": "undefined", "index": 0} diff --git a/src/ffx/ffx_controller.py b/src/ffx/ffx_controller.py index bf20f7f..4dcf558 100644 --- a/src/ffx/ffx_controller.py +++ b/src/ffx/ffx_controller.py @@ -149,6 +149,16 @@ class FfxController(): f"channelmap={FfxController.CHANNEL_MAP_5_1}", f"-b:a:{trackSubIndex}", self.__context['bitrates']['ac3']] + + # -ac 5 ? + if trackAudioLayout == AudioLayout.LAYOUT_5_0: + audioTokens += [f"-c:a:{trackSubIndex}", + 'libopus', + f"-filter:a:{trackSubIndex}", + 'channelmap=channel_layout=5.0', + f"-b:a:{trackSubIndex}", + self.__context['bitrates']['ac3']] + trackSubIndex += 1 return audioTokens