1
+ Updating depot_tools...
1
2
diff --git a/call/rtp_payload_params.cc b/call/rtp_payload_params.cc
2
- index 33e9c7666e..dcd0da8650 100644
3
+ index acc9e3ca18..dd47ff57f3 100644
3
4
--- a/call/rtp_payload_params.cc
4
5
+++ b/call/rtp_payload_params.cc
5
- @@ -316 ,7 +316 ,7 @@ void RtpPayloadParams::SetGeneric(const CodecSpecificInfo* codec_specific_info,
6
+ @@ -330 ,7 +330 ,7 @@ void RtpPayloadParams::SetGeneric(const CodecSpecificInfo* codec_specific_info,
6
7
chains_calculator_.Reset(
7
8
codec_specific_info->generic_frame_info->part_of_chain);
8
9
}
@@ -11,7 +12,7 @@ index 33e9c7666e..dcd0da8650 100644
11
12
*codec_specific_info->generic_frame_info, frame_id);
12
13
return;
13
14
}
14
- @@ -420 ,7 +420 ,7 @@ void RtpPayloadParams::GenericToGeneric(int64_t frame_id,
15
+ @@ -438 ,7 +438 ,7 @@ void RtpPayloadParams::GenericToGeneric(int64_t frame_id,
15
16
bool is_keyframe,
16
17
RTPVideoHeader* rtp_video_header) {
17
18
RTPVideoHeader::GenericDescriptorInfo& generic =
@@ -20,7 +21,7 @@ index 33e9c7666e..dcd0da8650 100644
20
21
21
22
generic.frame_id = frame_id;
22
23
generic.decode_target_indications.push_back(DecodeTargetIndication::kSwitch);
23
- @@ -453 ,7 +453 ,7 @@ void RtpPayloadParams::H264ToGeneric(const CodecSpecificInfoH264& h264_info,
24
+ @@ -471 ,7 +471 ,7 @@ void RtpPayloadParams::H264ToGeneric(const CodecSpecificInfoH264& h264_info,
24
25
}
25
26
26
27
RTPVideoHeader::GenericDescriptorInfo& generic =
@@ -29,7 +30,7 @@ index 33e9c7666e..dcd0da8650 100644
29
30
30
31
generic.frame_id = frame_id;
31
32
generic.temporal_index = temporal_index;
32
- @@ -509 ,7 +509 ,7 @@ void RtpPayloadParams::Vp8ToGeneric(const CodecSpecificInfoVP8& vp8_info,
33
+ @@ -535 ,7 +535 ,7 @@ void RtpPayloadParams::Vp8ToGeneric(const CodecSpecificInfoVP8& vp8_info,
33
34
}
34
35
35
36
RTPVideoHeader::GenericDescriptorInfo& generic =
@@ -38,7 +39,7 @@ index 33e9c7666e..dcd0da8650 100644
38
39
39
40
generic.frame_id = frame_id;
40
41
generic.spatial_index = spatial_index;
41
- @@ -578 ,7 +578 ,7 @@ void RtpPayloadParams::Vp9ToGeneric(const CodecSpecificInfoVP9& vp9_info,
42
+ @@ -604 ,7 +604 ,7 @@ void RtpPayloadParams::Vp9ToGeneric(const CodecSpecificInfoVP9& /* vp9_info */ ,
42
43
}
43
44
44
45
RTPVideoHeader::GenericDescriptorInfo& result =
@@ -47,7 +48,7 @@ index 33e9c7666e..dcd0da8650 100644
47
48
48
49
result.frame_id = frame_id;
49
50
result.spatial_index = spatial_index;
50
- @@ -643 ,7 +643 ,7 @@ void RtpPayloadParams::Vp9ToGeneric(const CodecSpecificInfoVP9& vp9_info,
51
+ @@ -669 ,7 +669 ,7 @@ void RtpPayloadParams::Vp9ToGeneric(const CodecSpecificInfoVP9& /* vp9_info */ ,
51
52
// non-layerd streams.
52
53
if (spatial_index > 0 || temporal_index > 0) {
53
54
// Prefer to generate no generic layering than an inconsistent one.
@@ -75,10 +76,25 @@ index f4525f0db1..eadbae52eb 100644
75
76
if (descriptor.spatial_index < 0 || descriptor.temporal_index < 0 ||
76
77
descriptor.spatial_index >=
77
78
diff --git a/modules/rtp_rtcp/source/rtp_sender_video.cc b/modules/rtp_rtcp/source/rtp_sender_video.cc
78
- index ebca7aaa75..ce5e224a9f 100644
79
+ index 8a21d0523f..06b99a6b9c 100644
79
80
--- a/modules/rtp_rtcp/source/rtp_sender_video.cc
80
81
+++ b/modules/rtp_rtcp/source/rtp_sender_video.cc
81
- @@ -121,9 +121,9 @@ absl::optional<VideoPlayoutDelay> LoadVideoPlayoutDelayOverride(
82
+ @@ -103,10 +103,10 @@ bool MinimizeDescriptor(RTPVideoHeader* video_header) {
83
+
84
+ bool IsBaseLayer(const RTPVideoHeader& video_header) {
85
+ // For AV1 & H.265 we fetch temporal index from the generic descriptor.
86
+ - if (video_header.generic) {
87
+ - const auto& generic = video_header.generic.value();
88
+ - return (generic.temporal_index == 0 ||
89
+ - generic.temporal_index == kNoTemporalIdx);
90
+ + if (video_header.generic_) {
91
+ + const auto& generic_ = video_header.generic_.value();
92
+ + return (generic_.temporal_index == 0 ||
93
+ + generic_.temporal_index == kNoTemporalIdx);
94
+ }
95
+ switch (video_header.codec) {
96
+ case kVideoCodecVP8: {
97
+ @@ -152,9 +152,9 @@ std::optional<VideoPlayoutDelay> LoadVideoPlayoutDelayOverride(
82
98
bool PacketWillLikelyBeRequestedForRestransmissionIfLost(
83
99
const RTPVideoHeader& video_header) {
84
100
return IsBaseLayer(video_header) &&
@@ -90,7 +106,7 @@ index ebca7aaa75..ce5e224a9f 100644
90
106
DecodeTargetIndication::kDiscardable)
91
107
: false);
92
108
}
93
- @@ -358 ,26 +358 ,26 @@ void RTPSenderVideo::AddRtpHeaderExtensions(const RTPVideoHeader& video_header,
109
+ @@ -391 ,26 +391 ,26 @@ void RTPSenderVideo::AddRtpHeaderExtensions(const RTPVideoHeader& video_header,
94
110
*video_header.absolute_capture_time);
95
111
}
96
112
@@ -125,7 +141,7 @@ index ebca7aaa75..ce5e224a9f 100644
125
141
RTC_DCHECK_EQ(
126
142
descriptor.frame_dependencies.decode_target_indications.size(),
127
143
video_structure_->num_decode_targets);
128
- @@ -392 ,7 +392 ,7 @@ void RTPSenderVideo::AddRtpHeaderExtensions(const RTPVideoHeader& video_header,
144
+ @@ -425 ,7 +425 ,7 @@ void RTPSenderVideo::AddRtpHeaderExtensions(const RTPVideoHeader& video_header,
129
145
// layers when inter layer dependency is not used, i.e. S structures.
130
146
// Distinguish these two cases by checking if there are any dependencies.
131
147
if (video_header.frame_type == VideoFrameType::kVideoFrameKey &&
@@ -134,7 +150,7 @@ index ebca7aaa75..ce5e224a9f 100644
134
150
// To avoid extra structure copy, temporary share ownership of the
135
151
// video_structure with the dependency descriptor.
136
152
descriptor.attached_structure =
137
- @@ -415 ,17 +415 ,17 @@ void RTPSenderVideo::AddRtpHeaderExtensions(const RTPVideoHeader& video_header,
153
+ @@ -448 ,17 +448 ,17 @@ void RTPSenderVideo::AddRtpHeaderExtensions(const RTPVideoHeader& video_header,
138
154
139
155
if (first_packet) {
140
156
generic_descriptor.SetFrameId(
@@ -157,7 +173,7 @@ index ebca7aaa75..ce5e224a9f 100644
157
173
158
174
if (video_header.frame_type == VideoFrameType::kVideoFrameKey) {
159
175
generic_descriptor.SetResolution(video_header.width,
160
- @@ -504 ,12 +504 ,12 @@ bool RTPSenderVideo::SendVideo(int payload_type,
176
+ @@ -557 ,12 +557 ,12 @@ bool RTPSenderVideo::SendVideo(int payload_type,
161
177
}
162
178
}
163
179
@@ -174,7 +190,7 @@ index ebca7aaa75..ce5e224a9f 100644
174
190
175
191
// No FEC protection for upper temporal layers, if used.
176
192
diff --git a/modules/rtp_rtcp/source/rtp_video_header.cc b/modules/rtp_rtcp/source/rtp_video_header.cc
177
- index b07a7beec4..16b1c94a74 100644
193
+ index 558b58289a..4feb91da72 100644
178
194
--- a/modules/rtp_rtcp/source/rtp_video_header.cc
179
195
+++ b/modules/rtp_rtcp/source/rtp_video_header.cc
180
196
@@ -36,12 +36,12 @@ VideoFrameMetadata RTPVideoHeader::GetAsMetadata() const {
@@ -196,12 +212,12 @@ index b07a7beec4..16b1c94a74 100644
196
212
}
197
213
metadata.SetIsLastFrameInPicture(is_last_frame_in_picture);
198
214
metadata.SetSimulcastIdx(simulcastIdx);
199
- @@ -73 ,15 +73 ,15 @@ void RTPVideoHeader::SetFromMetadata(const VideoFrameMetadata& metadata) {
215
+ @@ -75 ,15 +75 ,15 @@ void RTPVideoHeader::SetFromMetadata(const VideoFrameMetadata& metadata) {
200
216
rotation = metadata.GetRotation();
201
217
content_type = metadata.GetContentType();
202
218
if (!metadata.GetFrameId().has_value()) {
203
- - generic = absl ::nullopt;
204
- + generic_ = absl ::nullopt;
219
+ - generic = std ::nullopt;
220
+ + generic_ = std ::nullopt;
205
221
} else {
206
222
- generic.emplace();
207
223
- generic->frame_id = metadata.GetFrameId().value();
@@ -220,23 +236,23 @@ index b07a7beec4..16b1c94a74 100644
220
236
metadata.GetDecodeTargetIndications().end());
221
237
}
222
238
diff --git a/modules/rtp_rtcp/source/rtp_video_header.h b/modules/rtp_rtcp/source/rtp_video_header.h
223
- index d185c20c83..57e5627466 100644
239
+ index 8bf17fcb35..e0fb156348 100644
224
240
--- a/modules/rtp_rtcp/source/rtp_video_header.h
225
241
+++ b/modules/rtp_rtcp/source/rtp_video_header.h
226
- @@ -69 ,7 +69 ,7 @@ struct RTPVideoHeader {
242
+ @@ -70 ,7 +70 ,7 @@ struct RTPVideoHeader {
227
243
VideoFrameMetadata GetAsMetadata() const;
228
244
void SetFromMetadata(const VideoFrameMetadata& metadata);
229
245
230
- - absl ::optional<GenericDescriptorInfo> generic;
231
- + absl ::optional<GenericDescriptorInfo> generic_;
246
+ - std ::optional<GenericDescriptorInfo> generic;
247
+ + std ::optional<GenericDescriptorInfo> generic_;
232
248
233
249
VideoFrameType frame_type = VideoFrameType::kEmptyFrame;
234
250
uint16_t width = 0;
235
251
diff --git a/modules/video_coding/packet_buffer.cc b/modules/video_coding/packet_buffer.cc
236
- index 52ef5c2d85..0dc71c7029 100644
252
+ index 9d7b6e550c..2f3c42acfd 100644
237
253
--- a/modules/video_coding/packet_buffer.cc
238
254
+++ b/modules/video_coding/packet_buffer.cc
239
- @@ -256 ,7 +256 ,7 @@ std::vector<std::unique_ptr<PacketBuffer::Packet>> PacketBuffer::FindFrames(
255
+ @@ -268 ,7 +268 ,7 @@ std::vector<std::unique_ptr<PacketBuffer::Packet>> PacketBuffer::FindFrames(
240
256
int64_t frame_timestamp = buffer_[start_index]->timestamp;
241
257
242
258
// Identify H.264 keyframes by means of SPS, PPS, and IDR.
@@ -245,8 +261,17 @@ index 52ef5c2d85..0dc71c7029 100644
245
261
bool is_h264_descriptor =
246
262
(buffer_[start_index]->codec() == kVideoCodecH264) && !is_generic;
247
263
bool has_h264_sps = false;
264
+ @@ -282,7 +282,7 @@ std::vector<std::unique_ptr<PacketBuffer::Packet>> PacketBuffer::FindFrames(
265
+ // GFD is only attached to first packet of frame, so update check on
266
+ // every packet.
267
+ if (buffer_[start_index] != nullptr) {
268
+ - is_generic = buffer_[start_index]->video_header.generic.has_value();
269
+ + is_generic = buffer_[start_index]->video_header.generic_.has_value();
270
+ if (is_generic) {
271
+ is_h264_descriptor = false;
272
+ }
248
273
diff --git a/modules/video_coding/rtp_frame_reference_finder.cc b/modules/video_coding/rtp_frame_reference_finder.cc
249
- index a44b76bf15..695e161ba6 100644
274
+ index b73fcfe9d5..4f818263f5 100644
250
275
--- a/modules/video_coding/rtp_frame_reference_finder.cc
251
276
+++ b/modules/video_coding/rtp_frame_reference_finder.cc
252
277
@@ -48,9 +48,9 @@ RtpFrameReferenceFinder::ReturnVector RtpFrameReferenceFinderImpl::ManageFrame(
@@ -262,10 +287,10 @@ index a44b76bf15..695e161ba6 100644
262
287
263
288
switch (frame->codec_type()) {
264
289
diff --git a/video/rtp_video_stream_receiver2.cc b/video/rtp_video_stream_receiver2.cc
265
- index e875a5e109..fffcf92bcb 100644
290
+ index c0b2001b13..25088f1562 100644
266
291
--- a/video/rtp_video_stream_receiver2.cc
267
292
+++ b/video/rtp_video_stream_receiver2.cc
268
- @@ -433 ,7 +433 ,7 @@ RtpVideoStreamReceiver2::ParseGenericDependenciesExtension(
293
+ @@ -430 ,7 +430 ,7 @@ RtpVideoStreamReceiver2::ParseGenericDependenciesExtension(
269
294
video_header->is_last_packet_in_frame =
270
295
dependency_descriptor.last_packet_in_frame;
271
296
@@ -274,7 +299,7 @@ index e875a5e109..fffcf92bcb 100644
274
299
generic_descriptor_info.frame_id = frame_id;
275
300
generic_descriptor_info.spatial_index =
276
301
dependency_descriptor.frame_dependencies.spatial_id;
277
- @@ -490 ,7 +490 ,7 @@ RtpVideoStreamReceiver2::ParseGenericDependenciesExtension(
302
+ @@ -487 ,7 +487 ,7 @@ RtpVideoStreamReceiver2::ParseGenericDependenciesExtension(
278
303
? VideoFrameType::kVideoFrameKey
279
304
: VideoFrameType::kVideoFrameDelta;
280
305
@@ -283,7 +308,18 @@ index e875a5e109..fffcf92bcb 100644
283
308
int64_t frame_id =
284
309
frame_id_unwrapper_.Unwrap(generic_frame_descriptor.FrameId());
285
310
generic_descriptor_info.frame_id = frame_id;
286
- @@ -620,12 +620,12 @@ bool RtpVideoStreamReceiver2::OnReceivedPayloadData(
311
+ @@ -620,8 +620,8 @@ bool RtpVideoStreamReceiver2::OnReceivedPayloadData(
312
+ }
313
+
314
+ std::optional<int> spatial_id;
315
+ - if (video_header.generic.has_value()) {
316
+ - spatial_id = video_header.generic->spatial_index;
317
+ + if (video_header.generic_.has_value()) {
318
+ + spatial_id = video_header.generic_->spatial_index;
319
+ if (spatial_id >= kMaxSpatialLayers) {
320
+ RTC_LOG(LS_WARNING) << "Invalid spatial id: " << *spatial_id
321
+ << ". Ignoring corruption detection mesaage.";
322
+ @@ -676,12 +676,12 @@ bool RtpVideoStreamReceiver2::OnReceivedPayloadData(
287
323
"frame descriptor, but it is missing.";
288
324
} else {
289
325
if (video_header.is_first_packet_in_frame) {
@@ -299,10 +335,10 @@ index e875a5e109..fffcf92bcb 100644
299
335
loss_notification_controller_->OnReceivedPacket(
300
336
rtp_packet.SequenceNumber(), &frame);
301
337
} else {
302
- @@ -838 ,7 +838 ,7 @@ void RtpVideoStreamReceiver2::OnAssembledFrame(
338
+ @@ -895 ,7 +895 ,7 @@ void RtpVideoStreamReceiver2::OnAssembledFrame(
303
339
RTC_DCHECK(frame);
304
340
305
- const absl ::optional<RTPVideoHeader::GenericDescriptorInfo>& descriptor =
341
+ const std ::optional<RTPVideoHeader::GenericDescriptorInfo>& descriptor =
306
342
- frame->GetRtpVideoHeader().generic;
307
343
+ frame->GetRtpVideoHeader().generic_;
308
344
0 commit comments