aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/videos/live
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-03-04 13:40:02 +0100
committerChocobozzz <chocobozzz@cpy.re>2022-03-09 09:23:10 +0100
commitf443a74649174b2f9347c158e30f8ac7aa3e958a (patch)
treee423bc4e2307477bda4341037b7fa04ad10adae6 /shared/models/videos/live
parent01dd04cd5ab7b55d2a9af7d0ebf405bee9579b09 (diff)
downloadPeerTube-f443a74649174b2f9347c158e30f8ac7aa3e958a.tar.gz
PeerTube-f443a74649174b2f9347c158e30f8ac7aa3e958a.tar.zst
PeerTube-f443a74649174b2f9347c158e30f8ac7aa3e958a.zip
Add latency setting support
Diffstat (limited to 'shared/models/videos/live')
-rw-r--r--shared/models/videos/live/index.ts1
-rw-r--r--shared/models/videos/live/live-video-create.model.ts2
-rw-r--r--shared/models/videos/live/live-video-latency-mode.enum.ts5
-rw-r--r--shared/models/videos/live/live-video-update.model.ts3
-rw-r--r--shared/models/videos/live/live-video.model.ts4
5 files changed, 15 insertions, 0 deletions
diff --git a/shared/models/videos/live/index.ts b/shared/models/videos/live/index.ts
index a36f42a7d..68f32092a 100644
--- a/shared/models/videos/live/index.ts
+++ b/shared/models/videos/live/index.ts
@@ -1,5 +1,6 @@
1export * from './live-video-create.model' 1export * from './live-video-create.model'
2export * from './live-video-event-payload.model' 2export * from './live-video-event-payload.model'
3export * from './live-video-event.type' 3export * from './live-video-event.type'
4export * from './live-video-latency-mode.enum'
4export * from './live-video-update.model' 5export * from './live-video-update.model'
5export * from './live-video.model' 6export * from './live-video.model'
diff --git a/shared/models/videos/live/live-video-create.model.ts b/shared/models/videos/live/live-video-create.model.ts
index caa7acc17..49ccaf45b 100644
--- a/shared/models/videos/live/live-video-create.model.ts
+++ b/shared/models/videos/live/live-video-create.model.ts
@@ -1,6 +1,8 @@
1import { LiveVideoLatencyMode } from '.'
1import { VideoCreate } from '../video-create.model' 2import { VideoCreate } from '../video-create.model'
2 3
3export interface LiveVideoCreate extends VideoCreate { 4export interface LiveVideoCreate extends VideoCreate {
4 saveReplay?: boolean 5 saveReplay?: boolean
5 permanentLive?: boolean 6 permanentLive?: boolean
7 latencyMode?: LiveVideoLatencyMode
6} 8}
diff --git a/shared/models/videos/live/live-video-latency-mode.enum.ts b/shared/models/videos/live/live-video-latency-mode.enum.ts
new file mode 100644
index 000000000..4285e1d41
--- /dev/null
+++ b/shared/models/videos/live/live-video-latency-mode.enum.ts
@@ -0,0 +1,5 @@
1export const enum LiveVideoLatencyMode {
2 DEFAULT = 1,
3 HIGH_LATENCY = 2,
4 SMALL_LATENCY = 3
5}
diff --git a/shared/models/videos/live/live-video-update.model.ts b/shared/models/videos/live/live-video-update.model.ts
index a39c44797..93bb4d30d 100644
--- a/shared/models/videos/live/live-video-update.model.ts
+++ b/shared/models/videos/live/live-video-update.model.ts
@@ -1,4 +1,7 @@
1import { LiveVideoLatencyMode } from './live-video-latency-mode.enum'
2
1export interface LiveVideoUpdate { 3export interface LiveVideoUpdate {
2 permanentLive?: boolean 4 permanentLive?: boolean
3 saveReplay?: boolean 5 saveReplay?: boolean
6 latencyMode?: LiveVideoLatencyMode
4} 7}
diff --git a/shared/models/videos/live/live-video.model.ts b/shared/models/videos/live/live-video.model.ts
index 815a93804..2d3169941 100644
--- a/shared/models/videos/live/live-video.model.ts
+++ b/shared/models/videos/live/live-video.model.ts
@@ -1,8 +1,12 @@
1import { LiveVideoLatencyMode } from './live-video-latency-mode.enum'
2
1export interface LiveVideo { 3export interface LiveVideo {
2 rtmpUrl: string 4 rtmpUrl: string
3 rtmpsUrl: string 5 rtmpsUrl: string
4 6
5 streamKey: string 7 streamKey: string
8
6 saveReplay: boolean 9 saveReplay: boolean
7 permanentLive: boolean 10 permanentLive: boolean
11 latencyMode: LiveVideoLatencyMode
8} 12}