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

Convert underlying wave buffer to be uint8 #212

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

lherman-cs
Copy link
Member

@lherman-cs lherman-cs commented Sep 7, 2020

This follows image package from the standard library. By having a homogenous data type for storing the samples, it makes easier to manipulate the raw data in a generic way.

The main motivation of doing this is so that we can have ChunkBuffer similar to what we have for images, #209. If we had different data types to store the samples, we need to have multiple slices with different data types or we need to use unsafe to remove the type safety (which is not recommended generally).

This approach is inspired by https://golang.org/src/image/image.go?s=12897:12943#L428.

@lherman-cs lherman-cs marked this pull request as draft September 7, 2020 06:24
@lherman-cs lherman-cs marked this pull request as ready for review September 25, 2020 06:23
This follows image package from the standard library.
By having a homogenous data type for storing the samples,
it makes easier to manipulate the raw data in a generic way.
@edaniels
Copy link
Member

edaniels commented Mar 3, 2023

@lherman-cs do you still want to get this in?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants