1. Some audios are not named completely, that is, DTS-HD MA only marks them as DTS, trueHD gives me some strange characters.
2. I would like that if the file has several audios, for example "English AC3 and English DTS-HD MA" I would only be given the highest quality one.
Is there a possibility to do it?
Thank you.
Format: Select all
{n} ({y}) [BDRip {vf}][{ import java.math.RoundingMode
import net.filebot.Language
audio.collect { au ->
def channels = any{ au['ChannelPositions/String2'] }{ au['Channel(s)_Original'] }{ au['Channel(s)'] }
def ch = channels.tokenize('\\/')*.toDouble()
.inject(0, { a, b -> a + b }).findAll { it > 0 }
.max().toBigDecimal().setScale(1, RoundingMode.HALF_UP).toString()
def codec = any{ au['CodecID/Hint'] }{ au['Format'] }.replaceAll(/['`´‘’?\p{Punct}\p{Space}]/, '')
return allOf{Language.findLanguage(au['Language']).ISO3.upper()}{codec}{ch} }*.join(" ").join(" - ") }]