Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow transferring ArrayBuffer into WebCodecs object constructors #889

Closed
Djuffin opened this issue Aug 30, 2023 · 3 comments
Closed

Allow transferring ArrayBuffer into WebCodecs object constructors #889

Djuffin opened this issue Aug 30, 2023 · 3 comments
Assignees
Labels
Progress: propose closing we think it should be closed but are waiting on some feedback or consensus Resolution: satisfied The TAG is satisfied with this design Review type: Already shipped Already shipped in at least one browser Topic: media Venue: Media WG

Comments

@Djuffin
Copy link

Djuffin commented Aug 30, 2023

こんにちは TAG-さん!

I'm requesting a TAG review of "Allow transferring ArrayBuffer into WebCodecs object constructors".

We're working on adding transferable buffers to WebCodecs object constructors.
We've copied the transfer-list approach used by structuredClone and postMessage.

However a concern have been raised that this mechanism isn't ideal:
Should we just use a boolean value instead of a transfer list to indicate transferring of the ArrayBuffer contents to a WebCodecs object.
Arguments:

  • Boolean is easier to use and understand for API users.
  • Transfer list can be extended in the future when WebCodec objects need to transfer more than one ArrayBuffer ( we are likely to accept arrays of metadata, HDR data, etc. )
  • Transfer list is consistent with existing APIs like structuredClone and postMessage.

We've been asked to solicit TAG guidance on whether copying this mechanism is appropriate in terms of TAG principles around consistency.

Further details:

  • [x ] I have reviewed the TAG's Web Platform Design Principles
  • The group where the work on this specification is currently being done: Media Working Group

We'd prefer the TAG provide feedback as (please delete all but the desired option):

💬 leave review feedback as a comment in this issue and @-notify @Djuffin

@torgo torgo added Topic: media Missing: Multi-stakeholder support Lack of multi-stakeholder support labels Oct 11, 2023
@torgo torgo added this to the 2023-10-16-week milestone Oct 11, 2023
@torgo torgo modified the milestones: 2023-10-16-week, 2023-12-11-week Dec 6, 2023
@torgo torgo assigned maxpassion and unassigned cynthia Mar 11, 2024
@torgo torgo added Review type: Already shipped Already shipped in at least one browser and removed Missing: Multi-stakeholder support Lack of multi-stakeholder support labels Mar 11, 2024
@torgo
Copy link
Member

torgo commented Mar 11, 2024

Hi @Djuffin

My apologies it's taken us so long to get back to you on this. I realize things may have moved on significantly since you filed this review. We did have a fairly detailed discussion on this review in October but unfortunately the output didn't make its way into this issue. Specifically you've asked "Should we just use a boolean value instead of a transfer list to indicate transferring of the ArrayBuffer contents to a WebCodecs object". In the absence of our feedback have you made any decision in the group thus-far on this? In any case, we don't see any issues and we're happy with the multi-stakeholder story here.

@torgo torgo added the Progress: propose closing we think it should be closed but are waiting on some feedback or consensus label Mar 11, 2024
@Djuffin
Copy link
Author

Djuffin commented Mar 11, 2024

Thank you!

The change has been merged to the webcodecs spec and released in Chromium

@torgo
Copy link
Member

torgo commented Mar 18, 2024

Thanks @Djuffin we're happy to close on this basis.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Progress: propose closing we think it should be closed but are waiting on some feedback or consensus Resolution: satisfied The TAG is satisfied with this design Review type: Already shipped Already shipped in at least one browser Topic: media Venue: Media WG
Projects
None yet
Development

No branches or pull requests

5 participants