]>
Commit | Line | Data |
---|---|---|
1896bca0 C |
1 | import { VideoResolution } from './video-resolution.enum' |
2 | ||
3 | // Types used by plugins and ffmpeg-utils | |
4 | ||
5 | export type EncoderOptionsBuilder = (params: { | |
6 | input: string | |
7 | resolution: VideoResolution | |
8 | fps?: number | |
9 | streamNum?: number | |
10 | }) => Promise<EncoderOptions> | EncoderOptions | |
11 | ||
12 | export interface EncoderOptions { | |
13 | copy?: boolean // Copy stream? Default to false | |
14 | ||
43f7a43c TLC |
15 | inputOptions?: string[] |
16 | videoFilters?: string[] | |
17 | outputOptions?: string[] | |
1896bca0 C |
18 | } |
19 | ||
20 | // All our encoders | |
21 | ||
22 | export interface EncoderProfile <T> { | |
23 | [ profile: string ]: T | |
24 | ||
25 | default: T | |
26 | } | |
27 | ||
28 | export type AvailableEncoders = { | |
29 | available: { | |
30 | live: { | |
31 | [ encoder: string ]: EncoderProfile<EncoderOptionsBuilder> | |
32 | } | |
33 | ||
34 | vod: { | |
35 | [ encoder: string ]: EncoderProfile<EncoderOptionsBuilder> | |
36 | } | |
37 | } | |
38 | ||
39 | encodersToTry: { | |
40 | vod: { | |
41 | video: string[] | |
42 | audio: string[] | |
43 | } | |
44 | ||
45 | live: { | |
46 | video: string[] | |
47 | audio: string[] | |
48 | } | |
49 | } | |
50 | } |