Function: dvpp_jpeg_encode_async
Applicability
|
Product |
Supported (√/x) |
|---|---|
|
|
√ |
|
|
√ |
|
|
√ |
|
|
√ |
|
|
√ |
Function Usage
Encodes a YUV image into a JPG image. This API is asynchronous.
Prototype
- C Prototype
1aclError acldvppJpegEncodeAsync(acldvppChannelDesc *channelDesc, acldvppPicDesc *inputDesc, const void *data, uint32_t *size, acldvppJpegeConfig *config, aclrtStream stream)
- Python Function
1ret = acl.media.dvpp_jpeg_encode_async(dvpp_channel_desc, input_dvpp_pic_desc, data, size_ptr, dvpp_jpege_config, stream)
Parameter Description
|
Parameter |
Description |
|---|---|
|
dvpp_channel_desc |
Int, pointer address of the channel description. It must be the same as dvpp_channel_desc passed to the acl.media.dvpp_create_channel call. |
|
input_dvpp_pic_desc |
Int, pointer address of the description of input images.
|
|
data |
Int, pointer address of the output buffer address for storing encoded data. |
|
size_ptr |
Int, pointer to the output buffer size, in bytes.
|
|
dvpp_jpege_config |
Int, pointer address of the image encoding configuration.
|
|
stream |
Specified stream. |
Return Value Description
|
Return Value |
Description |
|---|---|
|
ret |
Int, error code: 0 on success; else, failure. |
Restrictions
This API is asynchronous. The API call delivers a task rather than executes a task. After this API is called, call the synchronization API (for example, acl.rt.synchronize_stream) to ensure that the task is complete.