video: driver: Add Complexity vs. Operating Rate handling

For Quality mode decision, Complexity and Operating rate
are handled as below -
[1] If Complexity and operating rate both are set,
    then for NRT, complexity is honored, and operating
    rate can be adjusted. But for RT, Operating Rate is
    honored and complexity can be adjusted.
[2] If only Complexity is set, then complexity is honored.
[3] If only Operating rate set then Operating rate is honored
[4] If None set, then upto encoder to decide

Change-Id: Ib8008551d5ee7a9506f4d1586ed7a3ae967ac54b
Signed-off-by: Vedang Nagar <quic_vnagar@quicinc.com>
此提交包含在:
Vedang Nagar
2022-05-19 15:27:21 +05:30
父節點 094b4c057c
當前提交 dd262f5916

查看文件

@@ -1128,9 +1128,13 @@ int msm_vidc_decide_quality_mode_iris3(struct msm_vidc_inst* inst)
max_hq_mbpf = core->capabilities[MAX_MBPF_HQ].value;;
max_hq_mbps = core->capabilities[MAX_MBPS_HQ].value;;
if (!is_realtime_session(inst) && mbpf <= max_hq_mbpf) {
mode = MSM_VIDC_MAX_QUALITY_MODE;
goto decision_done;
if (!is_realtime_session(inst)) {
if (((capability->cap[COMPLEXITY].flags & CAP_FLAG_CLIENT_SET) &&
(capability->cap[COMPLEXITY].value >= DEFAULT_COMPLEXITY)) ||
mbpf <= max_hq_mbpf) {
mode = MSM_VIDC_MAX_QUALITY_MODE;
goto decision_done;
}
}
if (mbpf <= max_hq_mbpf && mbps <= max_hq_mbps)