aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models/activitypub
diff options
context:
space:
mode:
authorRigel Kent <sendmemail@rigelk.eu>2020-03-10 14:39:40 +0100
committerGitHub <noreply@github.com>2020-03-10 14:39:40 +0100
commit8319d6ae72d4da6de51bd3d4b5c68040fc8dc3b4 (patch)
tree1f87041b2cd76222844960602cdc9f52fe206c7b /shared/models/activitypub
parentedb868655e52f934a71141175cf9dc6cb4753e11 (diff)
downloadPeerTube-8319d6ae72d4da6de51bd3d4b5c68040fc8dc3b4.tar.gz
PeerTube-8319d6ae72d4da6de51bd3d4b5c68040fc8dc3b4.tar.zst
PeerTube-8319d6ae72d4da6de51bd3d4b5c68040fc8dc3b4.zip
Add video file metadata to download modal, via ffprobe (#2411)
* Add video file metadata via ffprobe * Federate video file metadata * Add tests for file metadata generation * Complete tests for videoFile metadata federation * Lint migration and video-file for metadata * Objectify metadata from getter in ffmpeg-utils * Add metadataUrl to all videoFiles * Simplify metadata API middleware * Load playlist in videoFile when requesting metadata
Diffstat (limited to 'shared/models/activitypub')
-rw-r--r--shared/models/activitypub/objects/common-objects.ts11
1 files changed, 11 insertions, 0 deletions
diff --git a/shared/models/activitypub/objects/common-objects.ts b/shared/models/activitypub/objects/common-objects.ts
index e94d05429..bb3ffe678 100644
--- a/shared/models/activitypub/objects/common-objects.ts
+++ b/shared/models/activitypub/objects/common-objects.ts
@@ -28,6 +28,15 @@ export type ActivityPlaylistSegmentHashesObject = {
28 href: string 28 href: string
29} 29}
30 30
31export type ActivityVideoFileMetadataObject = {
32 type: 'Link'
33 rel: [ 'metadata', any ]
34 mediaType: 'application/json'
35 height: number
36 href: string
37 fps: number
38}
39
31export type ActivityPlaylistInfohashesObject = { 40export type ActivityPlaylistInfohashesObject = {
32 type: 'Infohash' 41 type: 'Infohash'
33 name: string 42 name: string
@@ -80,6 +89,7 @@ export type ActivityTagObject =
80 | ActivityMentionObject 89 | ActivityMentionObject
81 | ActivityBitTorrentUrlObject 90 | ActivityBitTorrentUrlObject
82 | ActivityMagnetUrlObject 91 | ActivityMagnetUrlObject
92 | ActivityVideoFileMetadataObject
83 93
84export type ActivityUrlObject = 94export type ActivityUrlObject =
85 ActivityVideoUrlObject 95 ActivityVideoUrlObject
@@ -87,6 +97,7 @@ export type ActivityUrlObject =
87 | ActivityBitTorrentUrlObject 97 | ActivityBitTorrentUrlObject
88 | ActivityMagnetUrlObject 98 | ActivityMagnetUrlObject
89 | ActivityHtmlUrlObject 99 | ActivityHtmlUrlObject
100 | ActivityVideoFileMetadataObject
90 101
91export interface ActivityPubAttributedTo { 102export interface ActivityPubAttributedTo {
92 type: 'Group' | 'Person' 103 type: 'Group' | 'Person'