Re: [mediacapture-region] What makes CropTarget special to require an asynchronous creation? (#17)

> @yoavweiss I'm hearing vastly differing claims about what [produceCropTarget]( needs to do that aren't supported by the spec: The spec says: _"Calling produceCropTarget on an [Element]( of a supported type associates that [Element]( with a [CropTarget]( This [CropTarget]( may be used as input to [cropTo]("_
> That's literally all it says: create an association between an interface that cannot be serialized with one that can.
> Clicking on [CropTarget]( confirms this: _"CropTarget is an intentionally empty, opaque identifier that exposes nothing. Its sole purpose is to be handed to [cropTo]( as input."_ — Nothing about cropping, preparing for cropping, IPC, render processes, or any failures. It's infallible and serializable, that's all.

The current processing model seems indeed insufficient in describing what current implementations are doing (or planning to do). I sent to clarify that part and make it (hopefully) more rigorous.

> There's no reason this needs to be asynchronous. We've had experienced Google folks suggest be used instead — a proposal that fell for other reasons — but being synchronous never came up.

I [beg to differ]( on that last part.

> I agree with @youennf we need to go back to the drawing board if Chrome has vastly different ideas for this than what they've proposed for standardization

I don't believe that's the case. I provided spec clarifications at in the hope that they'd help bridge our common understanding.

> I can think of no reason why this needs to be async

See [my comment above](

> Asynchronous API's come at a cost to web developers, as they turn JavaScript into a pre-emptive language.

Understood. At the same time, there's [general agreement]( that when locks or IPC calls are involved, async APIs are called for. I'd also like to stress out (again) that the TAG [did not find the burden significant]( in this particular case.

GitHub Notification of comment by yoavweiss
Please view or discuss this issue at using your GitHub account

Sent via github-notify-ml as configured in

Received on Thursday, 19 May 2022 10:03:50 UTC