Stage: "Pre-processing" added

make-only-subtitle-default
HaveAGitGat 6 years ago
parent f41d245c0f
commit 4168f0bc1a

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_075a_FFMPEG_HEVC_Generic",
Stage: "Pre-processing",
Name: "FFMPEG H265",
Type: "Video",
Operation:"Transcode",

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_075b_FFMPEG_HEVC_Generic_Video_Audio_Only",
Stage: "Pre-processing",
Name: "FFMPEG H265 Video + Audio Kept Only",
Type: "Video",
Operation:"Transcode",

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_a37x_Drawmonster_MP4_No_Title_Meta",
Stage: "Pre-processing",
Name: "Drawmonster MP4 No title meta data ",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes metadata (if a title exists). The output container is mp4. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_a8hc_HaveAGitGat_HandBrake_H264_VeryFast1080p30",
Stage: "Pre-processing",
Name: "HaveAGitGat HandBrake VeryFast1080p30, No title meta, no subs, 192Kb AAC stereo,MP4 ",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes into H264 using HandBrake's 'Very Fast 1080p30' preset if the file is not in H264 already. It removes subs, metadata (if a title exists) and adds a stereo 192kbit AAC track if an AAC track (any) doesn't exist. The output container is MP4. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_a9hc_HaveAGitGat_HandBrake_H264_Fast1080p30",
Stage: "Pre-processing",
Name: "HaveAGitGat HandBrake Fast1080p30, No title meta, no subs, 192Kb AAC stereo,MP4 ",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes into H264 using HandBrake's 'Fast 1080p30' preset if the file is not in H264 already. It removes subs, metadata (if a title exists) and adds a stereo 192kbit AAC track if an AAC track (any) doesn't exist. The output container is MP4. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_b38x_Nosirus_h265_aac_no_meta",
Stage: "Pre-processing",
Name: "Nosirus h265, aac, no meta, subs kept",
Type: "Video",
Description: `[Contains built-in filter] If the file is not in h265 it will be trancoded into h265 with HandBrake using the following command '-e x265 -q 22 --encoder-preset slow --all-audio --all-subtitles copy:aac -E fdk_aac -Q 4 -x aq-mode=3'. If no aac, aac track will be added. Subtitles are kept. Metadata is removed.\n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_b39x_the1poet_surround_sound_to_ac3",
Stage: "Pre-processing",
Name: "the1poet Video surround sound to ac3",
Type: "Video",
Description: `[Contains built-in filter] If the file has surround sound tracks not in ac3, they will be converted to ac3. \n\n

@ -1,6 +1,7 @@
function details() {
return {
id: "Tdarr_Plugin_d5d3_iiDrakeii_FFMPEG_NVENC_Tiered_MKV",
Stage: "Pre-processing",
Name: "Tiered FFMPEG NVENC settings depending on resolution",
Type: "Video",
Operation:"Transcode",

@ -1,6 +1,7 @@
function details() {
return {
id: "Tdarr_Plugin_d5d4_iiDrakeii_Not_A_Video_Mjpeg_Fix",
Stage: "Pre-processing",
Name: "Mjpeg Stream False Not A Video Fixer",
Type: "Video",
Operation:"",

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_e3jc_Tharic_H.264_MKV_480p30_No_Subs_No_Title_Meta",
Stage: "Pre-processing",
Name: "H.264 MKV 480p30, No Subs No, Title Meta",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes subs, metadata (if a title exists) and makes sure the video is h264 480p mkv. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_e3jd_Tharic_H.264_MKV_720p30_No_Subs_No_Title_Meta",
Stage: "Pre-processing",
Name: "H.264 MKV 720p30, No Subs No, Title Meta",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes subs, metadata (if a title exists) and makes sure the video is h264 720p mkv. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_e3je_Tharic_H.264_MKV_1080p30_No_Subs_No_Title_Meta",
Stage: "Pre-processing",
Name: "H.264 MKV 1080p30, No Subs No, Title Meta",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes subs, metadata (if a title exists) and makes sure the video is h264 1080p mkv. \n\n

@ -4,6 +4,7 @@ const iso6392 = require('/home/Tdarr/Documents/node_modules/iso-639-2');
function details() {
return {
id: "Tdarr_Plugin_e5c3_CnT_Add_Subtitles",
Stage: "Pre-processing",
Name: "Add subtitles to MKV files",
Type: "Video",
Operation:"Remux",

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_fd5T_Sparticus_4K_AC3_No_Subs",
Stage: "Pre-processing",
Name: "Sparticus 4K +AC3 No Subs Original container",
Type: "Video",
Description: `[Contains built-in filter] This plugin for 4K video removes subs. If no AC3 track exists, it adds one (max 5.1 channels). If only an AC3 commentary track exists, it adds a new AC3 main track (max 5.1 channels). The output container is the same as the original file. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_hk75_Drawmonster_MP4_AAC_No_Subs_No_metaTitle",
Stage: "Pre-processing",
Name: "Drawmonster MP4 Stereo AAC, No Subs, No title meta data ",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes subs, metadata (if a title exists) and adds a stereo 192kbit AAC track if an AAC track (English or any) doesn't exist. The output container is mp4. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_hk76_GilbN_MP4_AAC_No_metaTitle",
Stage: "Pre-processing",
Name: "GilbN MP4 Stereo AAC, No title meta data ",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes metadata (if a title exists) and adds a stereo 192kbit AAC track if an AAC track (any) doesn't exist. The output container is mp4. \n\n

@ -2,6 +2,7 @@ function details() {
return {
id: "Tdarr_Plugin_lmg1_Reorder_Streams",
Stage: "Pre-processing",
Name: "Tdarr_Plugin_lmg1_Reorder_Streams ",
Type: "Video",
Description: `[Contains built-in filter] This plugin will move the video stream to the front so Tdarr will recognize the codec correctly.\n\n`,

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_nc7x_Drawmonster_No_Title_Meta",
Stage: "Pre-processing",
Name: "Drawmonster No title meta data ",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes metadata (if a title exists). The output container is the same as the original. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_s710_nick_h265_nvenc_4K",
Stage: "Pre-processing",
Name: "Nick H265 NVENC 4K",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes all 4K videos to h265 using nvenc (if not in h265 already). For 4K and files in other resolutions: If not in mkv the file is remuxed into mkv. If the English language track is not in AC3,EAC3 or DTS then an AC3 track is added.\n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_s7x8_winsome_h265",
Stage: "Pre-processing",
Name: "Winsome H265 ",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes all videos to h265 (if not in h265 already) and remuxes if not in mkv. If the English language track is not in AC3,EAC3 or DTS then an AC3 track is added.\n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_s7x9_winsome_h265_10bit",
Stage: "Pre-processing",
Name: "Winsome H265 10 bit ",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes all videos to h265 10 bit (if not in h265 already) and remuxes if not in mkv. If the English language track is not in AC3,EAC3 or DTS then an AC3 track is added.\n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_s7x9_winsome_h265_nvenc",
Stage: "Pre-processing",
Name: "Winsome H265 NVENC",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes all videos to h265 using nvenc (if not in h265 already) and remuxes if not in mkv. If the English language track is not in AC3,EAC3 or DTS then an AC3 track is added.\n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_sdd3_Remove_Commentary_Tracks",
Stage: "Pre-processing",
Name: "Remove video commentary tracks",
Type: "Video",
Operation: "Remux",

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_sdf5_Thierrrrry_Remove_Non_English_Audio",
Stage: "Pre-processing",
Name: "Remove Non English Audio ",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes audio tracks which are not English or are not undefined. It ensures at least 1 audio track is left in any language. \n\n
@ -35,7 +36,7 @@ function plugin(file) {
response.FFmpegMode = true
//check if files is video
if (file.fileMedium !== "video") {
@ -47,22 +48,25 @@ function plugin(file) {
return response
}
}
var ffmpegCommandInsert = ''
var audioIdx = -1
var hasNonEngTrack = false
var audioStreamsRemoved = 0
var ffmpegCommandInsert = ''
var audioIdx = -1
var hasNonEngTrack = false
var audioStreamsRemoved = 0
var audioStreamCount = file.ffProbeData.streams.filter(row => (row.codec_type.toLowerCase() == "audio")).length;
//count number of audio streams
var audioStreamCount = file.ffProbeData.streams.filter(row => (row.codec_type.toLowerCase() == "audio")).length;
console.log("audioStreamCount:" + audioStreamCount)
console.log("audioStreamCount:" + audioStreamCount)
for (var i = 0; i < file.ffProbeData.streams.length; i++) {
//check if current stream is audio, update audioIdx if so
try {
if (file.ffProbeData.streams[i].codec_type.toLowerCase() == "audio") {
audioIdx++
@ -70,18 +74,15 @@ function plugin(file) {
} catch (err) { }
try {
if (file.ffProbeData.streams[i].codec_type.toLowerCase() == "audio" && !(file.ffProbeData.streams[i].tags.language.toLowerCase().includes('eng') || file.ffProbeData.streams[i].tags.language.toLowerCase().includes('und'))) {
audioStreamsRemoved++
if(audioStreamsRemoved == audioStreamCount){
if (audioStreamsRemoved == audioStreamCount) {
break;
}
ffmpegCommandInsert += ` -map -0:a:${audioIdx}`
hasNonEngTrack = true
@ -93,27 +94,27 @@ function plugin(file) {
if (hasNonEngTrack === true) {
if (hasNonEngTrack === true) {
response.processFile = true;
response.preset = `, -map 0 ${ffmpegCommandInsert} -c copy`
response.container = '.' + file.container
response.handBrakeMode = false
response.FFmpegMode = true
response.reQueueAfter = true;
response.infoLog += "☒File contains tracks which are not english or undefined. Removing! \n"
return response
response.processFile = true;
response.preset = `, -map 0 ${ffmpegCommandInsert} -c copy`
response.container = '.' + file.container
response.handBrakeMode = false
response.FFmpegMode = true
response.reQueueAfter = true;
response.infoLog += "☒File contains tracks which are not english or undefined. Removing! \n"
return response
} else {
} else {
response.infoLog += "☑File doesn't contain tracks which are not english or undefined! \n"
response.infoLog += "☑File doesn't contain tracks which are not english or undefined! \n"
}
}
response.processFile = false;
return response
response.processFile = false;
return response
}
module.exports.details = details;

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_x7ab_Remove_Subs",
Stage: "Pre-processing",
Name: "Remove subtitles ",
Type: "Video",
Description: `[Contains built-in filter] This plugin removes subtitles if detected. The output container is the same as the original. \n\n`,

@ -4,6 +4,7 @@ function details() {
return {
id: "Tdarr_Plugin_x7ac_Remove_Closed_Captions",
Stage: "Pre-processing",
Name: "Remove closed captions",
Type: "Video",
Operation: "Remux",

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_z0ab_TheRealShadoh_FFmpeg_Subs_H264_Medium",
Stage: "Pre-processing",
Name: "TheRealShadoh FFmpeg Subs Medium, video MP4, audio AAC, keep subs. ",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes into H264 using FFmpeg's 'Medium' preset if the file is not in H264 already. It maintains all subtitles. It removes metadata (if a title exists), and maintains all audio tracks. The output container is MP4. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_z1ab_TheRealShadoh_FFmpeg_Subs_H264_Fast",
Stage: "Pre-processing",
Name: "TheRealShadoh FFmpeg Subs Fast, video MP4, audio AAC, keep subs. ",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes into H264 using FFmpeg's 'Fast' preset if the file is not in H264 already. It maintains all subtitles. It removes metadata (if a title exists), and maintains all audio tracks. The output container is MP4. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_z2ab_TheRealShadoh_FFmpeg_Subs_H264_Slow",
Stage: "Pre-processing",
Name: "TheRealShadoh FFmpeg Subs Slow, video MP4, audio AAC, keep subs. ",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes into H264 using FFmpeg's 'Slow' preset if the file is not in H264 already. It maintains all subtitles. It removes metadata (if a title exists), and maintains all audio tracks. The output container is MP4. \n\n

@ -5,6 +5,7 @@ function details() {
return {
id: "Tdarr_Plugin_z3ab_TheRealShadoh_FFmpeg_Subs_H264_VeryFast",
Stage: "Pre-processing",
Name: "TheRealShadoh FFmpeg Subs VeryFast, video MP4, audio AAC, keep subs. ",
Type: "Video",
Description: `[Contains built-in filter] This plugin transcodes into H264 using FFmpeg's 'VeryFast' preset if the file is not in H264 already. It maintains all subtitles. It removes metadata (if a title exists), and maintains all audio tracks. The output container is MP4. \n\n

Loading…
Cancel
Save