*/
#include <system_info.h>
-
+#include <glib.h>
#include "mv_private.h"
+#define VISION_FEATURE_ROI_TRACKING "http://tizen.org/feature/vision.roi_tracking"
+
+static gpointer __get_system_info_feature_once(gpointer data)
+{
+ bool supported = false;
+ gchar *feature = (gchar *)data;
+
+ if (system_info_get_platform_bool(feature, &supported) != SYSTEM_INFO_ERROR_NONE)
+ LOGE("SYSTEM_INFO_ERROR: %s", feature);
+
+ return (gpointer)supported;
+}
+
bool __mv_check_system_info_feature_supported()
{
bool isBarcodeDetectionSupported = false;
return isInferenceFaceSupported;
}
+
+bool __mv_roi_tracking_check_system_info_feature_supported()
+{
+ static GOnce once = G_ONCE_INIT;
+ bool supported = (bool)g_once(&once, __get_system_info_feature_once, VISION_FEATURE_ROI_TRACKING);
+
+ LOGI("Feature[%s] : %d", VISION_FEATURE_ROI_TRACKING, supported);
+
+ return supported;
+}
\ No newline at end of file
int mv_roi_tracker_create(mv_roi_tracker_h *handle)
{
MEDIA_VISION_SUPPORT_CHECK(
- __mv_inference_face_check_system_info_feature_supported());
+ __mv_roi_tracking_check_system_info_feature_supported());
MEDIA_VISION_NULL_ARG_CHECK(handle);
int mv_roi_tracker_destroy(mv_roi_tracker_h handle)
{
MEDIA_VISION_SUPPORT_CHECK(
- __mv_inference_face_check_system_info_feature_supported());
+ __mv_roi_tracking_check_system_info_feature_supported());
MEDIA_VISION_INSTANCE_CHECK(handle);
int mv_roi_tracker_set_coordinate(mv_roi_tracker_h handle, int x, int y, int width, int height)
{
MEDIA_VISION_SUPPORT_CHECK(
- __mv_inference_face_check_system_info_feature_supported());
+ __mv_roi_tracking_check_system_info_feature_supported());
MEDIA_VISION_INSTANCE_CHECK(handle);
int mv_roi_tracker_set_tracker_type(mv_roi_tracker_h handle, mv_roi_tracker_type_e type)
{
MEDIA_VISION_SUPPORT_CHECK(
- __mv_inference_face_check_system_info_feature_supported());
+ __mv_roi_tracking_check_system_info_feature_supported());
MEDIA_VISION_INSTANCE_CHECK(handle);
mv_roi_tracker_result_s *result)
{
MEDIA_VISION_SUPPORT_CHECK(
- __mv_inference_face_check_system_info_feature_supported());
+ __mv_roi_tracking_check_system_info_feature_supported());
MEDIA_VISION_INSTANCE_CHECK(handle);
MEDIA_VISION_INSTANCE_CHECK(source);