venc_set_mod_param
Applicability
|
Product |
Supported (√/x) |
|---|---|
|
|
x |
|
|
x |
|
|
x |
|
|
√ |
|
|
√ |
Function Usage
Sets the encoding module parameters.
Prototype
- C Prototype
1hi_s32 hi_mpi_venc_set_mod_param(const hi_venc_mod_param *mod_param)
- Python Function
1ret = acl.himpi.venc_set_mod_param(mod_param)
Parameter Description
|
Parameter |
Description |
|---|---|
|
mod_param |
Dict, dictionary of encoding module parameters. For details, see hi_venc_mod_param. |
Return Value Description
|
Return Value |
Description |
|---|---|
|
ret |
Int, error code.
|
Restrictions
- Ensure that this API is called before any channel is created. Otherwise, the error code HI_ERR_VENC_NOT_PERM is returned. Before calling this API, it is recommended that the acl.himpi.venc_get_mod_param API be called to obtain the encoding module parameter settings of the current channel, and then set the parameters as required.
- This API is set at the global level. In the multi-process scenario:
- After this API is called in a process to set parameters, the parameters take effect in other processes.
- If process B calls acl.himpi.venc_set_mod_param after process A creates a channel, process B returns an error, indicating that the setting is invalid. However, process B continues encoding based on the default value or the parameter value that is successfully set in other processes. In this case, if process B is required to call the acl.himpi.venc_set_mod_param API to adjust parameter values, the channels in other processes must be destroyed first.
Parent topic: VENC/JPEGE APIs