Skip to content

Bugfix: Handle seekhead for cues on mkv files. #2254

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

Closed
wants to merge 1 commit into from

Conversation

fire-light42
Copy link

Closes #1143

This fixes the issue with non seekable mkv files, by checking the SEEK_HEAD, as media3 does not currently use SEEK_HEAD at all. A test was also added showing a non seekable mkv file, this was generated by mkvpropedit sample.mkv --chapters large_chapters.xml.

This means that when we parse an MKV file what really happens is:

    find KaxSeekHead
    seek to KaxSeekHead position
    find KaxCues
    seek to KaxCues position
    parse cues
    seek back from KaxCues
    seek back from KaxSeekHead
    parse rest normally

What happened before was:

    find KaxCues <- this step fails
    seek to KaxCues position
    parse cues
    seek back from KaxCues
    parse rest normally

Copy link

google-cla bot commented Mar 22, 2025

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@fire-light42
Copy link
Author

@icbaker

@icbaker icbaker self-assigned this Mar 25, 2025
@icbaker icbaker self-requested a review March 25, 2025 15:58
@icbaker
Copy link
Collaborator

icbaker commented Mar 25, 2025

Please sign the CLA and then we can take a look.

@fire-light42
Copy link
Author

Please sign the CLA and then we can take a look.

I cant sign it because I do not have a google account, nor am I interested in creating one. Is there any way to sign it without creating a google account?

@icbaker
Copy link
Collaborator

icbaker commented Mar 25, 2025

Is there any way to sign it without creating a google account?

Doesn't look like it. From https://cla.developers.google.com/about:

Can I sign the Google CLA without a Google account?

A Google account is required to sign the CLA. Google accounts are used to link individual and corporate CLAs to covered contributors and provide authentication for CLA management.

@fire-light42
Copy link
Author

@KingLucius

@fire-light42
Copy link
Author

#2268

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

Successfully merging this pull request may close these issues.

2 participants