use INFERENCE_SQUARE_WIDTH and INFERENCE_SQUARE_HEIGHT defined in aiengineinference.h for resizing in opi5 (set them to 1280)

reorganised logs for inference output, remove some logs for more clear output
This commit is contained in:
Alex Bezdieniezhnykh
2024-10-25 17:05:16 +03:00
parent 45c19baa45
commit 5f22931e0d
6 changed files with 34 additions and 32 deletions
+14 -14
View File
@@ -666,17 +666,17 @@ int convert_image(image_buffer_t* src_img, image_buffer_t* dst_img, image_rect_t
{
int ret;
printf("src width=%d height=%d fmt=0x%x virAddr=0x%p fd=%d\n",
src_img->width, src_img->height, src_img->format, src_img->virt_addr, src_img->fd);
printf("dst width=%d height=%d fmt=0x%x virAddr=0x%p fd=%d\n",
dst_img->width, dst_img->height, dst_img->format, dst_img->virt_addr, dst_img->fd);
if (src_box != NULL) {
printf("src_box=(%d %d %d %d)\n", src_box->left, src_box->top, src_box->right, src_box->bottom);
}
if (dst_box != NULL) {
printf("dst_box=(%d %d %d %d)\n", dst_box->left, dst_box->top, dst_box->right, dst_box->bottom);
}
printf("color=0x%x\n", color);
// printf("src width=%d height=%d fmt=0x%x virAddr=0x%p fd=%d\n",
// src_img->width, src_img->height, src_img->format, src_img->virt_addr, src_img->fd);
// printf("dst width=%d height=%d fmt=0x%x virAddr=0x%p fd=%d\n",
// dst_img->width, dst_img->height, dst_img->format, dst_img->virt_addr, dst_img->fd);
// if (src_box != NULL) {
// printf("src_box=(%d %d %d %d)\n", src_box->left, src_box->top, src_box->right, src_box->bottom);
// }
// if (dst_box != NULL) {
// printf("dst_box=(%d %d %d %d)\n", dst_box->left, dst_box->top, dst_box->right, dst_box->bottom);
// }
// printf("color=0x%x\n", color);
ret = convert_image_rga(src_img, dst_img, src_box, dst_box, color);
if (ret != 0) {
@@ -757,9 +757,9 @@ int convert_image_with_letterbox(image_buffer_t* src_image, image_buffer_t* dst_
dst_box.right = dst_box.left + resize_w - 1;
_left_offset = dst_box.left;
}
printf("scale=%f dst_box=(%d %d %d %d) allow_slight_change=%d _left_offset=%d _top_offset=%d padding_w=%d padding_h=%d\n",
scale, dst_box.left, dst_box.top, dst_box.right, dst_box.bottom, allow_slight_change,
_left_offset, _top_offset, padding_w, padding_h);
// printf("scale=%f dst_box=(%d %d %d %d) allow_slight_change=%d _left_offset=%d _top_offset=%d padding_w=%d padding_h=%d\n",
// scale, dst_box.left, dst_box.top, dst_box.right, dst_box.bottom, allow_slight_change,
// _left_offset, _top_offset, padding_w, padding_h);
//set offset and scale
if(letterbox != NULL){