Multi Languages

Any questions? Need some help?
Post Reply
Rdk206
Posts: 4
Joined: 25 Apr 2017, 23:29

Multi Languages

Post by Rdk206 »

Hi.

I need an audio command for:

1 language: Language of film
2 language: 'Dual'
3 or more language: 'Multi'

This is posible for Movie format in Filebot?

Thank you so much!
User avatar
rednoah
The Source
Posts: 22986
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Multi Languages

Post by rednoah »

Have you tried the {languages} or {audioLanguages} binding? That'll give you a list of languages, and if you want "Dual" and "Multi" then you can just check the size of that list of languages.
:idea: Please read the FAQ and How to Request Help.
Rdk206
Posts: 4
Joined: 25 Apr 2017, 23:29

Re: Multi Languages

Post by Rdk206 »

In other post, I see this:
(audio.size() > 1) ? 'Dual': '[$video_lang]'}

But... When film have 3 audio, I like put Multi, not Dual.

Sorry i'm rookie in filebot, and I speak english little.
User avatar
rednoah
The Source
Posts: 22986
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Multi Languages

Post by rednoah »

e.g.

Code: Select all

audio.size() > 2 ? 'Multi' : audio.size() > 1 ? 'Dual' : audioLanguages[0]
:idea: Please read the FAQ and How to Request Help.
Rdk206
Posts: 4
Joined: 25 Apr 2017, 23:29

Re: Multi Languages

Post by Rdk206 »

oh my god!! Perfect!!!!

One last answer...
I put this: {audio.size() > 2 ? 'Multi' : audio.size() > 1 ? 'Dual' : audioLanguages[0]}

When only have 1 audio, filebot put 'spa' (for example), if I like put 'Esp', How do I put the "replace" command?

Thank you!
User avatar
rednoah
The Source
Posts: 22986
Joined: 16 Nov 2011, 08:59
Location: Taipei
Contact:

Re: Multi Languages

Post by rednoah »

You can get normal and bibliographic language codes like this:

Code: Select all

audioLanguages[0].ISO3

Code: Select all

audioLanguages[0].ISO3B
:idea: Please read the FAQ and How to Request Help.
Rdk206
Posts: 4
Joined: 25 Apr 2017, 23:29

Re: Multi Languages

Post by Rdk206 »

This is I need:

Code: Select all

{audio.size() > 2 ? 'Multi' : audio.size() > 1 ? 'Dual' : audio.language[0].replace('es', 'Esp')}
Thank you for all.
Post Reply