androidx / media

Jetpack Media3 support libraries for media use cases, including ExoPlayer, an extensible media player for Android
Apache License 2.0
1.35k stars 320 forks source link

Presentation time offset for MPEG DASH manifests not applied correctly for xHE-AAC and AC4 streams #1440

Open ronak2121 opened 3 weeks ago

ronak2121 commented 3 weeks ago

Version

Media3 1.3.0

More version details

No response

Devices that reproduce the issue

Samsung S21+ with Android 14

Devices that do not reproduce the issue

None

Reproducible in the demo app?

Yes

Reproduction steps

Play attached media Wait for the first period to finish Watch the second period not honor the offset value (effectively restart playback from the beginning of the content)

Expected result

Media plays correctly - the first period and the second, honoring the offset correctly

Actual result

Playback starts, plays the first period, and then plays the second one, without honoring the presentationTimeOffset.

Media

We actively worked with the Exoplayer team here: https://github.com/google/ExoPlayer/issues/11000 to fix discontinuities with AC-4 streams. We just adopted the fix, but it looks to have broken applying the presentationTimeOffset correctly for both xHE-AAC and AC-4 audio streams. For some reason, it looks to be working with AAC-LC (which doesn't have I-Frames).

Based on our debugging, the commit the Exoplayer team made for our above issue is what caused this. Can you please look into what's going on, and please apply the correct fix?

We're not sure if you still have our AC-4 stream from the past, but you can still use that. We will also email you links to three clear streams - an AAC one (where presentationTimeOffset is being honored) and xHE-AAC and AC-4 where they are not anymore.

Bug Report

ronak2121 commented 3 weeks ago

FYI @rohitjoins and @tonihei

ronak2121 commented 3 weeks ago

FYI we've emailed the adb bug report to the above email address. We will send you sample audio later today. Would appreciate a set of eyes from your team on this soon.

We still think our original proposed patch from: https://github.com/google/ExoPlayer/issues/11000 is the actual solution to the original problem rather than messing with timestamps....but open to hearing your guidance as well.

ronak2121 commented 2 weeks ago

We've emailed an XHE-AAC stream as promised. An AC4 one will be forthcoming.

ronak2121 commented 1 week ago

@rohitjoins, can you please advise on the next steps for this issue?

ronak2121 commented 1 week ago

Hi @rohitjoins , is there any update?

tonihei commented 1 week ago

@ronak2121 The xHE-AAC link you shared via email results in HTTP 403 errors for me. Could you check that it's accessible or provide more details on how to access it? Not sure what the link is targeting, but the most important thing to have for testing is the actual DASH manifest referencing real media files that show the problem.

ronak2121 commented 1 week ago

Just emailed you guys again with a new link.

tonihei commented 5 days ago

The link still gives 403 errors I'm afraid. Not sure if it expired or if there is another problem, but we can't really debug and look into the issue if it's not accessible to us.