Use layer/encode target resolution in DropDueToSize

It used input frame resolution before this change which caused unnecessary resolution adaptations when resolution scaling is used.

Found that initial frame dropping was always enabled for AV1 SVC. After fixing DropDueToSize the AV1 SVC tests [1] started to fail ("number of encoded temporal layers is less than expected") on bots. The tests encode 1850x1110 in L3T3 for 5s using the default 300kbps start bitrate. Before the fix the initial frame dropping kicked in and reduced the resolution to a level that let encoder to generate all temporal layers. After the fix the resolution stayed at 1850x1110 and encoder dropped all T1 and T2 layer frames. Mitigated this by increasing test duration from 5 to 10s. This gives enough time for BWE to ramp up and for encoder to generate (stop dropping) all temporal layers.

[1] https://source.chromium.org/chromium/chromium/src/+/main:third_party/webrtc/pc/test/svc_e2e_tests.cc;l=460;bpv=1

Bug: chromium:1466809
Change-Id: I16802689e234f8fc16f891f024d5f644985de01c
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/315142
Reviewed-by: Florent Castelli <orphis@webrtc.org>
Commit-Queue: Sergey Silkin <ssilkin@webrtc.org>
Reviewed-by: Åsa Persson <asapersson@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#40536}
3 files changed
tree: 0c9ff185bde9c25937f14c615ad1772bd1c70a97
  1. api/
  2. audio/
  3. build_overrides/
  4. call/
  5. common_audio/
  6. common_video/
  7. data/
  8. docs/
  9. examples/
  10. experiments/
  11. g3doc/
  12. infra/
  13. logging/
  14. media/
  15. modules/
  16. net/
  17. p2p/
  18. pc/
  19. resources/
  20. rtc_base/
  21. rtc_tools/
  22. sdk/
  23. stats/
  24. system_wrappers/
  25. test/
  26. tools_webrtc/
  27. video/
  28. .clang-format
  29. .git-blame-ignore-revs
  30. .gitignore
  31. .gn
  32. .mailmap
  33. .style.yapf
  34. .vpython
  35. .vpython3
  36. AUTHORS
  37. BUILD.gn
  38. CODE_OF_CONDUCT.md
  39. codereview.settings
  40. DEPS
  41. DIR_METADATA
  42. ENG_REVIEW_OWNERS
  43. LICENSE
  44. license_template.txt
  45. native-api.md
  46. OWNERS
  47. OWNERS_INFRA
  48. PATENTS
  49. PRESUBMIT.py
  50. presubmit_test.py
  51. presubmit_test_mocks.py
  52. pylintrc
  53. README.chromium
  54. README.md
  55. WATCHLISTS
  56. webrtc.gni
  57. webrtc_lib_link_test.cc
  58. whitespace.txt
README.md

WebRTC is a free, open software project that provides browsers and mobile applications with Real-Time Communications (RTC) capabilities via simple APIs. The WebRTC components have been optimized to best serve this purpose.

Our mission: To enable rich, high-quality RTC applications to be developed for the browser, mobile platforms, and IoT devices, and allow them all to communicate via a common set of protocols.

The WebRTC initiative is a project supported by Google, Mozilla and Opera, amongst others.

Development

See here for instructions on how to get started developing with the native code.

Authoritative list of directories that contain the native API header files.

More info