-
Notifications
You must be signed in to change notification settings - Fork 56
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
Very beginning of audio cut off #88
Comments
Hey, are we talking milliseconds at the start of the audio file? I just listened to the two files you above and barely noticed a difference. I tested this with a drum beat loop sample taken from loopazon - uploaded sample files here I'm not sure if it's a bug on AudioFileStreamServices or a bug in this library will investigate. Thanks for raising this |
Sorry for the confusion. I'll clarify. The issue is talking about the beginning being cut off of a song file, not the beginning the the files I linked in the example. The example I gave is gapless playback between 2 songs, so the issue in those files is in the middle (end of one song transitioning into another). I didn't focus on perfectly matching the beginning and end of the 2 files since I was trying to highlight what's happening in the middle. these particular files are made for being gapless (and are FLAC, not mp3 as you were mentioning above) if it helps, below are links to the full songs above, and the third link is both songs transitioning gaplessly (intended effect).
so with that info, listening to the 2 files I initially provided hopefully it makes more sense that its a noticeable difference. the playback does seem to be gapless, but the beginning of the song is being cut off. it also cuts off if I play just the second file alone (so ignoring gapless playback entirely, its just an issue with playing a song itself) |
yes, it seems the issue occurs on FLAC files which as I mentioned is noticeable on the drum beat loops I posted, it makes it easier for debugging. I've also played the files on a private project which uses |
What’s interesting is that AVQueuePlayer (a subclass of AVPlayer) handles it perfectly, but sadly has quite a few limitations. Even setting up a queue myself and using AVPlayer doesnt work, let alone AVAudioEngine I wish we knew the inner workings of AVQueuePlayer! |
I can't pinpoint to where this issue lies and how to resolve it, I'll keep looking at it. I also have plans, time permitting to include an API similar to AVQueuePlayer, but I have limited time at the moment |
@hell001 This should be fixed on version 1.2.4, can you test with your audio files? thanks |
Same issue as in StreamingKit, which I believe this project takes inspiration from
Just using the basic syntax for now:
or
Running this will cause the very beginning of the audio to be chopped off. So like, it starts playing just barely into the song rather than the actual beginning. This also poses an issue for gapless playback, since it is not seamless. Only tested on FLAC
Gapless playback example (although this happens when just playing one file as well):
How it's supposed to sound: https://voca.ro/12qDs9q4ApSZ
How it does sound: https://voca.ro/1hAYzsF8paPl
The text was updated successfully, but these errors were encountered: