SetCropParams
Syntax
AIStatus SetCropParams(bool cropSwitch,
int32_t cropStartPosW, int32_t cropStartPosH,
int32_t cropSizeW, int32_t cropSizeH,
uint32_t batch_index = 0);
Function Description
Sets the crop parameters. Dynamic AIPP supports the configuration of different crop parameters for each batch. batchIndex indicates the sequence number of the batch for which the crop parameters are set. The value range of batchIndex is [0, batchNum). If the value exceeds the range, a failure message will be returned.
Parameter Description
Parameter |
Input/Output |
Type |
Description |
---|---|---|---|
cropSwitch |
Input |
Bool |
true: Crop is supported. false: Crop is not supported. |
cropStartPosW |
Input |
int32_t |
Horizontal coordinate of the start point in the image during cropping |
cropStartPosH |
Input |
int32_t |
Vertical coordinate of the start point in the image during cropping |
cropSizeW |
Input |
int32_t |
Crop width |
cropSizeH |
Input |
int32_t |
Crop height |
batchIndex |
Input |
uint32_t |
Sequence number of the batch for which cropping is performed. The default value is 0. The value range is [0, batchNum). |
Return Value
Parameter |
Type |
Description |
---|---|---|
- |
AIStatus |
If the parameter is set successfully, 0 is returned. If the input is invalid, other values are returned. The AIStatus type is defined as follows: AIStatus = uint32_t |
Exception Handling
None
Restriction
None
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot