1
0
Fork 0
peertube/shared/ffmpeg/ffmpeg-utils.ts
Chocobozzz 0c9668f779 Implement remote runner jobs in server
Move ffmpeg functions to @shared
2023-05-09 08:57:34 +02:00

17 lines
399 B
TypeScript

import { EncoderOptions } from '@shared/models'
export type StreamType = 'audio' | 'video'
export function buildStreamSuffix (base: string, streamNum?: number) {
if (streamNum !== undefined) {
return `${base}:${streamNum}`
}
return base
}
export function getScaleFilter (options: EncoderOptions): string {
if (options.scaleFilter) return options.scaleFilter.name
return 'scale'
}