aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/lib/transcoding/default-transcoding-profiles.ts
diff options
context:
space:
mode:
Diffstat (limited to 'server/lib/transcoding/default-transcoding-profiles.ts')
-rw-r--r--server/lib/transcoding/default-transcoding-profiles.ts16
1 files changed, 5 insertions, 11 deletions
diff --git a/server/lib/transcoding/default-transcoding-profiles.ts b/server/lib/transcoding/default-transcoding-profiles.ts
index f47718819..5251784ac 100644
--- a/server/lib/transcoding/default-transcoding-profiles.ts
+++ b/server/lib/transcoding/default-transcoding-profiles.ts
@@ -1,15 +1,9 @@
1 1
2import { logger } from '@server/helpers/logger' 2import { logger } from '@server/helpers/logger'
3import { getAverageBitrate, getMinLimitBitrate } from '@shared/core-utils' 3import { getAverageBitrate, getMinLimitBitrate } from '@shared/core-utils'
4import { AvailableEncoders, EncoderOptionsBuilder, EncoderOptionsBuilderParams, VideoResolution } from '../../../shared/models/videos' 4import { buildStreamSuffix, FFmpegCommandWrapper, ffprobePromise, getAudioStream, getMaxAudioBitrate } from '@shared/ffmpeg'
5import { 5import { AvailableEncoders, EncoderOptionsBuilder, EncoderOptionsBuilderParams, VideoResolution } from '@shared/models'
6 buildStreamSuffix, 6import { canDoQuickAudioTranscode } from './transcoding-quick-transcode'
7 canDoQuickAudioTranscode,
8 ffprobePromise,
9 getAudioStream,
10 getMaxAudioBitrate,
11 resetSupportedEncoders
12} from '../../helpers/ffmpeg'
13 7
14/** 8/**
15 * 9 *
@@ -184,14 +178,14 @@ class VideoTranscodingProfilesManager {
184 addEncoderPriority (type: 'vod' | 'live', streamType: 'audio' | 'video', encoder: string, priority: number) { 178 addEncoderPriority (type: 'vod' | 'live', streamType: 'audio' | 'video', encoder: string, priority: number) {
185 this.encodersPriorities[type][streamType].push({ name: encoder, priority }) 179 this.encodersPriorities[type][streamType].push({ name: encoder, priority })
186 180
187 resetSupportedEncoders() 181 FFmpegCommandWrapper.resetSupportedEncoders()
188 } 182 }
189 183
190 removeEncoderPriority (type: 'vod' | 'live', streamType: 'audio' | 'video', encoder: string, priority: number) { 184 removeEncoderPriority (type: 'vod' | 'live', streamType: 'audio' | 'video', encoder: string, priority: number) {
191 this.encodersPriorities[type][streamType] = this.encodersPriorities[type][streamType] 185 this.encodersPriorities[type][streamType] = this.encodersPriorities[type][streamType]
192 .filter(o => o.name !== encoder && o.priority !== priority) 186 .filter(o => o.name !== encoder && o.priority !== priority)
193 187
194 resetSupportedEncoders() 188 FFmpegCommandWrapper.resetSupportedEncoders()
195 } 189 }
196 190
197 private getEncodersByPriority (type: 'vod' | 'live', streamType: 'audio' | 'video') { 191 private getEncodersByPriority (type: 'vod' | 'live', streamType: 'audio' | 'video') {