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

Enhancement: Implement pitch and speed variables for FlxSound #2362

Closed
CyndaquilDAC opened this issue Jul 28, 2021 · 7 comments
Closed

Enhancement: Implement pitch and speed variables for FlxSound #2362

CyndaquilDAC opened this issue Jul 28, 2021 · 7 comments

Comments

@CyndaquilDAC
Copy link
Contributor

I really don't know how difficult this would be to add, but it would be useful for saving storage space and just generally a helpful tool for game development.

@Cheemsandfriends
Copy link
Contributor

Cheemsandfriends commented Dec 29, 2021

I think that what really depends it is on lime to add a solid Pitch changing thing.
ninjamuffin made a PR about setting the pitch in html5 and Desktop, And I made a PR today about some rough code with changing the timer when the pitch is changed.

it could be possible, of course! but it would require some tweaking and stuff

@EliteMasterEric
Copy link
Contributor

The requisite commit (openfl/lime@e6674ba) has been merged, so this feature is feasible to implement into Flixel 5.0.

@Geokureli
Copy link
Member

#2564
it's expected for 5.0.0, but it's not a breaking change so it can happen any time. not sure when lime will release the change

@ninjamuffin99
Copy link
Member

I believe this issue should be closed since #2564 was merged

@EliteMasterEric
Copy link
Contributor

I don't see any option for playback speed unless I am missing something

@ninjamuffin99
Copy link
Member

I don't see any option for playback speed unless I am missing something

i believe that changing the pitch changes the playback speed.
funnySound.pitch = 2; Would double the pitch, so the sound will place twice as fast, since really changing the pitch sorta just "squishes" the sound wave. At least I believe that's how sound works hehehe (peep dis one: https://youtu.be/i09V6SkVkz8)

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

No branches or pull requests

6 participants
@Geokureli @EliteMasterEric @ninjamuffin99 @CyndaquilDAC @Cheemsandfriends and others