From 54b82fdf77de5d10216763b2df3fdefdbe072480 Mon Sep 17 00:00:00 2001
From: Palak Agarwal
+ The RTP timestamp identifier is an unsigned integer value per [[RFC3550]] + that reflects the sampling instant of the first octet in the RTP data packet. +
+- The RTP timestamp identifier is an unsigned integer value per [[RFC3550]] - that reflects the sampling instant of the first octet in the RTP data packet. -
-+ Sets a new metadata that would be associated with the frame. +
+
[Exposed=(Window,DedicatedWorker)]
interface RTCEncodedAudioFrame {
- readonly attribute unsigned long timestamp;
+ attribute unsigned long timestamp;
attribute ArrayBuffer data;
RTCEncodedAudioFrameMetadata getMetadata();
};
From 05d28f7b6ff0778ed8dbcf3ce448a2e5416be3c8 Mon Sep 17 00:00:00 2001
From: Palak Agarwal
Date: Thu, 3 Aug 2023 13:35:34 +0200
Subject: [PATCH 02/10] Change dfn tag
---
index.bs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/index.bs b/index.bs
index ebd9b57..9735039 100644
--- a/index.bs
+++ b/index.bs
@@ -376,7 +376,7 @@ dictionary RTCEncodedVideoFrameMetadata {
- rtpTimestamp of type unsigned long
+ rtpTimestamp of type unsigned long
@@ -386,7 +386,7 @@ dictionary RTCEncodedVideoFrameMetadata {
- presentationTimestamp of type presentationTimestamp of type long long
From 6120dcee8d97bf3c1ff31cf13cb52a81d6b40f89 Mon Sep 17 00:00:00 2001
From: Palak Agarwal
Date: Fri, 4 Aug 2023 14:31:44 +0200
Subject: [PATCH 03/10] Remove restriction on streams being limited to only one
PC
---
index.bs | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/index.bs b/index.bs
index 9735039..8587c0e 100644
--- a/index.bs
+++ b/index.bs
@@ -121,7 +121,7 @@ The readEncodedData algorithm is given a |rtcObject| as p
1. [=ReadableStream/Enqueue=] |frame| in |rtcObject|.`[[readable]]`.
The writeEncodedData algorithm is given a |rtcObject| as parameter and a |frame| as input. It is defined by running the following steps:
-1. If |frame|.`[[owner]]` is not equal to |rtcObject|, abort these steps and return [=a promise resolved with=] undefined. A processor cannot create frames, or move frames between streams.
+1. If |frame|.`[[owner]]` is not equal to |rtcObject|, skip to step 4. In this case, either frames were created or moved between streams.
1. If |frame|.`[[counter]]` is equal or smaller than |rtcObject|.`[[lastReceivedFrameCounter]]`, abort these steps and return [=a promise resolved with=] undefined. A processor cannot reorder frames, although it may delay them or drop them.
1. Set |rtcObject|.`[[lastReceivedFrameCounter]]` to |frame|`[[counter]]`.
1. Let |data| be |frame|.`[[data]]`.
@@ -448,7 +448,9 @@ interface RTCEncodedVideoFrame {
- Sets a new metadata that would be associated with the frame.
+ Sets a new metadata that would be associated with the frame. Only allowed to change the fields
+ frameId, dependencies and rtpTimetsamp in the RTCEncodedVideoFrameMetadata. All other changes
+ are not allowed and should return an error.
From 9eb6c9df4bba1a4a2e6642191c1faa2b2f1ce8e6 Mon Sep 17 00:00:00 2001
From: Palak Agarwal
Date: Tue, 5 Sep 2023 14:16:06 +0200
Subject: [PATCH 04/10] Update index.bs to only include metadata changes
necessary for 3.2.2
---
index.bs | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/index.bs b/index.bs
index 8587c0e..a0139cc 100644
--- a/index.bs
+++ b/index.bs
@@ -121,7 +121,7 @@ The readEncodedData algorithm is given a |rtcObject| as p
1. [=ReadableStream/Enqueue=] |frame| in |rtcObject|.`[[readable]]`.
The writeEncodedData algorithm is given a |rtcObject| as parameter and a |frame| as input. It is defined by running the following steps:
-1. If |frame|.`[[owner]]` is not equal to |rtcObject|, skip to step 4. In this case, either frames were created or moved between streams.
+1. If |frame|.`[[owner]]` is not equal to |rtcObject|, abort these steps and return [=a promise resolved with=] undefined. A processor cannot create frames, or move frames between streams.
1. If |frame|.`[[counter]]` is equal or smaller than |rtcObject|.`[[lastReceivedFrameCounter]]`, abort these steps and return [=a promise resolved with=] undefined. A processor cannot reorder frames, although it may delay them or drop them.
1. Set |rtcObject|.`[[lastReceivedFrameCounter]]` to |frame|`[[counter]]`.
1. Let |data| be |frame|.`[[data]]`.
From c932a82b83a310197108c33c57131ead8917775f Mon Sep 17 00:00:00 2001
From: Palak Agarwal
Date: Tue, 5 Sep 2023 14:25:49 +0200
Subject: [PATCH 05/10] Update index.bs to have consistent defintion for audio
and video
---
index.bs | 31 +++++++++++++++++++++----------
1 file changed, 21 insertions(+), 10 deletions(-)
diff --git a/index.bs b/index.bs
index a0139cc..04e8fcf 100644
--- a/index.bs
+++ b/index.bs
@@ -462,6 +462,7 @@ dictionary RTCEncodedAudioFrameMetadata {
octet payloadType;
sequence<unsigned long> contributingSources;
short sequenceNumber;
+ attribute unsigned long rtpTimestamp;
};
### Members ### {#RTCEncodedAudioFrameMetadata-members}
@@ -505,29 +506,29 @@ dictionary RTCEncodedAudioFrameMetadata {
Comparing two sequence numbers requires serial number arithmetic described in [[RFC1982]].
+ + The RTP timestamp identifier is an unsigned integer value per [[RFC3550]] + that reflects the sampling instant of the first octet in the RTP data packet. +
+
[Exposed=(Window,DedicatedWorker)]
interface RTCEncodedAudioFrame {
- attribute unsigned long timestamp;
attribute ArrayBuffer data;
RTCEncodedAudioFrameMetadata getMetadata();
+ void setMetadata(RTCEncodedAudioFrameMetadata metadata);
};
### Members ### {#RTCEncodedAudioFrame-members}
- The RTP timestamp identifier is an unsigned integer value per [[RFC3550]] - that reflects the sampling instant of the first octet in the RTP data packet. -
-+ Sets a new metadata that would be associated with the frame. Only allowed to change + the rtpTimetsamp field in the RTCEncodedAudioFrameMetadata. All other changes are + not allowed and should return an error. +
+@@ -549,8 +547,6 @@ interface RTCEncodedAudioFrame { Returns the metadata associated with the frame.
dictionary RTCEncodedVideoFrameMetadata {
- unsigned long long frameId;
- sequence<unsigned long long> dependencies;
+ required unsigned long long frameId;
+ required sequence<unsigned long long> dependencies;
unsigned short width;
unsigned short height;
unsigned long spatialIndex;
@@ -340,7 +340,7 @@ dictionary RTCEncodedVideoFrameMetadata {
octet payloadType;
sequence<unsigned long> contributingSources;
long long timestamp; // microseconds
- unsigned long rtpTimestamp;
+ required unsigned long rtpTimestamp;
};
@@ -483,7 +483,7 @@ dictionary RTCEncodedAudioFrameMetadata {
octet payloadType;
sequence<unsigned long> contributingSources;
short sequenceNumber;
- unsigned long rtpTimestamp;
+ required unsigned long rtpTimestamp;
};
### Members ### {#RTCEncodedAudioFrameMetadata-members}
From 0a86a80e3a634d53cd88fd88e95e103bd0f6216b Mon Sep 17 00:00:00 2001
From: Palak Agarwal
dictionary RTCEncodedVideoFrameMetadata {
- required unsigned long long frameId;
- required sequence<unsigned long long> dependencies;
+ unsigned long long frameId;
+ sequence<unsigned long long> dependencies;
unsigned short width;
unsigned short height;
unsigned long spatialIndex;
@@ -340,7 +340,7 @@ dictionary RTCEncodedVideoFrameMetadata {
octet payloadType;
sequence<unsigned long> contributingSources;
long long timestamp; // microseconds
- required unsigned long rtpTimestamp;
+ unsigned long rtpTimestamp;
};
@@ -406,7 +406,7 @@ interface RTCEncodedVideoFrame {
readonly attribute RTCEncodedVideoFrameType type;
attribute ArrayBuffer data;
RTCEncodedVideoFrameMetadata getMetadata();
- undefined setMetadata(required RTCEncodedVideoFrameMetadata metadata);
+ undefined setMetadata(optional RTCEncodedVideoFrameMetadata metadata = {});
};
@@ -483,7 +483,7 @@ dictionary RTCEncodedAudioFrameMetadata {
octet payloadType;
sequence<unsigned long> contributingSources;
short sequenceNumber;
- required unsigned long rtpTimestamp;
+ unsigned long rtpTimestamp;
};
### Members ### {#RTCEncodedAudioFrameMetadata-members}
@@ -544,7 +544,7 @@ dictionary RTCEncodedAudioFrameMetadata {
interface RTCEncodedAudioFrame {
attribute ArrayBuffer data;
RTCEncodedAudioFrameMetadata getMetadata();
- undefined setMetadata(required RTCEncodedAudioFrameMetadata metadata);
+ undefined setMetadata(optional RTCEncodedAudioFrameMetadata metadata = {});
};