├── .gitignore ├── .pr-preview.json ├── w3c.json ├── LICENSE.md ├── CODE_OF_CONDUCT.md ├── README.md ├── .github └── workflows │ └── auto-publish.yml ├── CONTRIBUTING.md ├── images ├── L1T1.svg ├── L1T2.svg ├── S2T1.svg ├── L2T1_KEY.svg ├── S2T2.svg ├── L2T2_KEY.svg ├── L1T3.svg ├── L2T1.svg ├── L2T2_KEY_SHIFT.svg ├── L2T2.svg ├── S3T1.svg ├── L3T1_KEY.svg ├── S3T2.svg ├── L3T2_KEY.svg ├── L3T2_KEY_SHIFT.svg ├── L3T1.svg ├── L3T2.svg ├── S2T3.svg ├── L2T3_KEY.svg ├── L2T3_KEY_SHIFT.svg ├── L2T3.svg ├── S3T3.svg ├── L3T3_KEY.svg ├── L3T3_KEY_SHIFT.svg └── L3T3.svg ├── webrtc.css ├── svc-respec-config.js ├── explainer.md └── index.html /.gitignore: -------------------------------------------------------------------------------- 1 | *~ 2 | .DS_Store 3 | build 4 | support 5 | webrtc-respec-ci 6 | -------------------------------------------------------------------------------- /.pr-preview.json: -------------------------------------------------------------------------------- 1 | { 2 | "src_file": "index.html", 3 | "type": "respec" 4 | } 5 | 6 | -------------------------------------------------------------------------------- /w3c.json: -------------------------------------------------------------------------------- 1 | { 2 | "group": 47318 3 | , "contacts": ["dontcallmedom", "caribouW3"] 4 | , "repo-type": "rec-track" 5 | } 6 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | All documents in this Repository are licensed by contributors 2 | under the 3 | [W3C Software and Document License](https://www.w3.org/Consortium/Legal/copyright-software). 4 | 5 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Code of Conduct 2 | 3 | All documentation, code and communication under this repository are covered by the [W3C Code of Ethics and Professional Conduct](https://www.w3.org/Consortium/cepc/). 4 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | ## WebRTC-SVC 2 | 3 | This document defines a set of ECMAScript APIs in WebIDL to extend the WebRTC 1.0 4 | API to enable support for Scalable Video Coding (SVC). 5 | 6 | ### Published Versions 7 | 8 | The editors' draft is the tip-of-tree of this document, it may contain work in 9 | progress changes and other inconsistencies, including an incomplete change log. 10 | 11 | * [Latest editor's draft at github](https://w3c.github.io/webrtc-svc/) 12 | 13 | ### Useful Links 14 | 15 | The content of this document is discussed at the 16 | [public-webrtc](https://lists.w3.org/Archives/Public/public-webrtc/) 17 | mailing list. 18 | 19 | [Contribution Guidelines](CONTRIBUTING.md) 20 | -------------------------------------------------------------------------------- /.github/workflows/auto-publish.yml: -------------------------------------------------------------------------------- 1 | name: Validate and Auto Publish 2 | 3 | on: 4 | push: 5 | branches: 6 | - main 7 | pull_request: {} 8 | 9 | jobs: 10 | validate-and-publish: 11 | name: Validate and Publish 12 | runs-on: ubuntu-latest # only linux supported at present 13 | steps: 14 | - uses: actions/checkout@v2 15 | - uses: w3c/spec-prod@v2 # use the action 16 | with: 17 | W3C_ECHIDNA_TOKEN: ${{ secrets.ECHIDNA_TOKEN }} 18 | W3C_WG_DECISION_URL: "https://lists.w3.org/Archives/Public/public-webrtc/2016Mar/0031.html" 19 | W3C_NOTIFICATIONS_CC: "dom@w3.org" 20 | VALIDATE_LINKS: false 21 | W3C_BUILD_OVERRIDE: | 22 | specStatus: WD 23 | shortName: webrtc-svc 24 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | Contributions to this repository are intended to become part of Recommendation-track documents governed by the 2 | [W3C Patent Policy](https://www.w3.org/Consortium/Patent-Policy/) and 3 | [Software and Document License](https://www.w3.org/Consortium/Legal/copyright-software). To make substantive contributions to specifications, you must either participate 4 | in the relevant W3C Working Group or make a non-member patent licensing commitment. 5 | 6 | If you are not the sole contributor to a contribution (pull request), please identify all 7 | contributors in the pull request comment. 8 | 9 | To add a contributor (other than yourself, that's automatic), mark them one per line as follows: 10 | 11 | ``` 12 | +@github_username 13 | ``` 14 | 15 | If you added a contributor by mistake, you can remove them in a comment with: 16 | 17 | ``` 18 | -@github_username 19 | ``` 20 | 21 | If you are making a pull request on behalf of someone else but you had no part in designing the 22 | feature, you can remove yourself with the above syntax. 23 | -------------------------------------------------------------------------------- /images/L1T1.svg: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /images/L1T2.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/S2T1.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /webrtc.css: -------------------------------------------------------------------------------- 1 | @media screen { 2 | html { background: #eeeeee; } 3 | body { margin-bottom: 30%; border-bottom: thin solid #3c790a; } 4 | } 5 | 6 | pre { margin-left: 2em; white-space: pre-wrap; } 7 | dt, dfn { font-weight: bold; font-style: normal; } 8 | i, em, dt dfn { font-style: italic; } 9 | pre, code { font-size: inherit; font-family: monospace, Droid Sans Fallback, sans-serif; font-variant: normal; } 10 | pre strong { color: black; font: inherit; font-weight: bold; background: yellow; } 11 | pre em { font-weight: bolder; font-style: normal; } 12 | @media screen { code { color: orange; } } 13 | var sub { vertical-align: bottom; font-size: smaller; position: relative; top: 0.1em; } 14 | table { border-collapse: collapse; border-style: hidden hidden none hidden; } 15 | table thead, table tbody { border-bottom: solid; } 16 | table tbody th { text-align: left; } 17 | table tbody th:first-child { border-left: solid; } 18 | table td, table th { border-left: solid; border-right: solid; border-bottom: solid thin; vertical-align: top; padding: 0.2em; } 19 | 20 | ins { background: green; color: white; /* color: green; border: solid thin lime; padding: 0.3em; line-height: 1.6em; */ text-decoration: none; } 21 | del { background: maroon; color: white; /* color: maroon; border: solid thin red; padding: 0.3em; line-height: 1.6em; */ text-decoration: line-through; } 22 | body ins, body del { display: block; } 23 | body * ins, body * del { display: inline; } 24 | 25 | 26 | li > span:not([title=""]):not([class="XXX"]):not([class="impl"]):not([class="note"]) { border-bottom: solid #99CC99; } 27 | 28 | .note { color: green; background: transparent; font-family: sans-serif, Droid Sans Fallback; } 29 | .warning { color: red; background: transparent; } 30 | .note, .warning { font-weight: bolder; font-style: italic; } 31 | .note em, .warning em, .note i, .warning i { font-style: normal; } 32 | p.note, div.note { padding: 0.5em 2em; } 33 | span.note { padding: 0 2em; } 34 | .note p:first-child, .warning p:first-child { margin-top: 0; } 35 | .note p:last-child, .warning p:last-child { margin-bottom: 0; } 36 | .warning:before { font-style: normal; } 37 | p.note:before { content: 'Note: '; } 38 | p.warning:before { content: '\26A0 Warning! '; } 39 | 40 | .bookkeeping:before { display: block; content: 'Bookkeeping details'; font-weight: bolder; font-style: italic; } 41 | .bookkeeping { font-size: 0.8em; margin: 2em 0; } 42 | .bookkeeping p { margin: 0.5em 2em; display: list-item; list-style: square; } 43 | .bookkeeping dt { margin: 0.5em 2em 0; } 44 | .bookkeeping dd { margin: 0 3em 0.5em; } 45 | 46 | .critical { margin: 1em; border: double thick red; padding: 1em; background: #FFFFCC; } 47 | .critical > :first-child { margin-top: 0; } 48 | 49 | .example { display: block; color: #222222; background: #FCFCFC; border-left: double; margin-left: 2em; padding-left: 1em; } 50 | td > .example:only-child { margin: 0 0 0 0.1em; } 51 | .rfc2119 { font-variant: small-caps;} -------------------------------------------------------------------------------- /images/L2T1_KEY.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/S2T2.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L2T2_KEY.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L1T3.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L2T1.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L2T2_KEY_SHIFT.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L2T2.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /svc-respec-config.js: -------------------------------------------------------------------------------- 1 | var respecConfig = { 2 | specStatus: "ED", 3 | // if there a publicly available Editor's Draft, this is the link 4 | edDraftURI: "https://w3c.github.io/webrtc-svc/", 5 | shortName: "webrtc-svc", 6 | editors: [ 7 | // { name: "Your Name", url: "http://example.org/", 8 | // company: "Your Company", companyURL: "http://example.com/" }, 9 | { name: "Bernard Aboba", company: "Microsoft Corporation", 10 | w3cid: "65611" 11 | } 12 | ], 13 | formerEditors: [ 14 | { name: "Peter Thatcher", company: "Microsoft Corporation", w3cid: "68236", retiredDate: "2019-12-31" } 15 | ], 16 | authors: [ 17 | ], 18 | group: "webrtc", 19 | wgPublicList: "public-webrtc", 20 | xref: ["webidl", "webrtc", "media-capabilities", "infra"], 21 | github: "https://github.com/w3c/webrtc-svc", 22 | otherLinks: [ 23 | { 24 | key: "Participate", 25 | data: [ 26 | { 27 | value: "Mailing list", 28 | href: "https://lists.w3.org/Archives/Public/public-webrtc/" 29 | }, 30 | { 31 | "value": "IETF AVTCORE Working Group", 32 | "href": "https://datatracker.ietf.org/wg/avtcore/documents/" 33 | } 34 | ] 35 | } 36 | ], 37 | localBiblio: { 38 | "IANA-STUN-6": { 39 | "title": "STUN Error Codes", 40 | "href": "https://www.iana.org/assignments/stun-parameters/stun-parameters.xhtml#stun-parameters-6", 41 | "publisher": "IANA" 42 | }, 43 | "ITU-T-REC-H.264": { 44 | "href": "https://www.itu.int/rec/T-REC-H.264", 45 | "title": "H.264 : Advanced video coding for generic audiovisual services", 46 | "publisher": "ITU", 47 | "date": "June 2019" 48 | }, 49 | "ITU-T-REC-H.265": { 50 | "href": "https://www.itu.int/rec/T-REC-H.265", 51 | "title": "H.265 : High efficiency video coding", 52 | "publisher": "ITU", 53 | "date": "August 2021" 54 | }, 55 | "RFC7667": { 56 | "title": "RTP Topologies", 57 | "href": "https://datatracker.ietf.org/doc/html/rfc7667", 58 | "authors": [ 59 | "M. Westerlund", 60 | "S. Wenger" 61 | ], 62 | "status": "November 2015. RFC", 63 | "publisher": "IETF" 64 | }, 65 | "LRR": { 66 | "title": "The Layer Refresh Request (LRR) RTCP Feedback Message", 67 | "href": "https://datatracker.ietf.org/doc/html/draft-ietf-avtext-lrr", 68 | "authors": [ 69 | "J. Lennox", 70 | "D. Hong", 71 | "J. Uberti", 72 | "S. Holmer", 73 | "M. Flodman" 74 | ], 75 | "status": "29 June 2017. Internet Draft (work in progress)", 76 | "publisher": "IETF" 77 | }, 78 | "VP9": { 79 | "title": "VP9 Bitstream & Decoding Process Specification", 80 | "href": "https://storage.googleapis.com/downloads.webmproject.org/docs/vp9/vp9-bitstream-specification-v0.6-20160331-draft.pdf", 81 | "authors": [ 82 | "A. Grange", 83 | "P. de Rivaz", 84 | "J. Hunt" 85 | ], 86 | "status": "February 2016. Version 0.6", 87 | "publisher": "Google" 88 | }, 89 | "VP9-PAYLOAD": { 90 | "title": "RTP Payload Format for VP9 Video", 91 | "href": "https://datatracker.ietf.org/doc/html/draft-ietf-payload-vp9", 92 | "authors": [ 93 | "J. Uberti", 94 | "S. Holmer", 95 | "M. Flodman", 96 | "J. Lennox", 97 | "D. Hong" 98 | ], 99 | "status": "10 June 2021. Internet Draft (work in progress)", 100 | "publisher": "IETF" 101 | } 102 | } 103 | } 104 | -------------------------------------------------------------------------------- /images/S3T1.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L3T1_KEY.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/S3T2.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L3T2_KEY.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L3T2_KEY_SHIFT.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L3T1.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L3T2.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /explainer.md: -------------------------------------------------------------------------------- 1 | # WebRTC-SVC Explainer 2 | 3 | Updated: July 2019 4 | 5 | ## Problem and Motivation 6 | 7 | Scalable Video Coding (SVC) is increasingly used in realtime communications 8 | applications because of the performance and reliability advantages it offers. 9 | Today SVC is supported within WebRTC implementations using proprietary 10 | mechanisms and as a result, it is not possible to write web applications 11 | supporting SVC that interoperate on multiple browsers. 12 | 13 | We believe that there is a need for a simple mechanism to extend the WebRTC API 14 | to allow an application to discover the SVC capabilities of supported video 15 | codecs as well as to configure an encoder to utilize SVC. 16 | 17 | ## Goals 18 | 19 | - To extend WebRTC's RTCRtpCodecCapability dictionary to allow an application 20 | to discover the supported SVC modalities (known as scalabiltyModes) for each 21 | video codec. 22 | 23 | - To extend WebRTC's RTCRtpEncodingParameters dictionary to enable an 24 | application to configure an RTCRtpSender with the scalabilityMode of each 25 | video stream to be sent, as well as to retrieve the scalabilityMode of 26 | each video stream that is being sent. 27 | 28 | ## Non-goals 29 | 30 | - To enable differential robustness, where retransmission, forward error 31 | correction or redundant coding is applied to some scalability layers 32 | but not others. 33 | 34 | ## Outstanding issues 35 | 36 | - Whether to enable spatial scalability to utilize encoding parameters so 37 | to achieve feature parity with simulcast, as explained in Issue 38 | https://github.com/w3c/webrtc-svc/issues/14 39 | 40 | ## Key use-cases 41 | 42 | - Centralized video conferencing. 43 | 44 | ## Proposed solutions 45 | 46 | 1. Addition of a scalabilityModes attribute to the RTCRtpCodecCapability dictionary. 47 | 2. Addition of a scalabilityMode attribute to the RTCRtpEncodingParameters dictionary. 48 | 49 | ## Example of setting a scalabilityMode 50 | 51 | ```javascript 52 | // Example of 3 spatial simulcast layers + 3 temporal layers 53 | var encodings = [ 54 | {rid: 'f', scalabilityMode: 'L1T3'}, 55 | {rid: 'h', scaleResolutionDownBy: 2.0, scalabilityMode: 'L1T3'}, 56 | {rid: 'q', scaleResolutionDownBy: 4.0, scalabilityMode: 'L1T3'} 57 | ]; 58 | 59 | // Example of 2 spatial layers (with 2:1 ratio) + 3 temporal layers 60 | var encodings = [ 61 | {scalabilityMode: 'L2T3'} 62 | ]; 63 | 64 | ``` 65 | 66 | ## Example of discovering the scalabilityModes on a Scalable Forwarding Unit (SFU) 67 | 68 | ```javascript 69 | // RTCRtpReceiver.getCapabilities('video').codecs[] returned by 70 | // SFU that can only forward VP8 and VP9 temporal scalability modes 71 | "codecs": [ 72 | { 73 | "clockRate": 90000, 74 | "mimeType": "video/VP8", 75 | "scalabilityModes": ["L1T2","L1T3"] 76 | }, 77 | { 78 | "clockRate": 90000, 79 | "mimeType": "video/VP9", 80 | "scalabilityModes": ["L1T2","L1T3","L1T2h","L1T3h"] 81 | } 82 | ] 83 | ``` 84 | 85 | ## Example of discovering the scalabilityModes on a sender 86 | ```javascript 87 | 88 | // Capabilities returned by RTCRtpSender.getCapabilities('video').codecs[] 89 | "codecs": [ 90 | { 91 | "clockRate": 90000, 92 | "mimeType": "video/VP8", 93 | "scalabilityModes": ["L1T2","L1T3"] 94 | }, 95 | { 96 | "clockRate": 90000, 97 | "mimeType": "video/rtx", 98 | "sdpFmtpLine": "apt=96" 99 | }, 100 | { 101 | "clockRate": 90000, 102 | "mimeType": "video/VP9", 103 | "scalabilityModes": ["L1T2","L1T3","L2T1","L2T2","L2T3","L3T1","L3T2","L3T3","L1T2h","L1T3h","L2T1h","L2T2h","L2T3h","L3T1h","L3T2h","L3T3h"] 104 | }, 105 | { 106 | "clockRate": 90000, 107 | "mimeType": "video/rtx", 108 | "sdpFmtpLine": "apt=98" 109 | }, 110 | { 111 | "clockRate": 90000, 112 | "mimeType": "video/AV1", 113 | "scalabilityModes": ["L1T2","L1T3","L2T1","L2T2","L2T3","L3T1","L3T2","L3T3","L1T2h","L1T3h","L2T1h","L2T2h","L2T3h","L3T1h","L3T2h","L3T3h","S2T1","S2T2","S2T3","S3T1","S3T2","S3T3","S2T1h","S2T2h","S2T3h","S3T1h","S3T2h","S3T3h"] 114 | }, 115 | { 116 | "clockRate": 90000, 117 | "mimeType": "video/rtx", 118 | "sdpFmtpLine": "apt=100" 119 | } 120 | ] 121 | ``` 122 | 123 | ## WPT tests 124 | A sample WPT test is here: https://chromium.googlesource.com/chromium/src/+/f2e338d626fbb80ac9cd10d0d8200a4323d15c4d/third_party/blink/web_tests/external/wpt/webrtc-svc/RTCRtpParameters-scalability.html 125 | 126 | ## Detailed design discussion 127 | 128 | This proposal has evolved from the approach to SVC support provided in the ORTC API. 129 | 130 | - Developers utilizing the ORTC SVC APIs indicated that while it achieved feature 131 | parity with simulcast (e.g. ability to active/inactivate layers and handle arbitrary 132 | scale ratios), the API was complex and error prone and also could not express KEY 133 | and KEY_SHIFT modes. 134 | 135 | As a result of this feedback, a new proposal was developed, focussing on pre-canned 136 | scalability structures known as scalability modes. 137 | -------------------------------------------------------------------------------- /images/S2T3.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L2T3_KEY.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L2T3_KEY_SHIFT.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L2T3.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/S3T3.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L3T3_KEY.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L3T3_KEY_SHIFT.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /images/L3T3.svg: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 |
4 | 5 | 6 |13 | This document defines a set of ECMAScript APIs in WebIDL to extend the WebRTC 14 | specification to enable configuration of encoding parameters for Scalable 15 | Video Coding (SVC). Discovery of SVC encoder and decoder capabilities is 16 | handled by the Media Capabilities specification. 17 |
18 |21 | The API is based on preliminary work done in the W3C ORTC Community Group. 22 |
23 |27 | This specification extends the WebRTC specification [[WEBRTC]] to 28 | enable configuration of encoding parameters for Scalable Video 29 | Coding (SVC). Discovery of SVC encoder and decoder capabilities is 30 | handled by the Media Capabilities API [[?Media-Capabilities]]. 31 |
32 |33 | This specification does not change the behavior of WebRTC objects and 34 | methods. Therefore, restrictions relating to Offer/Answer negotiation and 35 | encoding parameters remain, as described in [[WEBRTC]] Section 5.2: 36 | "{{RTCRtpSender/setParameters()}} does not cause SDP renegotiation and can 37 | only be used to change what the media stack is sending or receiving within the 38 | envelope negotiated by Offer/Answer." 39 |
40 |41 | As a result, this specification can configure encoding parameters for 42 | codecs that do not negotiate SVC support in Offer/Answer, such as the 43 | VP8 [[?RFC6386]], VP9 [[?VP9]] and AV1 [[?AV1]] codecs. 44 | Configuraton of temporal scalability can also be supported 45 | for the H.264 [[?ITU-T-REC-H.264]] and H.265 [[?ITU-T-REC-H.265]] codecs. 46 |
47 |50 | This specification defines conformance criteria that apply to a single 51 | product: the user agent that implements the interfaces that it 52 | contains. 53 |
54 |55 | Conformance requirements phrased as algorithms or specific steps may be 56 | implemented in any manner, so long as the end result is equivalent. In 57 | particular, the algorithms defined in this specification are intended to be 58 | easy to follow, and not intended to be performant. 59 |
60 |61 | Implementations that use ECMAScript to implement the APIs defined in 62 | this specification MUST implement them in a manner consistent with the 63 | ECMAScript Bindings defined in the Web IDL specification [[WEBIDL]], as 64 | this specification uses that specification and terminology. 65 |
66 |70 | The term "simulcast envelope" is defined in [[!WEBRTC]] Section 5.4.1. 71 |
72 |73 | This specification references objects, methods, internal slots 74 | and dictionaries defined in [[!WEBRTC]]. 75 |
76 |77 | For Scalable Video Coding (SVC), the terms "single-session transmission" 78 | (SST) and "multi-session transmission" (MST) are 79 | defined in [[?RFC6190]]. This specification only supports SST but 80 | not MST. 81 |
82 |83 | The term "Single Real-time Transport Protocol stream Single Transport" 84 | (SRST), defined in [[RFC7656]] Section 3.7, refers to SVC 85 | implementations that transmit all layers within a single transport, 86 | using a single Real-time Transport Protocol (RTP) stream and 87 | synchronization source (SSRC). The term "Multiple RTP stream Single 88 | Transport" (MRST), also defined in [[RFC7656]] Section 3.7, 89 | refers to implementations that transmit all layers within a single 90 | transport, using multiple RTP streams with a distinct SSRC for each layer. 91 | This specification only supports SRST, not MRST. Codecs 92 | with RTP payload specifications supporting SRST include VP8 93 | [[?RFC7741]], VP9 [[?VP9-PAYLOAD]], AV1 [[?AV1-RTP-SPEC]], H.264 94 | [[?RFC6184]] and H.265 [[?RFC7798]]. 95 |
96 |97 | The term "S mode" refers to a scalability mode in which multiple 98 | encodings are sent on the same SSRC. This includes the [="S2T1"=], [="S2T1h"=], 99 | [="S2T2"=], [="S2T2h"=], [="S2T3"=], [="S2T3h"=], [="S3T1"=], [="S3T1h"=], [="S3T2"=], [="S3T2h"=], 100 | [="S3T3"=] and [="S3T3h"=] {{RTCRtpEncodingParameters/scalabilityMode}} values. 101 |
102 |103 | The term Selective Forwarding Middlebox 104 | (SFM) is defined in Section 3.7 of [[RFC7667]]. 105 |
106 |110 | This specification enables the configuration of encoding parameters for SVC 111 | by extending the {{RTCRtpEncodingParameters}} dictionary. 112 |
113 |partial dictionary RTCRtpEncodingParameters {
117 | DOMString scalabilityMode;
118 | };
119 |
126 | This member can only be [=map/exists|present=] if the sender's
127 | kind is "video".
128 | When [=map/exists|present=], indicates the case-sensitive
129 | identifier of the scalability mode to be
130 | used for this stream. Scalability modes are defined in
131 | Section 5.
132 |
141 | [[!WEBRTC]] describes error handling in {{RTCPeerConnection/addTransceiver()}} 142 | (Section 5.1) and {{RTCRtpSender/setParameters()}} (Section 5.2), 143 | including use of {{RTCError}} to indicate a 144 | {{RTCErrorDetailType/"hardware-encoder-error"}} 145 | due to an unsupported encoding parameter, as well as other errors. 146 | Implementations utilize {{RTCError}} and other errors 147 | in the prescribed manner when an invalid 148 | {{RTCRtpEncodingParameters/scalabilityMode}} value is provided to 149 | {{RTCRtpSender/setParameters()}} or {{RTCPeerConnection/addTransceiver()}}. 150 |
151 |154 | [[!WEBRTC]] Section 5.1 describes validation of 155 | {{RTCRtpTransceiverInit/sendEncodings}} within 156 | {{RTCPeerConnection/addTransceiver()}}. To validate 157 | {{RTCRtpEncodingParameters/scalabilityMode}}, add 158 | the following steps after step 3 of 159 | [=RTCPeerConnection/addTransceiver sendEncodings validation steps=]: 160 |
true and
177 | sendEncodings [=list/contains=] any encoding whose
178 | {{RTCRtpEncodingParameters/scalabilityMode}} value
179 | represents an "S mode" and whose
180 | {{RTCRtpEncodingParameters/active}} member has a
181 | value of true, [= exception/throw =] an
182 | {{OperationError}}.
183 | 187 | When the {{RTCPeerConnection/addTransceiver()}} and 188 | {{RTCRtpTransceiver/setCodecPreferences()}} methods are called 189 | prior to conclusion of the Offer/Answer negotiation, the negotiated 190 | codec and its capabilities may not be known. In this situation the 191 | {{RTCRtpEncodingParameters/scalabilityMode}} values configured 192 | in {{RTCRtpTransceiverInit/sendEncodings}} may not be supported 193 | by the eventually negotiated codec. However, an error will only result 194 | if the requested {{RTCRtpEncodingParameters/scalabilityMode}} value is 195 | invalid for any supported codec, or if mixed simulcast transport is requested. 196 |
197 |198 | So as to ensure that the desired {{RTCRtpEncodingParameters/scalabilityMode}} 199 | values can be applied, {{RTCRtpTransceiver/setCodecPreferences()}} can be 200 | used to prefer or only include codecs supporting the desired configuration. 201 | For example, if temporal scalability is desired along with spatial simulcast, 202 | when {{RTCPeerConnection/addTransceiver()}} is called, 203 | {{RTCRtpTransceiverInit/sendEncodings}} can be configured to send multiple 204 | simulcast streams with different resolutions, with each stream 205 | utilizing temporal scalability. If only the VP8, VP9 and AV1 codec implementations 206 | support temporal scalability, {{RTCRtpTransceiver/setCodecPreferences()}} 207 | can be used to remove the H.264/AVC codec from the Offer, improving the 208 | chances that a codec supporting temporal scalability is negotiated. 209 |
210 |211 | When {{RTCRtpTransceiverInit/sendEncodings}} is used to 212 | request the sending of multiple simulcast streams using 213 | {{RTCPeerConnection/addTransceiver()}}, an "S mode" cannot 214 | be requested. The browser may only be configured to send 215 | simulcast encodings with multiple SSRCs and RIDs, or 216 | alternatively, to send all simulcast encodings on a single 217 | RTP stream. Simultaneously using both simulcast transport 218 | techniques is not permitted. 219 |
220 |224 | [[!WEBRTC]] Section 5.2 describes validation of parameters 225 | within {{RTCRtpSender/setParameters()}}. Insert the following 226 | conditions under which the operation causes a promise rejected 227 | with an {{InvalidModificationError}} (step 4) of 228 | [=RTCRtpSender/setParameters validation steps=]: 229 |
true and
253 | encodings contains any encoding whose
254 | {{RTCRtpEncodingParameters/scalabilityMode}} value
255 | represents an "S mode" and whose
256 | {{RTCRtpEncodingParameters/active}} member has a
257 | value of true.
258 | 262 | The [="L1T1"=] scalability mode enables SVC encoding to be turned off 263 | using {{RTCRtpSender/setParameters()}}. If [="L1T1"=] is set using 264 | {{RTCRtpSender/setParameters()}} then it will be returned in response 265 | to {{RTCRtpSender/getParameters()}}. 266 |
267 |271 | Before the initial negotiation has completed, 272 | {{RTCRtpSender/getParameters()}} returns the 273 | {{RTCRtpEncodingParameters/scalabilityMode}} value for each 274 | encoding in encodings, as last set by 275 | {{RTCPeerConnection/addTransceiver()}} or 276 | {{RTCRtpSender/setParameters()}}. If no 277 | {{RTCRtpEncodingParameters/scalabilityMode}} value 278 | was provided for an encoding in encodings, 279 | or if a value was not successfully set, then 280 | {{RTCRtpSender/getParameters()}} will not return a 281 | {{RTCRtpEncodingParameters/scalabilityMode}} value 282 | for that encoding. 283 |
284 |285 | After the initial negotiation has completed, {{RTCRtpSender/getParameters()}} 286 | returns the currently configured {{RTCRtpEncodingParameters/scalabilityMode}} 287 | value for each encoding in encodings which had a value before the 288 | initial negotiation. This MAY be different from the values requested in 289 | {{RTCPeerConnection/addTransceiver()}} or {{RTCRtpSender/setParameters()}}. 290 | For example, if the codecs selected during negotiation do not include an 291 | encoder supporting the desired {{RTCRtpEncodingParameters/scalabilityMode}} 292 | value, the user agent MAY select another value. If the configuration is not 293 | satisfactory, {{RTCRtpSender/setParameters()}} can be used to change it. 294 |
295 |296 | If {{RTCPeerConnection/addTransceiver()}} or {{RTCRtpSender/setParameters()}} 297 | did not provide a {{RTCRtpEncodingParameters/scalabilityMode}} value for 298 | an encoding in encodings, then after the initial negotiation 299 | has completed, {{RTCRtpSender/getParameters()}} will not return a 300 | {{RTCRtpEncodingParameters/scalabilityMode}} value and the encoder will use 301 | the default {{RTCRtpEncodingParameters/scalabilityMode}} of the codec for 302 | that encoding's RTP stream. The default {{RTCRtpEncodingParameters/scalabilityMode}} 303 | for each codec is implementation dependent. The default 304 | {{RTCRtpEncodingParameters/scalabilityMode}} SHOULD be one of the 305 | temporal scalability modes (e.g. [="L1T1"=],[="L1T2"=],[="L1T3"=], etc.). 306 |
307 |311 | SVC is most often employed in video conferencing, where a conferencing 312 | server such as a SFM 313 | selectively forwards layers to participants based on their device 314 | characteristics and available bandwidth. In such an environment, 315 | the application will negotiate codecs to be sent and received with 316 | the conferencing server. However, since scalability modes are not 317 | negotiated in Offer/Answer, the application needs to determine 318 | which scalability modes the browser and conference server support 319 | by other means. 320 |
321 |322 | The [[?Media-Capabilities]] API enables discovery of encoder and decoder 323 | support for scalable video coding. {{VideoConfiguration//scalabilityMode}} 324 | is used to query whether an encoder supports a 325 | {{RTCRtpEncodingParameters/scalabilityMode}} value, indicating whether 326 | it is "supported", "smooth" and "power efficient". 327 |
328 |
329 | The [[?Media-Capabilities]] API also provides information on decoder support
330 | for spatial scalablity modes. {{VideoConfiguration/spatialScalability}}
331 | indicates whether a decoder has the ability to support spatial prediction,
332 | which requires the ability to use frames of a resolution different than
333 | the current resolution as a dependency. If {{VideoConfiguration/spatialScalability}}
334 | is set to true, the decoder can decode any
335 | {{RTCRtpEncodingParameters/scalabilityMode}} value supported by the encoder.
336 | If {{VideoConfiguration/spatialScalability}} is set to false
337 | or is absent, the decoder cannot decode spatial scalability modes, but can
338 | can decode all other {{RTCRtpEncodingParameters/scalabilityMode}} values
339 | supported by the encoder.
340 |
342 | Once an application has determined which combination of codecs and 343 | {{RTCRtpEncodingParameters/scalabilityMode}} values it has available to use, 344 | it needs to determine which of these combinations are supported by the SFM. 345 | One way to handle this is for the SFM to indicate the combination of codecs 346 | and scalability modes it can forward in the form of receiver capabilities 347 | After receiving the SFM's capabilities, the application can compute the 348 | intersection of codec and {{RTCRtpEncodingParameters/scalabilityMode}} values 349 | supported by the browser's {{RTCRtpSender}} and the 350 | SFM's receiver. This 351 | can be used to determine the arguments passed to the browser's 352 | {{RTCPeerConnection/addTransceiver()}} and {{RTCRtpSender/setParameters()}} 353 | methods. 354 |
355 |356 | Here are some examples: 357 |
381 | There are situations in which computing the intersection of the browser and 382 | SFM capabilities needs to take RTP header extensions into account. If the 383 | SFM cannot parse codec payloads 384 | (either because it is not designed to do so, or because the payloads are encrypted), 385 | then negotiation of an RTP header extension (such as the AV1 Dependency Descriptor 386 | defined in Appendix A of [[?AV1-RTP-SPEC]]) could be required for the 387 | SFM to forward a particular codec. 388 | To take this into account, the RTP header extensions required for forwarding of a 389 | codec could be added to the SFM's receiver capabilities. The application could 390 | then compute the intersection of codec, header extension and 391 | {{RTCRtpEncodingParameters/scalabilityMode}} values supported 392 | by the browser's {{RTCRtpSender}} and the 393 | SFM's receiver. 394 |
395 |401 | The {{RTCRtpEncodingParameters/scalabilityMode}} values supported in this specification, 402 | as well as their associated identifiers and characteristics, are provided in the table 403 | below. The names of the {{RTCRtpEncodingParameters/scalabilityMode}} values (which are 404 | case sensitive) are provided, along with the scalability mode identifiers assigned in 405 | [[?AV1]] Section 6.7.5, and links to dependency diagrams provided in Section 9. 406 |
407 |408 | While the [[?AV1]] and VP9 [[?VP9]] specifications support all the 409 | {{RTCRtpEncodingParameters/scalabilityMode}} values defined in the table, other codec 410 | specifications do not. For example, VP8 [[?RFC6386]], H.264 [[?RFC6184]] and 411 | H.265 [[?RFC7798]] only support temporal scalability (e.g. [="L1T2"=], [="L1T3"=]). 412 | Also VP8 [[?RFC6386]], H.264 [[?RFC6184]] and H.265 [[?RFC7798]] only permit transport 413 | of simulcast on distinct SSRCs, so that "S" modes (where multiple encodings are 414 | transported on a single RTP stream) are not supported. 415 |
416 || Scalability Mode Identifier | 420 |Spatial Layers | 421 |Resolution Ratio | 422 |Temporal Layers | 423 |Inter-layer dependency | 424 |AV1 scalability_mode_idc | 425 |
|---|---|---|---|---|---|
| "L1T1" | 430 |1 | 431 |432 | | 1 | 433 |434 | | N/A | 435 |
| "L1T2" | 438 |1 | 439 |440 | | 2 | 441 |442 | | SCALABILITY_L1T2 | 443 |
| "L1T3" | 446 |1 | 447 |448 | | 3 | 449 |450 | | SCALABILITY_L1T3 | 451 |
| "L2T1" | 454 |2 | 455 |2:1 | 456 |1 | 457 |Yes | 458 |SCALABILITY_L2T1 | 459 |
| "L2T2" | 462 |2 | 463 |2:1 | 464 |2 | 465 |Yes | 466 |SCALABILITY_L2T2 | 467 |
| "L2T3" | 470 |2 | 471 |2:1 | 472 |3 | 473 |Yes | 474 |SCALABILITY_L2T3 | 475 |
| "L3T1" | 478 |3 | 479 |2:1 | 480 |1 | 481 |Yes | 482 |SCALABILITY_L3T1 | 483 |
| "L3T2" | 486 |3 | 487 |2:1 | 488 |2 | 489 |Yes | 490 |SCALABILITY_L3T2 | 491 |
| "L3T3" | 494 |3 | 495 |2:1 | 496 |3 | 497 |Yes | 498 |SCALABILITY_L3T3 | 499 |
| "L2T1h" | 502 |2 | 503 |1.5:1 | 504 |1 | 505 |Yes | 506 |SCALABILITY_L2T1h | 507 |
| "L2T2h" | 510 |2 | 511 |1.5:1 | 512 |2 | 513 |Yes | 514 |SCALABILITY_L2T2h | 515 |
| "L2T3h" | 518 |2 | 519 |1.5:1 | 520 |3 | 521 |Yes | 522 |SCALABILITY_L2T3h | 523 |
| "L3T1h" | 526 |3 | 527 |1.5:1 | 528 |1 | 529 |Yes | 530 |531 | |
| "L3T2h" | 534 |3 | 535 |1.5:1 | 536 |2 | 537 |Yes | 538 |539 | |
| "L3T3h" | 542 |3 | 543 |1.5:1 | 544 |3 | 545 |Yes | 546 |547 | |
| "S2T1" | 550 |2 | 551 |2:1 | 552 |1 | 553 |No | 554 |SCALABILITY_S2T1 | 555 |
| "S2T2" | 558 |2 | 559 |2:1 | 560 |2 | 561 |No | 562 |SCALABILITY_S2T2 | 563 |
| "S2T3" | 566 |2 | 567 |2:1 | 568 |3 | 569 |No | 570 |SCALABILITY_S2T3 | 571 |
| "S2T1h" | 574 |2 | 575 |1.5:1 | 576 |1 | 577 |No | 578 |SCALABILITY_S2T1h | 579 |
| "S2T2h" | 582 |2 | 583 |1.5:1 | 584 |2 | 585 |No | 586 |SCALABILITY_S2T2h | 587 |
| "S2T3h" | 590 |2 | 591 |1.5:1 | 592 |3 | 593 |No | 594 |SCALABILITY_S2T3h | 595 |
| "S3T1" | 598 |3 | 599 |2:1 | 600 |1 | 601 |No | 602 |SCALABILITY_S3T1 | 603 |
| "S3T2" | 606 |3 | 607 |2:1 | 608 |2 | 609 |No | 610 |SCALABILITY_S3T2 | 611 |
| "S3T3" | 614 |3 | 615 |2:1 | 616 |3 | 617 |No | 618 |SCALABILITY_S3T3 | 619 |
| "S3T1h" | 622 |3 | 623 |1.5:1 | 624 |1 | 625 |No | 626 |SCALABILITY_S3T1h | 627 |
| "S3T2h" | 630 |3 | 631 |1.5:1 | 632 |2 | 633 |No | 634 |SCALABILITY_S3T2h | 635 |
| "S3T3h" | 638 |3 | 639 |1.5:1 | 640 |3 | 641 |No | 642 |SCALABILITY_S3T3h | 643 |
| "L2T2_KEY" | 646 |2 | 647 |2:1 | 648 |2 | 649 |Yes | 650 |SCALABILITY_L3T2_KEY | 651 |
| "L2T2_KEY_SHIFT" | 654 |2 | 655 |2:1 | 656 |2 | 657 |Yes | 658 |SCALABILITY_L3T2_KEY_SHIFT | 659 |
| "L2T3_KEY" | 662 |2 | 663 |2:1 | 664 |3 | 665 |Yes | 666 |SCALABILITY_L3T3_KEY | 667 |
| "L2T3_KEY_SHIFT" | 670 |2 | 671 |2:1 | 672 |3 | 673 |Yes | 674 |SCALABILITY_L3T3_KEY_SHIFT | 675 |
| "L3T1_KEY" | 678 |3 | 679 |2:1 | 680 |1 | 681 |Yes | 682 |683 | |
| "L3T2_KEY" | 686 |3 | 687 |2:1 | 688 |2 | 689 |Yes | 690 |SCALABILITY_L4T5_KEY | 691 |
| "L3T2_KEY_SHIFT" | 694 |3 | 695 |2:1 | 696 |2 | 697 |Yes | 698 |SCALABILITY_L4T5_KEY_SHIFT | 699 |
| "L3T3_KEY" | 702 |3 | 703 |2:1 | 704 |3 | 705 |Yes | 706 |SCALABILITY_L4T7_KEY | 707 |
| "L3T3_KEY_SHIFT" | 710 |3 | 711 |2:1 | 712 |3 | 713 |Yes | 714 |SCALABILITY_L4T7_KEY_SHIFT | 715 |
When proposing a {{RTCRtpEncodingParameters/scalabilityMode}} value, the following principles should be followed:
721 |LxTy to denote a {{RTCRtpEncodingParameters/scalabilityMode}} with x
731 | spatial layers using a 2:1 resolution ratio and y temporal layers.
732 | LxTyh denotes x spatial layers with a 1.5:1 resolution ratio and
733 | y temporal layers. SxTy denotes a {{RTCRtpEncodingParameters/scalabilityMode}}
734 | with x simulcast encodings with a 2:1 resolution ratio, with each
735 | simulcast encoding containing y temporal layers. SxTyh denotes
736 | a 1.5:1 resolution ratio. LxTy_KEY denotes a {{RTCRtpEncodingParameters/scalabilityMode}}
737 | with x spatial layers using a 2:1 resolution ratio and y temporal layers in which spatial layers only
738 | depend on lower spatial layers at a key frame. LxTy_KEY_SHIFT modes denotes a
739 | {{RTCRtpEncodingParameters/scalabilityMode}} with x spatial layers using a 2:1 resolution ratio and
740 | y temporal layers in which spatial layers only depend on lower spatial layers at a key frame and subsequent
741 | frames have their temporal identifier shifted upward.
742 | 754 | This example extends [[WEBRTC]] Section 7.1 (Example 1) to demonstrate sending three spatial 755 | simulcast layers each with three temporal layers, using an SSRC and RID for each simulcast 756 | layer. Only the "sendEncodings" attribute is changed from the original example. 757 |
758 |
759 | const signaling = new SignalingChannel(); // handles JSON.stringify/parse
760 | const constraints = {audio: true, video: true};
761 | const configuration = {'iceServers': [{'urls': 'stun:stun.example.org'}]};
762 | let pc;
763 |
764 | // call start() to initiate
765 | async function start() {
766 | pc = new RTCPeerConnection(configuration);
767 |
768 | // let the "negotiationneeded" event trigger offer generation
769 | pc.onnegotiationneeded = async () => {
770 | try {
771 | await pc.setLocalDescription();
772 | // send the offer to the other peer
773 | signaling.send({description: pc.localDescription});
774 | } catch (err) {
775 | console.error(err);
776 | }
777 | };
778 |
779 | try {
780 | // get a local stream, show it in a self-view and add it to be sent
781 | const stream = await navigator.mediaDevices.getUserMedia(constraints);
782 | selfView.srcObject = stream;
783 | pc.addTransceiver(stream.getAudioTracks()[0], {direction: 'sendonly'});
784 | pc.addTransceiver(stream.getVideoTracks()[0], {
785 | direction: 'sendonly',
786 | sendEncodings: [
787 | {rid: 'q', scaleResolutionDownBy: 4.0, scalabilityMode: 'L1T3'},
788 | {rid: 'h', scaleResolutionDownBy: 2.0, scalabilityMode: 'L1T3'},
789 | {rid: 'f', scalabilityMode: 'L1T3'}
790 | ]
791 | });
792 | } catch (err) {
793 | console.error(err);
794 | }
795 | }
796 |
797 | signaling.onmessage = async ({data: {description, candidate}}) => {
798 | try {
799 | if (description) {
800 | await pc.setRemoteDescription(description);
801 | // if we got an offer, we need to reply with an answer
802 | if (description.type == 'offer') {
803 | await pc.setLocalDescription();
804 | signaling.send({description: pc.localDescription});
805 | }
806 | } else if (candidate) {
807 | await pc.addIceCandidate(candidate);
808 | }
809 | } catch (err) {
810 | console.error(err);
811 | }
812 | };
813 |
814 | 815 | This is an example with two spatial layers (with a 2:1 ratio) and three temporal layers. 816 |
817 |
818 | let sendEncodings = [
819 | {scalabilityMode: 'L2T3'}
820 | ];
821 |
822 | 823 | This is an example of mixed codec simulcast, with each simulcast layer having 3 temporal layers. 824 |
825 |
826 | let sendEncodings = [
827 | {rid: 'q', codec: {clockRate: 90000, mimeType: 'video/AV1'}, scaleResolutionDownBy: 4.0, scalabilityMode: 'L1T3'},
828 | {rid: 'h', codec: {clockRate: 90000, mimeType: 'video/VP8'}, scaleResolutionDownBy: 2.0, scalabilityMode: 'L1T3'},
829 | {rid: 'f', codec: {clockRate: 90000, mimeType: 'video/VP8'}, scalabilityMode: 'L1T3'}
830 | ];
831 |
832 | 833 | This is an example with three spatial simulcast layers each with three temporal layers on a single SSRC. 834 |
835 |
836 | let sendEncodings = [
837 | {scalabilityMode: 'S3T3'}
838 | ]
839 |
840 | 844 | This is an example of {{MediaCapabilities/encodingInfo(configuration)}} 845 | returned by a browser implementing [[WEBRTC]] and [[?Media-Capabilities]]. 846 |
847 |
848 | const contentType = 'video/VP9';
849 |
850 | const configuration = {
851 | type: 'webrtc',
852 | video: {
853 | contentType,
854 | width: 640,
855 | height: 480,
856 | bitrate: 10000,
857 | framerate: 29.97,
858 | scalabilityMode: 'L3T3_KEY'
859 | }
860 | };
861 |
862 | try {
863 | const info = await navigator.mediaCapabilities.encodingInfo(configuration);
864 |
865 | if (!info.supported) {
866 | console.log(`${contentType} is unsupported.`);
867 | return;
868 | }
869 | console.log(`${contentType} is ${info.smooth || 'NOT '}smooth, and ` +
870 | `${info.powerEfficient || 'NOT '}power efficient`);
871 | } catch (err) {
872 | console.error(err, ' caused encodingInfo to fail');
873 | }
874 |
875 | 879 | This is an example of receiver capabilities returned by an 880 | SFM that only 881 | supports forwarding of VP8, VP9 and AV1 temporal scalability modes. 882 |
883 |
884 | "codecs": [
885 | {
886 | "clockRate": 90000,
887 | "mimeType": "video/VP8",
888 | "scalabilityModes": [
889 | "L1T1",
890 | "L1T2",
891 | "L1T3"
892 | ]
893 | },
894 | {
895 | "clockRate": 90000,
896 | "mimeType": "video/VP9",
897 | "scalabilityModes": [
898 | "L1T1",
899 | "L1T2",
900 | "L1T3"
901 | ]
902 | },
903 | {
904 | "clockRate": 90000,
905 | "mimeType": "video/AV1",
906 | "scalabilityModes": [
907 | "L1T1",
908 | "L1T2",
909 | "L1T3"
910 | ]
911 | }
912 | ]
913 |
914 | 919 | This section is non-normative; it specifies no new behaviour, but 920 | instead summarizes information already present in other parts of the 921 | specification. The privacy considerations 922 | for the WebRTC APIs are described in [[WEBRTC]] Section 13. 923 |
924 |927 | In WebRTC, the use of scalable coding tools is not 928 | negotiated between peers, so neither supported 929 | {{RTCRtpEncodingParameters/scalabilityMode}} values nor 930 | decoder support for spatial prediction is exposed in SDP. 931 |
932 |933 | By attempting to set 934 | {{RTCRtpEncodingParameters/scalabilityMode}} values for 935 | each codec using the {{RTCRtpSender/setParameters()}} API, 936 | an application can determine the values supported by the 937 | encoder, by noting which configuration attempts succeed 938 | and which ones fail. However, this does not indicate 939 | whether a {{RTCRtpEncodingParameters/scalabilityMode}} 940 | value is supported by a hardware or software encoder 941 | (or both). Since {{RTCRtpSender/setParameters()}} 942 | is not supported for the {{RTCRtpReceiver}}, equivalent 943 | experiments cannot be run to determine decoder support. 944 |
945 |946 | Since the {{RTCRtpEncodingParameters/scalabilityMode}} 947 | values supported by software encoders are typically 948 | a superset of those supported in hardware, the information 949 | available from these experiments has a high correlation 950 | with the browser in use, which is already available to 951 | web pages. Once media is flowing, information on 952 | performance characteristics or whether a 953 | {{RTCRtpEncodingParameters/scalabilityMode}} value 954 | is decodable for the codec in use can be obtained, 955 | which provides more information on hardware capabilities. 956 |
957 |958 | As noted in [[?Media-Capabilities]] Section 3.1, the Media 959 | Capabilities API "will likely provide more accurate and 960 | consistent information" than is available from this 961 | specification. As noted in 962 | [[?Media-Capabilities]] Section 3.1, "This information is 963 | expected to have a high correlation with other information 964 | already available to the web pages as a given class of 965 | device is expected to have very similar decoding/encoding 966 | capabilities." 967 |
968 |973 | This section is non-normative; it specifies no new behaviour, but 974 | instead summarizes information already present in other parts of the 975 | specification. WebRTC protocol security considerations are described 976 | in [[RFC8827]] and the security and privacy considerations 977 | for the WebRTC APIs are described in [[WEBRTC]] Section 13. 978 |
979 |983 | Dependency diagrams for the scability modes defined in this specification 984 | are provided below. 985 |
986 |1240 | The editors wish to thank Robin Raymond, Michael Horowitz, Harald Alvestrand, 1241 | Chris Cunningham, Danil Chapovalov, Florent Castelli, Erik Språng and Henrik Boström 1242 | for their contributions to this specification, which evolved from the ORTC API 1243 | developed in the W3C ORTC CG. 1244 |
1245 |