webrtc/modules/video_coding/codecs/av1
Evan Shrubsole b556b08668 Allow encoders to receive preferred pixel formats from native buffers
Adds a field to EncoderInfo called preferred_pixel_formats which a
software encoder populates with the pixel formats it supports. When a
kNative frame is received for encoding, the VideoStreamEncoder will
first try to get a frame that is accessible by the software encoder in
that pixel format from the kNative frame. If this fails it will fallback
to converting the frame using ToI420.

This minimizes the number of conversions made in the case that the
encoder supports the pixel format of the native buffer or where
conversion can be accelerated. For example, in Chromium, the capturer can
emit an NV12 frame, which can be consumed by libvpx which supports NV12.

Testing: Tested in Chrome with media::VideoFrame adapters.

Bug: webrtc:11977
Change-Id: I9becc4100136b0c0128f4fa06dedf9ee4dc62f37
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/187121
Reviewed-by: Niels Moller <nisse@webrtc.org>
Reviewed-by: Ilya Nikolaevskiy <ilnik@webrtc.org>
Reviewed-by: Markus Handell <handellm@webrtc.org>
Commit-Queue: Evan Shrubsole <eshr@google.com>
Cr-Commit-Position: refs/heads/master@{#32353}
2020-10-08 13:47:50 +00:00
..
BUILD.gn Add scaling interface to VideoFrameBuffer 2020-10-08 13:33:00 +00:00
create_scalability_structure.cc Add factory to create scalability structures by name 2020-07-15 10:26:40 +00:00
create_scalability_structure.h Add factory to create scalability structures by name 2020-07-15 10:26:40 +00:00
DEPS Add Av1 Decoder wrapper behind a build flag 2020-03-11 11:20:56 +00:00
libaom_av1_decoder.cc Extend I420 frame buffer pool to also create NV12 buffers 2020-09-21 09:46:15 +00:00
libaom_av1_decoder.h Add Av1 Decoder wrapper behind a build flag 2020-03-11 11:20:56 +00:00
libaom_av1_decoder_absent.cc Add Av1 Decoder wrapper behind a build flag 2020-03-11 11:20:56 +00:00
libaom_av1_encoder.cc Allow encoders to receive preferred pixel formats from native buffers 2020-10-08 13:47:50 +00:00
libaom_av1_encoder.h Introduce layering controller interface for av1 encoder 2020-05-15 15:25:42 +00:00
libaom_av1_encoder_absent.cc Add AV1 encoder wrapper 2020-03-20 12:20:06 +00:00
libaom_av1_encoder_unittest.cc In Av1 encoder propagate zero bitrate as inactive decode target 2020-06-25 16:32:28 +00:00
libaom_av1_unittest.cc AV1: set error_resilience to 0. 2020-07-20 23:57:15 +00:00
scalability_structure_full_svc.cc Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_full_svc.h Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l1t2.cc Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l1t2.h Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l1t3.cc Embed FrameDependencyTemplate builder helpers directly into the struct 2020-06-11 13:43:51 +00:00
scalability_structure_l1t3.h Add av1 structures for 3 spatial and/or 3 temporal layers 2020-06-09 14:50:21 +00:00
scalability_structure_l2t1.cc Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l2t1.h Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l2t1_key.cc In av1 add structure with custom spatial scalability factor 2020-07-02 14:52:08 +00:00
scalability_structure_l2t1_key.h Add av1 test with spatial scalability. 2020-06-02 13:27:57 +00:00
scalability_structure_l2t1h.cc In av1 add structure with custom spatial scalability factor 2020-07-02 14:52:08 +00:00
scalability_structure_l2t1h.h In av1 add structure with custom spatial scalability factor 2020-07-02 14:52:08 +00:00
scalability_structure_l2t2.cc Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l2t2.h Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l2t2_key.cc In av1 add structure with custom spatial scalability factor 2020-07-02 14:52:08 +00:00
scalability_structure_l2t2_key.h Add av1 scalability structures for 2 spatial and 2 temporal layers. 2020-06-08 10:23:23 +00:00
scalability_structure_l2t2_key_shift.cc In av1 add structure with custom spatial scalability factor 2020-07-02 14:52:08 +00:00
scalability_structure_l2t2_key_shift.h Add av1 scalability structures for 2 spatial and 2 temporal layers. 2020-06-08 10:23:23 +00:00
scalability_structure_l3t1.cc Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l3t1.h Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalability_structure_l3t3.cc In av1 add structure with custom spatial scalability factor 2020-07-02 14:52:08 +00:00
scalability_structure_l3t3.h Add av1 structures for 3 spatial and/or 3 temporal layers 2020-06-09 14:50:21 +00:00
scalability_structure_s2t1.cc In av1 add structure with custom spatial scalability factor 2020-07-02 14:52:08 +00:00
scalability_structure_s2t1.h Add av1 test with spatial scalability. 2020-06-02 13:27:57 +00:00
scalability_structure_unittest.cc Factor out common logic for full svc scalability structures 2020-10-05 12:43:33 +00:00
scalable_video_controller.h In av1 add structure with custom spatial scalability factor 2020-07-02 14:52:08 +00:00
scalable_video_controller_no_layering.cc Add builder setters for ScalableVideoStructure::LayerFrameConfig 2020-06-09 10:31:35 +00:00
scalable_video_controller_no_layering.h Introduce layering controller interface for av1 encoder 2020-05-15 15:25:42 +00:00