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

Fix: Update AudioBuffer parameters to remove deprecated options #36562

Merged

Conversation

FizanMuhammedFaisal
Copy link
Contributor

Summary of Changes

  • Updated the AudioBuffer documentation to remove deprecated parameters (channelCount, channelCountMode, channelInterpretation, context).
  • Clarified the usage of current parameters.

Reason for Change

The deprecated parameters were causing confusion, and removing them helps to clarify the expected usage of the AudioBuffer constructor.

Related Issues

Motivation

The issue was put up by a reader knowledgeable about the topic, so I looked it up and fixed it.

Additional Details

  • Reviewed the latest specifications to ensure accuracy.
  • Confirmed that the updated parameters are accurately reflected in the examples.

current AudioBufferOptions: https://webaudio.github.io/web-audio-api/#AudioBufferOptions
current options(AudioBufferOptions) of AudioBuffer constructor in mdn web docs: https://developer.mozilla.org/en-US/docs/Web/API/AudioBuffer/AudioBuffer#options

Testing

  • I reviewed the relevant documentation and confirmed that the updated parameters are accurately reflected.

Impact

These changes do not affect any existing functionality but clarify the documentation for future contributors.

Feedback Request

I’d appreciate any feedback on the clarity of the changes made to the documentation.

@FizanMuhammedFaisal FizanMuhammedFaisal requested a review from a team as a code owner October 29, 2024 14:27
@FizanMuhammedFaisal FizanMuhammedFaisal requested review from wbamberg and removed request for a team October 29, 2024 14:27
@github-actions github-actions bot added Content:WebAPI Web API docs size/s [PR only] 6-50 LoC changed labels Oct 29, 2024
Copy link
Contributor

github-actions bot commented Oct 29, 2024

Preview URLs

(comment last updated: 2024-10-29 17:27:09)

Copy link
Collaborator

@wbamberg wbamberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would just delete these three options, and the context option as well for that matter. I can't find any references to them in the specs. #36555 points out that there used to be a gain attribute, and that perhaps they were used for initializing that, but this also seems to be long gone.

cc @chrisdavidmills who knows about Web Audio.

@FizanMuhammedFaisal
Copy link
Contributor Author

FizanMuhammedFaisal commented Oct 29, 2024

@wbamberg so I could just remove the "Deprecated parameters' section. Like you said

@wbamberg
Copy link
Collaborator

@wbamberg so I could just remove the "Deprecated parameters' section. Like you said

Yes, I think so!

@FizanMuhammedFaisal
Copy link
Contributor Author

@wbamberg so could you please check the pull request I have made the changes

Copy link
Collaborator

@wbamberg wbamberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 thank you @FizanMuhammedFaisal !

@wbamberg wbamberg merged commit 8cf2239 into mdn:main Oct 29, 2024
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Content:WebAPI Web API docs size/s [PR only] 6-50 LoC changed
Projects
None yet
2 participants