acldvppVpcCalcHistAsync

The Atlas 200/300/500 Inference Product does not support this API.

The Atlas Training Series Product does not support this API.

Description

Obtains the distribution of color components of each pixel in an image. This API is asynchronous.

Prototype

aclError acldvppVpcCalcHistAsync(acldvppChannelDesc *channelDesc,

acldvppPicDesc *srcPicDesc,

acldvppHist *hist,

void *reserve,

aclrtStream stream)

Parameters

Parameter

Input/Output

Description

channelDesc

Input

Pointer to channel description.

Must be the same as the channelDesc argument passed to the acldvppCreateChannel call.

srcPicDesc

Input

Pointer to the input image description.

  • Call acldvppCreatePicDesc to create an image description.
  • Call acldvppSetPicDesc series to set the image description (including the buffer address, buffer size, image format, and image resolution).
    NOTE:

    When the image format is YUV440SP 8-bit or YVU440SP 8-bit, the Y component statistics are accurate, but the UV component statistics are inaccurate.

hist

Input/Output

Pointer to histogram description.

Call acldvppCreateHist to create a histogram description in advance.

Calling this API returns the pixel value distribution (0–255) of each color component of each image.

reserve

Input

Pointer to the histogram configuration. This parameter is reserved and can be set to NULL currently.

stream

Input

Stream.

Returns

0 on successful task delivery; else, failure.