-
Notifications
You must be signed in to change notification settings - Fork 0
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
CPD-91: Use forced resolution for overlay composition when requested by downstream peer #26
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Normal behavior is to sync subtitle resolution with video resolution, here we introduce an option to decouple.
if (gst_structure_get_int (structure, "overlay-composition-width", &overlay_composition_width) && | ||
gst_structure_get_int (structure, "overlay-composition-height", &overlay_composition_height)) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When downstream connection (kmssink
in our case) sets these two propreties, and the renderer is capable to attach overlay composition rather than blend into video, the overlay composition resolution is fixed.
We send the caps back downstream as well, and the renderer will be able to recognize fixed resolution.
These properties are introduced by us.
The idea is that physical monitor is known and fixed in our AERQ case, and in general it does not make a lot of sense to downsize the subtitles if the video is low res. But also, it does not make a lot of sense to render 4K and upload to slow buffer if this is sensed as performance hit.
render->width = render->overlay_composition_width; | ||
render->height = render->overlay_composition_height; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here we essentially override the internal resolution, and composition renderer would just use the resolution detached from actual video from now on.
This updates subtitle rendered to negotiate overlay composition reoslution with the downstream peers.
NOTE:
kmssink
compatible with this PR