Skip to content

Commit 2f5b0d8

Browse files
committed
Explicit reject for non video senders/receivers
1 parent 87c59ca commit 2f5b0d8

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

index.bs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -408,6 +408,7 @@ The <dfn attribute for="RTCRtpScriptTransformer">writable</dfn> getter steps are
408408

409409
The <dfn>generate key frame algorithm</dfn>, given |promise|, |encoder| and |rids|, is defined by running these steps:
410410
1. If |encoder| is undefined, reject |promise| with {{InvalidStateError}}, abort these steps.
411+
1. If |encoder| is not processing video frames, reject |promise| with {{InvalidStateError}}, abort these steps.
411412
1. If |rids| is defined, validate each of the RID values in |rids|.
412413
If any RID value is invalid, reject |promise| with {{NotAllowedError}} and abort these steps.
413414
1. Gather a list of video encoders, named |videoEncoders| from |encoder|.
@@ -420,6 +421,7 @@ The <dfn>generate key frame algorithm</dfn>, given |promise|, |encoder| and |rid
420421

421422
The <dfn>send request key frame algorithm</dfn>, given |promise| and |depacketizer|, is defined by running these steps:
422423
1. If |depacketizer| is undefined, reject |promise| with {{InvalidStateError}}, abort these steps.
424+
1. If |depacketizer| is not processing video packets, reject |promise| with {{InvalidStateError}}, abort these steps.
423425
1. If sending a Full Intra Request (FIR) by |depacketizer|'s receiver is not deemed appropriate, [=resolve=] |promise| with undefined and abort these steps.
424426
Section 4.3.1 of [[RFC5104]] provides guidelines of how and when it is appropriate to sending a Full Intra Request.
425427
1. Generate a Full Intra Request (FIR) packet as defined in section 4.3.1 of [[RFC5104]] and send it through |depacketizer|'s receiver.

0 commit comments

Comments
 (0)