is there a way to detect the different Audio tracks?
Posted: 08 Mar 2015, 18:04
So i'm trying to detect the different audio tracks of a video file.
{audios.groupBy{ it.language }.collect{ c, a -> a*.language}.flatten()})
seems to work. but i'd guess only if the audio track has an encoded language.
I have several videos that have the main audio track, and then a commentary. that i can't get it to display anything for the audio track at all.
in those cases (I'd like it to display "2 audio tracks") unless there was a way to determine if one was a commentary. that would be nice. though i'm guessing not possible.
and if it has 2 audio tracks, maybe: 1. English 2ch, 2. English 6ch)
would be nice
I did see this: {'.'+audios.groupBy{ it.Codec }.collect{ c, a -> [c] + a*.Language }.flatten().join('.')}{'.['+texts.language.flatten().join('.')+']'}{'.'+vc}
from another post on here that I was working with. but it isn't detecting many of the videos with the second commentary track. - (that i verified in Windows Media player are indeed in the video) - I'd assume maybe not all videos have the language name encoded in the audio track, so it just doesn't pull anything up? i'm not sure.
I would appreciate any help or advice. thank you.
{audios.groupBy{ it.language }.collect{ c, a -> a*.language}.flatten()})
seems to work. but i'd guess only if the audio track has an encoded language.
I have several videos that have the main audio track, and then a commentary. that i can't get it to display anything for the audio track at all.
in those cases (I'd like it to display "2 audio tracks") unless there was a way to determine if one was a commentary. that would be nice. though i'm guessing not possible.
and if it has 2 audio tracks, maybe: 1. English 2ch, 2. English 6ch)
would be nice
I did see this: {'.'+audios.groupBy{ it.Codec }.collect{ c, a -> [c] + a*.Language }.flatten().join('.')}{'.['+texts.language.flatten().join('.')+']'}{'.'+vc}
from another post on here that I was working with. but it isn't detecting many of the videos with the second commentary track. - (that i verified in Windows Media player are indeed in the video) - I'd assume maybe not all videos have the language name encoded in the audio track, so it just doesn't pull anything up? i'm not sure.
I would appreciate any help or advice. thank you.