[webrtc-rtptransport] Pull Request: Replace ArrayBuffers with BYOB methods/AllowSharedBufferSources

tonyherre has just submitted a new pull request for https://github.com/w3c/webrtc-rtptransport:

== Replace ArrayBuffers with BYOB methods/AllowSharedBufferSources ==
Replace ArrayBuffers in interfaces with "copy*To(AllowSharedBufferSources)" to allow apps to point to Bring Their Own Buffers. Similarly change ArrayBuffers in dictionaries to AllowSharedBufferSources to allow providing ArrayBufferViews point at existing ArrayBuffers. All following the patterns & naming convention ("copyTo") from WebCodecs.

Note the copy() methods need to be synchronous to avoid exposing data races, which needed to be solved by Streams by detaching the buffer synchronously at call time and handing back later, adding a lot of complexity & ruling out SABs and eg writing directly into a WASM memory block.

Fixes #41.

See https://github.com/w3c/webrtc-rtptransport/pull/44


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 3 June 2024 08:41:06 UTC