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

Use preview Timings for FreePlay Song Preview #2729

Closed
wants to merge 1 commit into from

Conversation

PurSnake
Copy link
Contributor

@PurSnake PurSnake commented Jun 9, 2024

This pr makes previewTimings not useless
and makes preview louder, I can’t hear a damn thing.

This pr makes previewTimings not useless
and makes preview louder, I can’t hear a damn thing.
@PurSnake PurSnake changed the title Use previewTimings for FreePlay Song Preview Use preview Timings for FreePlay Song Preview Jun 9, 2024
@ninjamuffin99
Copy link
Member

FlxPartialSound doesn't get audio based off millisecond/second timing, but rather it gets the audio based on bytes and byte positions. the 0.05 start and 0.25 end refer to getting all the bytes between 5% into the song, and 25% into the song. Getting the actual second based time from a slice of bytes is a bit more complicated than just using these values, since we parse the MP3 + OGG "frames" directly, which both could have varying bitrates or sample rates that you'd have to figure out.

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.

2 participants