aclvdecCallback

Description

Video decoding callback function. This API is synchronous. This callback function is user-defined.

Restrictions

  • Do not perform channel destruction in the callback function. Doing so results in a deadlock at app runtime.
  • The latency for handling the callback function must meet the frame rate required for frame feeding. Otherwise, aclvdecSendFrame will be unable to process video frames in real time.
  • The callback thread needs to be unsubscribed when all callbacks are handled. (That is, after the stream feeding thread has been unsubscribed.)
  • After frame extraction by the aclvdecSendSkippedFrame call, the output of the corresponding frame is nullptr.

    In the case of frame extraction, the output buffer has no decoding result, and the extracted frames are output in sequence.

    In the case of no-frame extraction, the output buffer has the decoding result, and the non-extracted frames are output in sequence.

    If both frame extraction and no-frame extraction exist in the decoded stream, the system does not guarantee that the extracted frames and non-extracted frames are output in sequence.

Prototype

void (* aclvdecCallback) (acldvppStreamDesc * input, acldvppPicDesc * output, void* userData)

Parameters

Parameter

Input/Output

Description

input

Input

Pointer to the input stream description. The value is the same as that of input in the aclvdecSendFrame API.

output

Input

Pointer to the VDEC output image description. The user needs to allocate output buffer in advance.

userData

Input

Pointer to the user-defined data.

Returns

None

See Also

For details about the API call sequence and example, see VDEC.