Skip to content

media: qcom: iris: fix enum_frameintervals to support non-integer framerates#731

Open
gouravk-qualcomm wants to merge 1 commit into
qualcomm-linux:qcom-6.18.yfrom
gouravk-qualcomm:frameinterval-fix
Open

media: qcom: iris: fix enum_frameintervals to support non-integer framerates#731
gouravk-qualcomm wants to merge 1 commit into
qualcomm-linux:qcom-6.18.yfrom
gouravk-qualcomm:frameinterval-fix

Conversation

@gouravk-qualcomm

Copy link
Copy Markdown

Encoding fails with "internal data stream error" for input videos with
non-integer framerates (e.g., 29.97 fps / 30000/1001)
video driver returned a STEPWISE range with min=1/fps and max=1/1.
GStreamer enumerated this as a discrete list of framerates (480/1,
240/1, ..., 30/1, ..., 1/1). Since 29.97 fps is not expressible as 480/n for
any integer n, caps negotiation failed.

Swap min and max denominators (min=1/1, max=1/fps). GStreamer's
loop condition fails immediately, no discrete list is built, and the
framerate is left unconstrained, accepting any framerate including
29.97 fps.

CRs-Fixed: 4515234

@qswat-orbit-external

Copy link
Copy Markdown

Merge Check Failed: No Change Task Found

No associated change tasks found for CR 4515234 on any of the following entities:

Entities:

  • kernel.qli.2.0

CR: 4515234

Please ensure the CR has a change task associated with at least one of the entities for this branch.

…teger framerates

iris_enum_frameintervals() had min/max swapped in the stepwise frame
interval structure. This caused GStreamer to enumerate a discrete list
of framerates (480/n), which excluded non-integer values like 29.97 fps
(30000/1001), resulting in caps negotiation failure.

Fix by swapping min and max denominators so GStreamer's enumeration loop
exits immediately, leaving the framerate unconstrained in caps and
allowing any framerate to negotiate successfully.

Signed-off-by: Gourav Kumar <gouravk@qti.qualcomm.com>
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.

1 participant