goto ErrorExit;
}
- /* display interface handle */
- if (mm_display_interface_init(&cb_info->dp_interface) != MM_ERROR_NONE) {
- LOGE("display interface init failed");
- goto ErrorExit;
- }
-
cb_info->api_waiting[MUSE_CAMERA_API_CREATE] = 1;
for (i = 0 ; i < MUSE_CAMERA_API_MAX ; i++) {
g_cond_clear(&cb_info->api_cond[i]);
}
- if (cb_info->dp_interface) {
- mm_display_interface_deinit(cb_info->dp_interface);
- cb_info->dp_interface = NULL;
- }
-
g_free(cb_info);
cb_info = NULL;
}
if (type == CAMERA_DISPLAY_TYPE_NONE) {
LOGD("display type NONE");
} else {
+ /* display interface handle */
+ if (!cb_info->dp_interface) {
+ if (mm_display_interface_init(&cb_info->dp_interface) != MM_ERROR_NONE) {
+ LOGE("display interface init failed");
+ return CAMERA_ERROR_NOT_SUPPORTED;
+ }
+ }
+
ret = mm_display_interface_set_display(cb_info->dp_interface, type, display, &cb_info->parent_id);
if (ret == MM_ERROR_NONE && type == CAMERA_DISPLAY_TYPE_EVAS) {
camera_flip_e flip = CAMERA_FLIP_NONE;