aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib/transcoding/create-transcoding-job.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/lib/transcoding/create-transcoding-job.ts')
-rw-r--r--server/lib/transcoding/create-transcoding-job.ts37
1 files changed, 0 insertions, 37 deletions
diff --git a/server/lib/transcoding/create-transcoding-job.ts b/server/lib/transcoding/create-transcoding-job.ts
deleted file mode 100644
index d78e68b87..000000000
--- a/server/lib/transcoding/create-transcoding-job.ts
+++ /dev/null
@@ -1,37 +0,0 @@
1import { CONFIG } from '@server/initializers/config'
2import { MUserId, MVideoFile, MVideoFullLight } from '@server/types/models'
3import { TranscodingJobQueueBuilder, TranscodingRunnerJobBuilder } from './shared'
4
5export function createOptimizeOrMergeAudioJobs (options: {
6 video: MVideoFullLight
7 videoFile: MVideoFile
8 isNewVideo: boolean
9 user: MUserId
10 videoFileAlreadyLocked: boolean
11}) {
12 return getJobBuilder().createOptimizeOrMergeAudioJobs(options)
13}
14
15// ---------------------------------------------------------------------------
16
17export function createTranscodingJobs (options: {
18 transcodingType: 'hls' | 'webtorrent' | 'web-video' // TODO: remove webtorrent in v7
19 video: MVideoFullLight
20 resolutions: number[]
21 isNewVideo: boolean
22 user: MUserId
23}) {
24 return getJobBuilder().createTranscodingJobs(options)
25}
26
27// ---------------------------------------------------------------------------
28// Private
29// ---------------------------------------------------------------------------
30
31function getJobBuilder () {
32 if (CONFIG.TRANSCODING.REMOTE_RUNNERS.ENABLED === true) {
33 return new TranscodingRunnerJobBuilder()
34 }
35
36 return new TranscodingJobQueueBuilder()
37}