mv3d: fix vision.3d feature check 92/285092/1
authorTae-Young Chung <ty83.chung@samsung.com>
Tue, 6 Dec 2022 04:39:26 +0000 (13:39 +0900)
committerTae-Young Chung <ty83.chung@samsung.com>
Tue, 6 Dec 2022 04:39:29 +0000 (13:39 +0900)
[Issue type] bug fix

This commit is manually patched from https://review.tizen.org/gerrit/#/c/platform/core/api/mediavision/+/285085
to avoid conflict.

Change-Id: I1d5718d1ee4c3cc46db550ce3be9984fca92262f
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
mv_3d/3d/src/mv_3d.c
mv_common/src/mv_private.c

index 5f62b6d..b01ac4c 100644 (file)
@@ -72,7 +72,7 @@ int mv_3d_set_depth_cb(mv_3d_h mv3d,
                        mv_3d_depth_cb depth_cb,
                        void *user_data)
 {
-       MEDIA_VISION_SUPPORT_CHECK(_mv_3d_depth_check_system_info_feature_supported() ||
+       MEDIA_VISION_SUPPORT_CHECK(_mv_3d_depth_check_system_info_feature_supported() &&
                                                           _mv_3d_check_system_info_feature_supported());
        MEDIA_VISION_INSTANCE_CHECK(mv3d);
 
@@ -91,7 +91,7 @@ int mv_3d_set_pointcloud_cb(mv_3d_h mv3d,
                        mv_3d_pointcloud_cb pointcloud_cb,
                        void *user_data)
 {
-       MEDIA_VISION_SUPPORT_CHECK(_mv_3d_pointcloud_check_system_info_feature_supported() ||
+       MEDIA_VISION_SUPPORT_CHECK(_mv_3d_pointcloud_check_system_info_feature_supported() &&
                                                           _mv_3d_check_system_info_feature_supported());
        MEDIA_VISION_INSTANCE_CHECK(mv3d);
 
@@ -165,7 +165,7 @@ int mv_3d_pointcloud_write_file(mv_3d_h mv3d,
                        mv_3d_pointcloud_type_e type,
                        char *filename)
 {
-       MEDIA_VISION_SUPPORT_CHECK(_mv_3d_pointcloud_check_system_info_feature_supported() ||
+       MEDIA_VISION_SUPPORT_CHECK(_mv_3d_pointcloud_check_system_info_feature_supported() &&
                                                           _mv_3d_check_system_info_feature_supported());
        MEDIA_VISION_INSTANCE_CHECK(mv3d);
        MEDIA_VISION_INSTANCE_CHECK(pointcloud);
index f6dc75a..b7ed619 100644 (file)
@@ -262,9 +262,8 @@ bool _mv_roi_tracking_check_system_info_feature_supported(void)
 
 bool _mv_3d_all_check_system_info_feature_supported(void)
 {
-       return _mv_3d_check_system_info_feature_supported() ||
-                  _mv_3d_depth_check_system_info_feature_supported() ||
-                  _mv_3d_pointcloud_check_system_info_feature_supported();
+       return _mv_3d_check_system_info_feature_supported() &&
+                       (_mv_3d_depth_check_system_info_feature_supported() || _mv_3d_pointcloud_check_system_info_feature_supported());
 }
 
 bool _mv_3d_check_system_info_feature_supported(void)