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

OGG SoundDuration Support #6089

Open
Cpt-Hazama opened this issue Nov 22, 2024 · 0 comments
Open

OGG SoundDuration Support #6089

Cpt-Hazama opened this issue Nov 22, 2024 · 0 comments

Comments

@Cpt-Hazama
Copy link

For years, SoundDuration hasn't properly supported OGG files. OGG files are integral for optimization in an addon, and the worst part of this is when systems rely heavily on SoundDuration for sound timers and they get messed up when using OGG files.

While I don't have access to the source code to confirm the exact cause, my best guess based on my own tests, is that it's failing to extract or process the sample rate and granule position stored within OGG file headers.

In lua, I put together a VERY ugly code to properly calculate the sound duration for OGG files. However because Im doing this through lua, it is extremely hard on the game and causes lag spikes every time it runs: https://github.com/Cpt-Hazama/SoundDuration-OGG-Solution/blob/master/lua/autorun/ogg.solution.lua

The referenced code isn't a genuine solution, just a proof of concept. Again if I had to guess its probably just because there is no actual checks for OGG files specifically. An implemented fix into the source code would be greatly appreciated!

Image

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

No branches or pull requests

1 participant