Skip to content
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

video/external: Reorder frames decoded by OpenH264 manually #19445

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

torokati44
Copy link
Member

@torokati44 torokati44 commented Feb 5, 2025

This should unblock #18581, despite cisco/openh264#3837.

@torokati44 torokati44 marked this pull request as draft February 5, 2025 23:14
@torokati44 torokati44 changed the title Manual frame reordering to work around OpenH264 2.5.0 latency video/external: Reorder frames decoded by OpenH264 manually Feb 5, 2025
@torokati44 torokati44 force-pushed the openh264-manual-frame-reordering branch from 642c69c to 31d87b9 Compare February 5, 2025 23:25
@torokati44 torokati44 added A-video T-refactor Type: Refactor / Cleanup labels Feb 5, 2025
@torokati44 torokati44 force-pushed the openh264-manual-frame-reordering branch from 31d87b9 to 2b4c38b Compare February 5, 2025 23:29
@torokati44
Copy link
Member Author

torokati44 commented Feb 5, 2025

Hm, I wonder if instead we should use the composition time of the decoded frames (assuming OpenH264 carries them over correctly from the encoded ones, but surely it does), to govern the "lead time" with which the FLV streaming feeds the decoder... 🤔
Then we could better match FP even, in which frame is presented when, getting the delay lower than it currently has to be.

@torokati44
Copy link
Member Author

... and/or separate the "here's an encoded chunk" and "gimme a decoded frame" calls, like they are in FFmpeg (libavcodec), so they don't have to be 1:1 with each other...

@torokati44
Copy link
Member Author

Note to self: if we go forward with this, then TODO clear the frame queue on seek (especially on backward ones), decide whether it's signalled explicitly from the outside or detected based on frame_ids passed in, and see how those work with FLV sources

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-video T-refactor Type: Refactor / Cleanup
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant