-
Notifications
You must be signed in to change notification settings - Fork 115
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
Store videos in different qualities, audio-only version #3806
Comments
I think this is a great idea, but I think this is a big project, which has two distinct parts we should tackle separately, both in order to learn as we go, but also unlock some incremental benefits earlier.
Unlocking nr. 2 first makes a great deal of sense because
So perhaps you can make an issue for just unlocking 2 first, where you describe full set of changes you believe will need to be done to
Be as detailed as possible, so as to make it possible to review before we start any sort of execution on this. Things I am particularly interested in
|
Well, the on-chain db in particular the content pallet model wasn't designed with this feature in mind (assets 1:1 files, not 1:n) and it is unlikely a change like the placeholder #3861 will come anytime soon. On top of that there can be services (GW) that 1) transcode them into additional formats 2) host an index of those 3) cut them into equal minute-long pieces according to DASH and 4) make them accessible via an API for a profit.
Combining those incentives might pay off extra service fees to be able to offer additional device-specific formats. That way end-user GW pay another GW to offer (all / specific) assets in the optimal format / time-slice. We could try to determine costs of such an approach via bounties. |
Content pallet is quite transparent when it comes to that and we can easily support multiple resolutions for a single video without any runtime changes. Chain already allows you to specify any number of files (data objects) to be created alongside a video. It's only a matter of updating the metadata protobuf definitions for |
That's great news. metadata protobuf is a scary term though, you'll need to teach the community how to do that :) |
When you create a video or a channel, one of the extrinsic args is Here is our And here is an example usage in Atlas: https://github.com/Joystream/atlas/blob/carthage/packages/atlas/src/joystream-lib/metadata.ts#L75 |
Runtime update to support multiple versions per video assets to increase compatibility (encoding, bitrate, audio/video only) and possible applications like podcasts, kiosk mode, skimming, etc.
Rationale
The Joystream CDN currently is bitrate agnostic and does not reprocess for example very high definition videos for consumption via mobile devices or users with slow connection:
Status Quo
Query to fetch duration, size and codec for videos:
This shows video bitrate for actual video files:
Scope
Store uploaded videos in known YT qualities, starting with possibly most common 144p and 720p.
Processing
This is the easy tho time consuming part.
Which actors can be trusted to reprocess all videos?
Workflow
draft to figure out which role gateways would play in this
There can be multiple JPS and they could be regional Gateway Providers that also take care of other obligations on the way based on local laws (KYC, content screening, IP/ copyright checks).
In any way the chain needs to be able to link multiple media assets to one video. Ideally rather short-term (or at least before mainnet) to give possible investors time to develop their infrastructure around that. Also for auditing which is on the way for other features already and takes time.
RICE estimates
Gateway ideas
Downside of leaving this to off-chain internal Gateway processes may defeat CDN advantages to store and distribute different versions per bag and asset.
Storage
Open questions:
=> update storage system to be able to save multiple versions per "video"
=> update QN support needed queries for consumer apps (available versions with bitrate by asset id)
Discussion
July 2021
First discussed In July 21 Operations was asked to look into client side transcoding.
Nov 2021
Dec 2021
May 2022
Lately discussed here suggesting the DASH concept to switch bitrate.
The text was updated successfully, but these errors were encountered: