Functions and Restrictions
The
Function Description
Video Encoder (VENC) encodes YUV420SP NV12/NV21 8-bit images into H.264/H.265 video streams.
Single-process and multi-thread scenarios are not supported on the
Resolution Restrictions
Restrictions on Stream/Image Formats, Width and Height Alignment, and Buffers
To implement the VENC function:
- Input buffer
Call acldvppMalloc or acldvppFree to allocate or free the input buffer on the device. The buffer lifetime is managed by the user. For details about the buffer size, see the formula in the following table.
- Output buffer:
For details about the definition of the input image format, see acldvppPixelFormat. For details about the concepts such as width stride and height stride, see Terminology.
Input Format |
Input Width and Height |
Input Width Stride, Height Stride, and Buffer Size |
Output Format |
|---|---|---|---|
YUV420SP NV12 8-bit |
Width: Must be a multiple of 2. Height: Must be a multiple of 2. |
Width stride: Round up the width to the nearest multiple of 16. The height stride does not need to be configured. Buffer size (in bytes) = Width stride x Height x 3/2 |
|
YUV420SP NV21 8-bit |