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

WIP/RFC extract framerate #62

Open
wants to merge 4 commits into
base: release
Choose a base branch
from

Conversation

ydirson
Copy link

@ydirson ydirson commented Oct 4, 2018

This builds on #61 to get notifications when the frame-rate encoded in SPS changes.

This is very preliminary, adding h264-specific fields in generic structures. I noticed that some work had been done about those fields in the h265 decoder, but the data-structures are missing. We'll have to deal with h265 too in the near future. How can we proceed ? Are you interested with adding this feature ?

@@ -144,6 +144,8 @@ MPP_RET mpp_frame_info_cmp(MppFrame frame0, MppFrame frame1)
(f0->height == f1->height) &&
(f0->hor_stride == f1->hor_stride) &&
(f0->ver_stride == f1->ver_stride) &&
(f0->time_scale == f1->time_scale) &&
Copy link
Collaborator

Choose a reason for hiding this comment

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

There is no necessary to add info change test. For framerate change will reflect on pts.
The info change judgement will report resolution / bitdepth / format changes which will affect buffer allocation and display setup.

Copy link
Author

Choose a reason for hiding this comment

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

Yes I had doubts about where to put the information and how to have the parser notify the app when those values change. What do you think would be the best way ?

Copy link
Collaborator

Choose a reason for hiding this comment

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

There should be demux before mpp ( codec ). So demuxer can know the change.
When use mpp alone without demux embeded the frame rate change can be detect by pts gap.
These frame rate information looks like ffmpeg style : )

Copy link
Author

Choose a reason for hiding this comment

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

In fact, we're already in the process moving away from PTS-based detection of framerate changes, and on our side the need for this patch is temporary. If you feel it's not the right place for the feature, let's just close this PR, and we'll just keep this patch on our side until our need for it is gone :)

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