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

Add transfer-functions and hdr-metadata to video-capabilities. #300

Merged
merged 4 commits into from
Nov 7, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 21 additions & 2 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1702,15 +1702,34 @@ following additional fields:
display could return this value as 1.6 to indicate its preferred content
scaling. Default is none.

Issue(194): Expose capabilities for decoding HDR transfer functions and metadata formats.

: color-gamuts (optional)
:: An optional field indicating what color spaces can be decoded and rendered by
the media receiver. The media sender may use these values to determine how
to encode video. Valid values correspond to [[MEDIA-CAPABILITIES#colorgamut|ColorGamut]]
in the [[!MEDIA-CAPABILITIES|Media Capabilities]] API. The default value is
a list with the single entry "srgb".

: hdr-formats (optional)
:: An optional field indicating what HDR transfer functions and metadata formats
can be decoded and rendered by the media receiver. Each `video-hdr-format`
consists of two fields, `transfer-function` and `hdr-metadata`.

The `transfer-function` field must be a valid
[[MEDIA-CAPABILITIES#transferfunction|TransferFunction]]
and the `hdr-metadata` field must be a valid
[[MEDIA-CAPABILITIES#hdrmetadatatype|HdrMetadataType]], both defined in the
[[!MEDIA-CAPABILITIES|Media Capabilities]] API.

If a `video-hdr-format` is provided with a `transfer-function` but no
`hdr-metadata`, then the media receiver can render the `transfer-function`
without any associated metadata. (This is the case, for example, with the
"hlg" `transfer-function`.)

The media receiver should ignore duplicate entries in `hdr-formats.`
If no `hdr-formats` are listed, then the media reciever cannot decode any
HDR formats.


: native-resolutions (optional)
:: An optional field indicating what video-resolutions the media receiver supports and
considers to be "native," meaning that scaling is not required.
Expand Down
6 changes: 6 additions & 0 deletions messages_appendix.cddl
Original file line number Diff line number Diff line change
Expand Up @@ -553,6 +553,11 @@ video-resolution = {
1: uint ; width
}

video-hdr-format = {
0: transfer-function ; string
1: ? hdr-metadata ; string
}

receive-video-capability = {
0: format ; codec
? 1: video-resolution ; max-resolution
Expand All @@ -564,6 +569,7 @@ receive-video-capability = {
? 7: [* video-resolution] ; native-resolutions
? 8: bool ; supports-scaling
? 9: bool ; supports-rotation
? 10: [* video-hdr-format] ; hdr-formats
}

receive-data-capability = {
Expand Down