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

Nvidia nvenc #271

Merged
merged 2 commits into from
Apr 1, 2023
Merged

Nvidia nvenc #271

merged 2 commits into from
Apr 1, 2023

Conversation

mbattista
Copy link
Contributor

Hi,

I had a similar problem with the rpi pipeline back in the day.
I added h264parse and it worked like expected.
I took every 3 seconds as a value for the refresh frame.

I changed the profile and the profile to High Quality since it should be fast enough on nvenc either way. But some experimenting could be done here.

@m1k1o
Copy link
Owner

m1k1o commented Apr 1, 2023

Wow @mbattista thank you very much, you actually fixed this issue! It has been there for raspberry pi pipeline all the time since you added it. I tried almost everything but didn't think of looking at raspberry pi pipeline.

I somehow suspected that it must have something to do with keyframes, but I had no idea where to search for it and what would fix it.

I would keep gop-size=15 because default is 75 and that's quite long distance. Maybe also changing keyframe-period=180 and key-int-max=60 for other encoders to 15. Or maybe 30, what would you say?

When I'm reading about h264parse config-interval= is not -1 the value that would be actually desired? To send those informations with IDR frame?

@mbattista
Copy link
Contributor Author

The last time the keyframes were changed to a shorter interval, the short freezes in the pipeline were reintroduced. (At least for me)

I do not understand, why you would want to resend it in such a short interval?
Are there any benefits besides a shorter delay at the startup?

@m1k1o
Copy link
Owner

m1k1o commented Apr 1, 2023

The freezes still happen for me. And they match the length of keyframe interval. Therefore keyframe-max-dist for vp8enc has been changed to match fps 25. Now I get only one second freezes.

Does this not happen for h264? Is it only Vp8 issue? What about vaapivp8enc where keyframe-period is 180, there must be at least 7sec freezes (I don't use VAAPI so cannot test that).

If that's not issue for H264 we can keep longer keyframe interval and just introduce h264parse for all other pipelines to ensure fast joinig.

@mbattista
Copy link
Contributor Author

Interesting.
But it seems that those are different freezes that I had.

Can you check if you drop frames in those intervalls?

@m1k1o
Copy link
Owner

m1k1o commented Apr 1, 2023

It happens at least once per session (1-2hours long). So I'll have stats open and will check the next time.

@m1k1o m1k1o merged commit 8e66e59 into m1k1o:nvidia-nvenc Apr 1, 2023
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