Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for Video Thumbnails #120

Open
rig-0 opened this issue Sep 30, 2021 · 1 comment
Open

Support for Video Thumbnails #120

rig-0 opened this issue Sep 30, 2021 · 1 comment
Labels
enhancement New feature or request

Comments

@rig-0
Copy link

rig-0 commented Sep 30, 2021

Summary

Support for Video Thumbnails (storing and retrieving)

Abstract

We (the Mobile Team) would like to see the spec support thumbnails for Video objects. If it is not included in the response, then it becomes the responsibility of all clients to implement thumbnail generation client-side, and this can be expensive (when scrolling through a grid of video thumbnails). Another consequence of client-side generation is that video thumbnails can be different app to app, platform to platform. We already generate video thumbnails before we submit posts, and can easily support uploading and submitting these urls as part of the Video Content Attachment request.

Specification

Potential sample spec that includes thumbnail:

  "@context": "https://www.w3.org/ns/activitystreams",
  "type": "Note",
  "attachments": [
    {
      "type": "Video",
      "name": "One of the founders of DSNP",
      "duration": "PT10M32S",
      "url": [
        {
          "type": "Link",
          "href": "https://upload.wikimedia.org/wikipedia/commons/c/c0/Big_Buck_Bunny_4K.webm",
          "width": 4000,
          "height": 2250,
          "mediaType": "video/webm",
          "hash": {
            "algorithm": "keccak256",
            "value": "0xf841950dfcedc968dbd63132da844b9f28faea3dbfd4cf326b3831b419a20e9a"
          }
        }
      ],
      "thumbnail": [
        {
          "type": "Image",
          "href": "https://upload.wikimedia.org/wikipedia/commons/a/ae/Mccourt.jpg",
          "width": 350,
          "height": 228,
          "mediaType": "image/jpg"
        }
      ]
    }
  ],
  "published": "1970-01-01T00:00:00+00:00"
}

(source: https://spec.dsnp.org/ActivityContent/Associated/Attachments#video )

FWIW: Here is YT API spec for Videos: https://developers.google.com/youtube/v3/docs/videos

Copyright

Copyright and related rights waived via CC0.

@rig-0 rig-0 added the enhancement New feature or request label Sep 30, 2021
@sebdomdev
Copy link

An additional benefit would be that users (that post a video) can choose the thumbnail themselves. This allows users (that see the post) to get a better impression of what the video is about.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants