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

Bug: trying to play StreamingSoundData with ogg may cause AudioManager::play and subsequent operations to fail #96

Open
Kolsky opened this issue May 27, 2024 · 0 comments

Comments

@Kolsky
Copy link

Kolsky commented May 27, 2024

The offender

This probably should've been reported to Symphonia instead, as it seems to be the source of the problem, but nevertheless it was first discovered indirectly (it's not clear who is responsible in this scenario), and a second issue was found later on.

This must be related to pdeljanov/Symphonia#207. When I try to play file using StaticSoundData, it's fine, I assume because it's fully decoded and normalized. When I try to play the same file using StreamingSoundData, it fails, and the source of error tracks down to this line in demuxer.rs. Adding .start_position(Samples(1024)) does "fix" the issue, but trying to seek to 0 manually later fails again and stops the audio (probably the right thing to do, given eb3cd09).

rodio in these scenarios either returns Err on Decoder creation with the cryptic end of stream message, or if it succeeds, trying to seek could result in an internal panic (happened at least once).

It's not at all clear how to get this start_ts to skip decoding the unnecessary part entirely, or how to remove it from the audio with ffmpeg too.

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