Add support for scalability modes L3T1_KEY, L3T2, L3T2_KEY.
Bug: webrtc:13960 Change-Id: Ib5c8309271d83a0fcfdecf7a93fdd61483c7d3e2 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/273105 Commit-Queue: Åsa Persson <asapersson@webrtc.org> Reviewed-by: Danil Chapovalov <danilchap@webrtc.org> Reviewed-by: Florent Castelli <orphis@webrtc.org> Cr-Commit-Position: refs/heads/main@{#37927}
This commit is contained in:
committed by
WebRTC LUCI CQ
parent
c18a8fd8d1
commit
46f4de5722
@ -343,6 +343,55 @@ FrameDependencyStructure ScalabilityStructureL2T3Key::DependencyStructure()
|
||||
return structure;
|
||||
}
|
||||
|
||||
ScalabilityStructureL3T1Key::~ScalabilityStructureL3T1Key() = default;
|
||||
|
||||
FrameDependencyStructure ScalabilityStructureL3T1Key::DependencyStructure()
|
||||
const {
|
||||
FrameDependencyStructure structure;
|
||||
structure.num_decode_targets = 3;
|
||||
structure.num_chains = 3;
|
||||
structure.decode_target_protected_by_chain = {0, 1, 2};
|
||||
auto& t = structure.templates;
|
||||
t.resize(6);
|
||||
// Templates are shown in the order frames following them appear in the
|
||||
// stream, but in `structure.templates` array templates are sorted by
|
||||
// (`spatial_id`, `temporal_id`) since that is a dependency descriptor
|
||||
// requirement.
|
||||
t[1].S(0).Dtis("SSS").ChainDiffs({0, 0, 0});
|
||||
t[3].S(1).Dtis("-SS").ChainDiffs({1, 1, 1}).FrameDiffs({1});
|
||||
t[5].S(2).Dtis("--S").ChainDiffs({2, 1, 1}).FrameDiffs({1});
|
||||
t[0].S(0).Dtis("S--").ChainDiffs({3, 2, 1}).FrameDiffs({3});
|
||||
t[2].S(1).Dtis("-S-").ChainDiffs({1, 3, 2}).FrameDiffs({3});
|
||||
t[4].S(2).Dtis("--S").ChainDiffs({2, 1, 3}).FrameDiffs({3});
|
||||
return structure;
|
||||
}
|
||||
|
||||
ScalabilityStructureL3T2Key::~ScalabilityStructureL3T2Key() = default;
|
||||
|
||||
FrameDependencyStructure ScalabilityStructureL3T2Key::DependencyStructure()
|
||||
const {
|
||||
FrameDependencyStructure structure;
|
||||
structure.num_decode_targets = 6;
|
||||
structure.num_chains = 3;
|
||||
structure.decode_target_protected_by_chain = {0, 0, 1, 1, 2, 2};
|
||||
auto& t = structure.templates;
|
||||
t.resize(9);
|
||||
// Templates are shown in the order frames following them appear in the
|
||||
// stream, but in `structure.templates` array templates are sorted by
|
||||
// (`spatial_id`, `temporal_id`) since that is a dependency descriptor
|
||||
// requirement.
|
||||
t[1].S(0).T(0).Dtis("SSSSSS").ChainDiffs({0, 0, 0});
|
||||
t[4].S(1).T(0).Dtis("--SSSS").ChainDiffs({1, 1, 1}).FrameDiffs({1});
|
||||
t[7].S(2).T(0).Dtis("----SS").ChainDiffs({2, 1, 1}).FrameDiffs({1});
|
||||
t[2].S(0).T(1).Dtis("-D----").ChainDiffs({3, 2, 1}).FrameDiffs({3});
|
||||
t[5].S(1).T(1).Dtis("---D--").ChainDiffs({4, 3, 2}).FrameDiffs({3});
|
||||
t[8].S(2).T(1).Dtis("-----D").ChainDiffs({5, 4, 3}).FrameDiffs({3});
|
||||
t[0].S(0).T(0).Dtis("SS----").ChainDiffs({6, 5, 4}).FrameDiffs({6});
|
||||
t[3].S(1).T(0).Dtis("--SS--").ChainDiffs({1, 6, 5}).FrameDiffs({6});
|
||||
t[6].S(2).T(0).Dtis("----SS").ChainDiffs({2, 1, 6}).FrameDiffs({6});
|
||||
return structure;
|
||||
}
|
||||
|
||||
ScalabilityStructureL3T3Key::~ScalabilityStructureL3T3Key() = default;
|
||||
|
||||
FrameDependencyStructure ScalabilityStructureL3T3Key::DependencyStructure()
|
||||
|
||||
Reference in New Issue
Block a user