Lines Matching refs:areas
5804 … cam_area_t *areas = (cam_area_t *)malloc(sizeof(cam_area_t) * m_pCapability->max_num_focus_areas); in setFocusAreas() local
5805 if (NULL == areas) { in setFocusAreas()
5809 memset(areas, 0, sizeof(cam_area_t) * m_pCapability->max_num_focus_areas); in setFocusAreas()
5813 areas, in setFocusAreas()
5816 free(areas); in setFocusAreas()
5820 if (validateCameraAreas(areas, num_areas_found) == false) { in setFocusAreas()
5822 free(areas); in setFocusAreas()
5831 areas[0].rect.left == 0 && in setFocusAreas()
5832 areas[0].rect.top == 0 && in setFocusAreas()
5833 areas[0].rect.width == 0 && in setFocusAreas()
5834 areas[0].rect.height == 0 && in setFocusAreas()
5835 areas[0].weight == 0) { in setFocusAreas()
5846 __func__, i, (areas[i].rect.top), (areas[i].rect.left), in setFocusAreas()
5847 (areas[i].rect.width), (areas[i].rect.height)); in setFocusAreas()
5850 … af_roi_value.roi[i].left = (int32_t)((areas[i].rect.left + 1000.0f) * (previewWidth / 2000.0f)); in setFocusAreas()
5851 … af_roi_value.roi[i].top = (int32_t)((areas[i].rect.top + 1000.0f) * (previewHeight / 2000.0f)); in setFocusAreas()
5852 af_roi_value.roi[i].width = (int32_t)(areas[i].rect.width * previewWidth / 2000.0f); in setFocusAreas()
5853 af_roi_value.roi[i].height = (int32_t)(areas[i].rect.height * previewHeight / 2000.0f); in setFocusAreas()
5854 af_roi_value.weight[i] = areas[i].weight; in setFocusAreas()
5856 free(areas); in setFocusAreas()
5883 …cam_area_t *areas = (cam_area_t *)malloc(sizeof(cam_area_t) * m_pCapability->max_num_metering_area… in setMeteringAreas() local
5884 if (NULL == areas) { in setMeteringAreas()
5888 memset(areas, 0, sizeof(cam_area_t) * m_pCapability->max_num_metering_areas); in setMeteringAreas()
5892 areas, in setMeteringAreas()
5895 free(areas); in setMeteringAreas()
5899 if (validateCameraAreas(areas, num_areas_found) == false) { in setMeteringAreas()
5901 free(areas); in setMeteringAreas()
5910 areas[0].rect.left == 0 && in setMeteringAreas()
5911 areas[0].rect.top == 0 && in setMeteringAreas()
5912 areas[0].rect.width == 0 && in setMeteringAreas()
5913 areas[0].rect.height == 0 && in setMeteringAreas()
5914 areas[0].weight == 0) { in setMeteringAreas()
5928 __func__, i, (areas[i].rect.top), (areas[i].rect.left), in setMeteringAreas()
5929 (areas[i].rect.width), (areas[i].rect.height)); in setMeteringAreas()
5933 … (uint32_t)(((areas[i].rect.left + areas[i].rect.width / 2) + 1000.0f) * previewWidth / 2000.0f) ; in setMeteringAreas()
5935 … (uint32_t)(((areas[i].rect.top + areas[i].rect.height / 2) + 1000.0f) * previewHeight / 2000.0f) ; in setMeteringAreas()
5940 free(areas); in setMeteringAreas()
8270 bool QCameraParameters::validateCameraAreas(cam_area_t *areas, int num_areas) in validateCameraAreas() argument
8274 areas[0].rect.left == 0 && in validateCameraAreas()
8275 areas[0].rect.top == 0 && in validateCameraAreas()
8276 areas[0].rect.width == 0 && in validateCameraAreas()
8277 areas[0].rect.height == 0 && in validateCameraAreas()
8278 areas[0].weight == 0) { in validateCameraAreas()
8284 if(areas[i].rect.left < -1000) { in validateCameraAreas()
8289 if(areas[i].rect.top < -1000) { in validateCameraAreas()
8294 if (areas[i].rect.width <= 0 || areas[i].rect.height <= 0) { in validateCameraAreas()
8299 if(areas[i].rect.left + areas[i].rect.width > 1000) { in validateCameraAreas()
8304 if(areas[i].rect.top + areas[i].rect.height > 1000) { in validateCameraAreas()
8309 if (areas[i].weight < 1 || areas[i].weight > 1000) { in validateCameraAreas()