Bug fix
This commit is contained in:
parent
a4fe115a7c
commit
f41d245c0f
@ -44,6 +44,7 @@ function plugin(file) {
|
|||||||
|
|
||||||
var audioIdx = -1
|
var audioIdx = -1
|
||||||
var hasCommentaryTrack = false
|
var hasCommentaryTrack = false
|
||||||
|
var ffmpegCommandInsert = ""
|
||||||
|
|
||||||
|
|
||||||
for (var i = 0; i < file.ffProbeData.streams.length; i++) {
|
for (var i = 0; i < file.ffProbeData.streams.length; i++) {
|
||||||
@ -59,11 +60,14 @@ function plugin(file) {
|
|||||||
//check if commentary track and passing audio stream number
|
//check if commentary track and passing audio stream number
|
||||||
try {
|
try {
|
||||||
if (file.ffProbeData.streams[i].codec_type.toLowerCase() == "audio" && file.ffProbeData.streams[i].tags.title.toLowerCase().includes("commentary")) {
|
if (file.ffProbeData.streams[i].codec_type.toLowerCase() == "audio" && file.ffProbeData.streams[i].tags.title.toLowerCase().includes("commentary")) {
|
||||||
|
|
||||||
|
|
||||||
ffmpegCommandInsert += ` -map -0:a:${audioIdx}`
|
ffmpegCommandInsert += ` -map -0:a:${audioIdx}`
|
||||||
hasCommentaryTrack = true
|
hasCommentaryTrack = true
|
||||||
|
|
||||||
}
|
}
|
||||||
} catch (err) { }
|
} catch (err) {
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user