Skip to content

Inaccurate MP3 VBR seeking with Media3 1.9.x #3117

@ckett73

Description

@ckett73

Version

Media3 1.9.2

More version details

No response

Devices that reproduce the issue

Any device

Devices that do not reproduce the issue

None

Reproducible in the demo app?

Yes

Reproduction steps

  1. Play the attached MP3 file in the demo session app.
  2. The seeking and the duration is very inaccurate (about 25 seconds off)
  3. Setting the setMediaSourceFactory with FLAG_ENABLE_INDEX_SEEKING has no effect (Version 1.8.0 works well / accurate with this flag enabled)

Seems to be that this commit changes the behaviour:
cef3c8f / Prioritize CBR seeking over index seeking for MP3s

Expected result

Accurate duration and seeking.
Maybe a new flag like FLAG_ENABLE_INDEX_SEEKING_ALWAYS could be a workaround / solution to force index seeking.

This MP3 works fine with other players like VLC e.g.

Actual result

Very inaccurate (about 25 sec off)

Media

tenstories-vbr.mp3

or forked repo (MP3 already integrated as asset in demo app)
https://github.com/DavidEdwardsBL/media3/tree/bug/vbr-duration

Bug Report

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions