aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/helpers
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-03-19 15:02:36 +0100
committerChocobozzz <me@florianbigard.com>2018-03-19 15:22:18 +0100
commita797728009eb5c26cf55624a4a01e8ecb73f1297 (patch)
tree3dcfe4870986c9bacdfbd2a671143b5dfc4f47d3 /server/helpers
parent9d145133d82c11edfb2781871076b7063cc3ae3d (diff)
downloadPeerTube-a797728009eb5c26cf55624a4a01e8ecb73f1297.tar.gz
PeerTube-a797728009eb5c26cf55624a4a01e8ecb73f1297.tar.zst
PeerTube-a797728009eb5c26cf55624a4a01e8ecb73f1297.zip
Fix video_share_url duplicate key in transcoding job
Diffstat (limited to 'server/helpers')
-rw-r--r--server/helpers/ffmpeg-utils.ts6
1 files changed, 4 insertions, 2 deletions
diff --git a/server/helpers/ffmpeg-utils.ts b/server/helpers/ffmpeg-utils.ts
index 4f75ba5a8..4d6cd3a82 100644
--- a/server/helpers/ffmpeg-utils.ts
+++ b/server/helpers/ffmpeg-utils.ts
@@ -1,7 +1,7 @@
1import * as ffmpeg from 'fluent-ffmpeg' 1import * as ffmpeg from 'fluent-ffmpeg'
2import { join } from 'path' 2import { join } from 'path'
3import { VideoResolution } from '../../shared/models/videos' 3import { VideoResolution } from '../../shared/models/videos'
4import { CONFIG, MAX_VIDEO_TRANSCODING_FPS } from '../initializers' 4import { CONFIG, VIDEO_TRANSCODING_FPS } from '../initializers'
5import { unlinkPromise } from './core-utils' 5import { unlinkPromise } from './core-utils'
6import { processImage } from './image-utils' 6import { processImage } from './image-utils'
7import { logger } from './logger' 7import { logger } from './logger'
@@ -92,7 +92,9 @@ function transcode (options: TranscodeOptions) {
92 .outputOption('-movflags faststart') 92 .outputOption('-movflags faststart')
93 // .outputOption('-crf 18') 93 // .outputOption('-crf 18')
94 94
95 if (fps > MAX_VIDEO_TRANSCODING_FPS) command = command.withFPS(MAX_VIDEO_TRANSCODING_FPS) 95 // Our player has some FPS limits
96 if (fps > VIDEO_TRANSCODING_FPS.MAX) command = command.withFPS(VIDEO_TRANSCODING_FPS.MAX)
97 else if (fps < VIDEO_TRANSCODING_FPS.MIN) command = command.withFPS(VIDEO_TRANSCODING_FPS.MIN)
96 98
97 if (options.resolution !== undefined) { 99 if (options.resolution !== undefined) {
98 // '?x720' or '720x?' for example 100 // '?x720' or '720x?' for example