Skip to content

Conversation

@madebymozart
Copy link
Collaborator

This addresses and issue where 0 frame from the flushonframe were being called, this causing audio to drop (sometimes)

10-14 09:05:04.351 12339 12339 E AudioStreamInternalPlay_Client: flushFromFrame_l() do not have enough data, safePosition=5760, frameWritten=0

@madebymozart madebymozart requested a review from flamme January 26, 2026 21:53
@madebymozart madebymozart self-assigned this Jan 26, 2026
Copy link
Collaborator

@flamme flamme left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why this will cause glitch? In aaudio framework, if it fails calling flushFromFrame, there is nothing changed.

@madebymozart
Copy link
Collaborator Author

So for some reason, this caused and issue where the audio would just "stop" when switching between songs, but it'd only happen in a couple of occasions.

Since putting this fix in, I haven't heard it, but that could also be that I just haven't encountered it again.

@flamme
Copy link
Collaborator

flamme commented Jan 26, 2026

So for some reason, this caused and issue where the audio would just "stop" when switching between songs, but it'd only happen in a couple of occasions.

Since putting this fix in, I haven't heard it, but that could also be that I just haven't encountered it again.

This doesn't sound right to me. getFramesWritten always returns positive number as long as the stream has ever played. If the stream never starts, the stream is only in open state.

It will be better to capture a bugreport and file a bug to me if calling flushFromFrame when active playing cause stream stop.

@madebymozart
Copy link
Collaborator Author

Then we ca close this, might have been a old ticket for this one

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants