mirror of
https://github.com/gabehf/Tdarr_Plugins.git
synced 2026-03-09 15:38:19 -07:00
new function + tidy
This commit is contained in:
parent
d60e0c17ad
commit
32b8d73e0f
5 changed files with 228 additions and 15 deletions
|
|
@ -3,26 +3,27 @@
|
|||
module.exports = function transcodeStandardiseAudioCodecs(file, audioEncoder) {
|
||||
|
||||
|
||||
try {
|
||||
|
||||
var audioIdx = -1
|
||||
var hasNonSpecifiedAudioCodecStream = false
|
||||
var ffmpegCommandInsert = ''
|
||||
|
||||
|
||||
//Function required responses
|
||||
// preset
|
||||
// processFile
|
||||
// note
|
||||
|
||||
try {
|
||||
|
||||
|
||||
var audioIdx = -1
|
||||
var hasNonSpecifiedAudioCodecStream = false
|
||||
var ffmpegCommandInsert = ''
|
||||
var audioCodec = audioEncoder
|
||||
|
||||
if (audioEncoder == 'dca') {
|
||||
audioCodec = 'dts'
|
||||
}
|
||||
|
||||
if (audioEncoder == 'libmp3lame') {
|
||||
audioCodec = 'mp3'
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
for (var i = 0; i < file.ffProbeData.streams.length; i++) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue