handle property
The handle
read-only property of the MediaSource interface returns
a MediaSourceHandle object, a proxy for the MediaSource
that can be
transferred from a dedicated worker back to the main thread and attached
to a media element via its HTMLMediaElement.srcObject property.
Note:
handle
is only visible on MediaSource instances inside dedicated workers.
Each MediaSource
object created inside a dedicated worker has its own
distinct MediaSourceHandle
. The handle
getter will always return the
MediaSourceHandle
instance specific to the associated dedicated worker
MediaSource
instance. If the handle has already been transferred to the
main thread using DedicatedWorkerGlobalScope.postMessage, the handle
instance in the worker is technically detached and can't be transferred
again.
Implementation
external MediaSourceHandle get handle;