-
Notifications
You must be signed in to change notification settings - Fork 114
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
Allow level-id to be different in codec match #3023
Conversation
@aboba Does this wording make sense to you? |
if you want to go this route you will also need to take care of RFC6184s |
No this is just about the codec matching algorithm used to sanity check input to setParameters/setCodecPreferences, what is actually negotiated based on this is defined somewhere else. As for sending the selected codec, the description is kind of vague, RTCRtpEncodingParmaters.codec just says:
And setParameters just says:
So it's just "codec used for selecting what to send", we might want to create an issue about clarifying not to send greater than the level-id that was negotiated, but that seems more like an editorial note. |
We might want to update getParameters().encodings[i].codec to match the level-id that you find in getParamters().codecs though? Separate issue though because that is the same as what happens with setCodecPreferences() today |
Codec wizard @aboba, can you do another review? |
Btw I had said during the meeting that I thought all instances of "codec matching" could ignore level, but upon a second look I realized that we don't need to be that "loose" in most cases. For example if you addTransceiver, the only valid input is from getCapabilities since there is no chance that anything else has been negotiated for that transceiver yet. It might not hurt to be more loose here, but it does not seem to help either. Ultimately we only need to "ignoreLevels=true" at a few places:
In all other cases we can "ignoreLevels=false", which the PR reflects now. |
Co-authored-by: Harald Alvestrand <[email protected]>
Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7
Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <[email protected]> Commit-Queue: Henrik Boström <[email protected]> Reviewed-by: Evan Shrubsole <[email protected]> Cr-Commit-Position: refs/heads/main@{#1404052}
Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <[email protected]> Commit-Queue: Henrik Boström <[email protected]> Reviewed-by: Evan Shrubsole <[email protected]> Cr-Commit-Position: refs/heads/main@{#1404052}
Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <[email protected]> Commit-Queue: Henrik Boström <[email protected]> Reviewed-by: Evan Shrubsole <[email protected]> Cr-Commit-Position: refs/heads/main@{#1404052}
WPTs added and PR updated with link + addressed remaining comments. |
Merging based on Editors can integrate |
Removing needs test label since tests now exist |
…al level-id in SDP answers., a=testonly Automatic update from web-platform-tests Add WPTs for negotiating H265 with minimal level-id in SDP answers. Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <[email protected]> Commit-Queue: Henrik Boström <[email protected]> Reviewed-by: Evan Shrubsole <[email protected]> Cr-Commit-Position: refs/heads/main@{#1404052} -- wpt-commits: 545a2ed81a38330f024fac8c0b139739a7329097 wpt-pr: 49990
Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <[email protected]> Commit-Queue: Henrik Boström <[email protected]> Reviewed-by: Evan Shrubsole <[email protected]> Cr-Commit-Position: refs/heads/main@{#1404052}
…al level-id in SDP answers., a=testonly Automatic update from web-platform-tests Add WPTs for negotiating H265 with minimal level-id in SDP answers. Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <[email protected]> Commit-Queue: Henrik Boström <[email protected]> Reviewed-by: Evan Shrubsole <[email protected]> Cr-Commit-Position: refs/heads/main@{#1404052} -- wpt-commits: 545a2ed81a38330f024fac8c0b139739a7329097 wpt-pr: 49990
…al level-id in SDP answers., a=testonly Automatic update from web-platform-tests Add WPTs for negotiating H265 with minimal level-id in SDP answers. Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <dbaronchromium.org> Commit-Queue: Henrik Boström <hboschromium.org> Reviewed-by: Evan Shrubsole <eshrgoogle.com> Cr-Commit-Position: refs/heads/main{#1404052} -- wpt-commits: 545a2ed81a38330f024fac8c0b139739a7329097 wpt-pr: 49990 UltraBlame original commit: 86ca1c880fa3a95d616df4db1fae65eb4e24e60e
…al level-id in SDP answers., a=testonly Automatic update from web-platform-tests Add WPTs for negotiating H265 with minimal level-id in SDP answers. Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <dbaronchromium.org> Commit-Queue: Henrik Boström <hboschromium.org> Reviewed-by: Evan Shrubsole <eshrgoogle.com> Cr-Commit-Position: refs/heads/main{#1404052} -- wpt-commits: 545a2ed81a38330f024fac8c0b139739a7329097 wpt-pr: 49990 UltraBlame original commit: 86ca1c880fa3a95d616df4db1fae65eb4e24e60e
…al level-id in SDP answers., a=testonly Automatic update from web-platform-tests Add WPTs for negotiating H265 with minimal level-id in SDP answers. Add test coverage for w3c/webrtc-pc#3023 which unblocks merging the PR (it has "editors can integrate"). Specifically it should be possible to negotiate H265 even if the level-id is downgraded in the SDP answer (not throwing on level-id mismatch). - H265 is behind flags so a virtual test suite is added. - If bot lacks HW capabilities to do H265, the tests will PRECONDITION_FAILED. To avoid reverting tests we will allow the bots to both pass and fail, I filed crbug.com/388299759. Some of the tests FAIL even when they run: passing these tests will be covered by crbug.com/381407888. Bug: chromium:381407888, webrtc:41480904, chromium:388299759 Change-Id: Ie017560b4310418a4c9ed854dcb09136b9b446e7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6148192 Reviewed-by: David Baron <dbaronchromium.org> Commit-Queue: Henrik Boström <hboschromium.org> Reviewed-by: Evan Shrubsole <eshrgoogle.com> Cr-Commit-Position: refs/heads/main{#1404052} -- wpt-commits: 545a2ed81a38330f024fac8c0b139739a7329097 wpt-pr: 49990 UltraBlame original commit: 86ca1c880fa3a95d616df4db1fae65eb4e24e60e
This CL implements allowing sendonly codecs in setCodecPreferences(), i.e. this spec PR: w3c/webrtc-pc#3018. It also makes the setCodecPreferences() ignore level IDs in the filtering algorithm (but not in the sCP method call) as per this spec PR: w3c/webrtc-pc#3023. In short, before this CL, setCodecPreferences() threw an exception if a codec was preferred that is not present in receiver codec capabilities. After this CL, setCodecPreferences() allows you to prefer codecs that are *either* in the sender capabilities *or* the receiver capabilities. - This allows you to "offer to send", i.e. prefer sendonly codecs on a sendonly transceiver. - The filtering on direction is handled by RtpTransceiver::filtered_codec_preferences() which is called during SDP offer/answer (sdp_offer_answer.cc). Also as per spec changes, if this filtering results in not having any codecs to offer or answer then this results in not having any codec preferences as opposed to throwing an exception (old behavior). - Two old peer_connection_media_unittest.cc tests are updated to reflect the API failing less. This CL adds both unit tests (rtp_transceiver_unittest.cc) and full stack integration tests (peer_connection_encodings_integrationtest.cc). It also makes us pass the following Web Platform Tests in Chrome: https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/web_tests/external/wpt/webrtc/protocol/h265-level-id.https.html Bug: chromium:381407888 Change-Id: I98a5ad1acccb56db0538e4d47975b8a725102c33 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/374520 Reviewed-by: Ilya Nikolaevskiy <[email protected]> Commit-Queue: Henrik Boström <[email protected]> Reviewed-by: Harald Alvestrand <[email protected]> Reviewed-by: Evan Shrubsole <[email protected]> Cr-Commit-Position: refs/heads/main@{#43788}
Fixes #3020
Preview | Diff