mirror of
https://github.com/gabehf/Tdarr_Plugins.git
synced 2026-03-09 07:29:04 -07:00
Apply auto-build changes
This commit is contained in:
parent
69afa93e70
commit
f7ee4d8b44
18 changed files with 48 additions and 0 deletions
|
|
@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var os_1 = __importDefault(require("os"));
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: '10 Bit Video',
|
||||
|
|
@ -32,6 +33,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
for (var i = 0; i < args.variables.ffmpegCommand.streams.length; i += 1) {
|
||||
var stream = args.variables.ffmpegCommand.streams[i];
|
||||
if (stream.codec_type === 'video') {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Crop Black Bars',
|
||||
|
|
@ -29,6 +30,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
return {
|
||||
outputFileObj: args.inputFileObj,
|
||||
outputNumber: 1,
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Custom Arguments',
|
||||
|
|
@ -50,6 +51,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
var inputArguments = String(args.inputs.inputArguments);
|
||||
var outputArguments = String(args.inputs.outputArguments);
|
||||
if (inputArguments) {
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var fileUtils_1 = require("../../../../FlowHelpers/1.0.0/fileUtils");
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Ensure Audio Stream',
|
||||
|
|
@ -224,6 +225,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
var audioEncoder = String(args.inputs.audioEncoder);
|
||||
var langTag = String(args.inputs.language).toLowerCase();
|
||||
var wantedChannelCount = Number(args.inputs.channels);
|
||||
|
|
|
|||
|
|
@ -193,6 +193,8 @@ var plugin = function (args) { return __awaiter(void 0, void 0, void 0, function
|
|||
throw new Error('FFmpeg failed');
|
||||
}
|
||||
args.logOutcome('tSuc');
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
args.variables.ffmpegCommand.init = false;
|
||||
return [2 /*return*/, {
|
||||
outputFileObj: {
|
||||
_id: outputFilePath,
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'HDR to SDR',
|
||||
|
|
@ -28,6 +29,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
args.variables.ffmpegCommand.streams.forEach(function (stream) {
|
||||
if (stream.codec_type === 'video') {
|
||||
stream.outputArgs.push('-vf', 'zscale=t=linear:npl=100,format=yuv420p');
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Normalize Audio',
|
||||
|
|
@ -29,6 +30,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
return {
|
||||
outputFileObj: args.inputFileObj,
|
||||
outputNumber: 1,
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint-disable no-param-reassign */
|
||||
var details = function () { return ({
|
||||
name: 'Remove Data Streams',
|
||||
|
|
@ -29,6 +30,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
args.variables.ffmpegCommand.streams.forEach(function (stream) {
|
||||
if (stream.codec_type === 'data') {
|
||||
stream.removed = true;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Remove Stream By Property',
|
||||
|
|
@ -63,6 +64,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
var propertyToCheck = String(args.inputs.propertyToCheck).trim();
|
||||
var valuesToRemove = String(args.inputs.valuesToRemove).trim().split(',').map(function (item) { return item.trim(); });
|
||||
var condition = String(args.inputs.condition);
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint-disable no-param-reassign */
|
||||
var details = function () { return ({
|
||||
name: 'Remove Subtitles',
|
||||
|
|
@ -29,6 +30,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
args.variables.ffmpegCommand.streams.forEach(function (stream) {
|
||||
if (stream.codec_type === 'subtitle') {
|
||||
stream.removed = true;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Reorder Streams',
|
||||
|
|
@ -79,6 +80,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
var streams = JSON.parse(JSON.stringify(args.variables.ffmpegCommand.streams));
|
||||
streams.forEach(function (stream, index) {
|
||||
// eslint-disable-next-line no-param-reassign
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@
|
|||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var fileUtils_1 = require("../../../../FlowHelpers/1.0.0/fileUtils");
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint-disable no-param-reassign */
|
||||
var details = function () { return ({
|
||||
name: 'Set Container',
|
||||
|
|
@ -55,6 +56,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
var newContainer = String(args.inputs.container);
|
||||
var forceConform = args.inputs.forceConform;
|
||||
if ((0, fileUtils_1.getContainer)(args.inputFileObj._id) !== newContainer) {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Set Video Framerate',
|
||||
|
|
@ -40,6 +41,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
var desiredFrameRate = Number(args.inputs.framerate);
|
||||
args.jobLog("Desired framerate: ".concat(desiredFrameRate));
|
||||
args.variables.ffmpegCommand.streams.forEach(function (stream) {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Set Video Resolution',
|
||||
|
|
@ -65,6 +66,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
for (var i = 0; i < args.variables.ffmpegCommand.streams.length; i += 1) {
|
||||
var stream = args.variables.ffmpegCommand.streams[i];
|
||||
if (stream.codec_type === 'video') {
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var fileUtils_1 = require("../../../../FlowHelpers/1.0.0/fileUtils");
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint no-plusplus: ["error", { "allowForLoopAfterthoughts": true }] */
|
||||
var details = function () { return ({
|
||||
name: 'Set Video Bitrate',
|
||||
|
|
@ -115,6 +116,7 @@ var plugin = function (args) {
|
|||
var lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
var useInputBitrate = args.inputs.useInputBitrate;
|
||||
var targetBitratePercent = String(args.inputs.targetBitratePercent);
|
||||
var fallbackBitrate = String(args.inputs.fallbackBitrate);
|
||||
|
|
|
|||
|
|
@ -39,6 +39,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
|
|||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.plugin = exports.details = void 0;
|
||||
var hardwareUtils_1 = require("../../../../FlowHelpers/1.0.0/hardwareUtils");
|
||||
var flowUtils_1 = require("../../../../FlowHelpers/1.0.0/interfaces/flowUtils");
|
||||
/* eslint-disable no-param-reassign */
|
||||
var details = function () { return ({
|
||||
name: 'Set Video Encoder',
|
||||
|
|
@ -217,6 +218,7 @@ var plugin = function (args) { return __awaiter(void 0, void 0, void 0, function
|
|||
lib = require('../../../../../methods/lib')();
|
||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars,no-param-reassign
|
||||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
(0, flowUtils_1.checkFfmpegCommandInit)(args);
|
||||
hardwareDecoding = args.inputs.hardwareDecoding === true;
|
||||
hardwareType = String(args.inputs.hardwareType);
|
||||
args.variables.ffmpegCommand.hardwareDecoding = hardwareDecoding;
|
||||
|
|
|
|||
|
|
@ -44,6 +44,7 @@ var plugin = function (args) {
|
|||
args.inputs = lib.loadDefaultValues(args.inputs, details);
|
||||
var container = (0, fileUtils_1.getContainer)(args.inputFileObj._id);
|
||||
var ffmpegCommand = {
|
||||
init: true,
|
||||
inputFiles: [],
|
||||
streams: JSON.parse(JSON.stringify(args.inputFileObj.ffProbeData.streams)).map(function (stream) { return (__assign(__assign({}, stream), { removed: false, mapArgs: [
|
||||
'-map',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue