${INC_IMAGE}
${INC_SURVEILLANCE})
-SET(dependents "dlog capi-media-tool capi-system-info capi-appfw-application")
+SET(dependents "dlog capi-media-tool capi-system-info")
SET(pc_dependents "dlog")
INCLUDE(FindPkgConfig)
* This examples can be removed by
* @ref mv_face_recognition_model_reset() function if
* it is needed to clear the memory.
- * @remarks @a recognition_model is saved to the application's data directory.
+ * @remarks @a recognition_model is saved to the absolute path directory.
+ * Use @ref app_get_data_path for the private app storage path or
+ * @ref app_get_shared_data_path for the app shared storage path.
* After model is saved to the file, it can be loaded from this file
* by @ref mv_face_recognition_model_load() function.
- * @param [in] file_name Name of the file to save the model
+ * @param [in] file_name Name of the path/file to save the model
* @param [in] recognition_model The handle to the recognition model to be
* saved to the file
* @return @c 0 on success, otherwise a negative error value
*
* @see mv_face_recognition_model_load()
* @see mv_face_recognition_model_create()
+ * @see app_get_data_path()
+ * @see app_get_shared_data_path()
*/
int mv_face_recognition_model_save(
const char *file_name,
* @ref mv_face_recognition_model_reset() function. It
* is recommended to clear the memory if learning algorithm doesn't
* support reinforcement learning.
- * @remarks @a recognition_model is loaded from the application's data directory.
+ * @remarks @a recognition_model is loaded from the absolute path directory.
+ * Use @ref app_get_data_path for the private app storage path or
+ * @ref app_get_shared_data_path for the app shared storage path.
* @a recognition_model must be destroyed using
* @ref mv_face_recognition_model_destroy().
- * @param [in] file_name Name of file to load the model
+ * @param [in] file_name Name of path/file to load the model
* @param [out] recognition_model The handle to the recognition model
* to be loaded from the file
* @return @c 0 on success, otherwise a negative error value
*
* @see mv_face_recognition_model_save()
* @see mv_face_recognition_model_destroy()
+ * @see app_get_data_path()
+ * @see app_get_shared_data_path()
*/
int mv_face_recognition_model_load(
const char *file_name,
* @brief Calls this method to save tracking model to the file.
*
* @since_tizen 3.0
- * @remarks @ tracking_model is saved to the application's data directory.
+ * @remarks @a tracking_model is saved to the absolute path directory.
+ * Use @ref app_get_data_path for the private app storage path or
+ * @ref app_get_shared_data_path for the app shared storage path.
* After model is saved to the file, it can be loaded from this file
* with @ref mv_face_tracking_model_load() function.
- * @param [in] file_name Name of the file to save the model
+ * @param [in] file_name Name of the path/file to save the model
* @param [in] tracking_model The handle to the tracking model to be
* saved to the file
* @return @c 0 on success, otherwise a negative error value
*
* @see mv_face_tracking_model_load()
* @see mv_face_tracking_model_create()
+ * @see app_get_data_path()
+ * @see app_get_shared_data_path()
*/
int mv_face_tracking_model_save(
const char *file_name,
* @brief Calls this method to load a tracking model from file.
*
* @since_tizen 3.0
- * @remarks @a tracking_model is loaded from the application's data directory.
+ * @remarks @a tracking_model is loaded from the absolute path directory.
+ * Use @ref app_get_data_path for the private app storage path or
+ * @ref app_get_shared_data_path for the app shared storage path.
* @a tracking_model must be destroyed using
* @ref mv_face_tracking_model_destroy.
- * @param [in] file_name Name of file to load the model
+ * @param [in] file_name Name of path/file to load the model
* @param [out] tracking_model The handle to the tracking model to be
* loaded from file
* @return @c 0 on success, otherwise a negative error value
*
* @see mv_face_tracking_model_save()
* @see mv_face_tracking_model_destroy()
+ * @see app_get_data_path()
+ * @see app_get_shared_data_path()
*/
int mv_face_tracking_model_load(
const char *file_name,
* @brief Saves the image object.
*
* @since_tizen 3.0
- * @remarks @a image_object is saved to the application's data directory.
- * @param [in] file_name Name of the file to save the image object
+ * @remarks @a image_object is saved to the absolute path directory.
+ * Use @ref app_get_data_path for the private app storage path or
+ * @ref app_get_shared_data_path for the app shared storage path.
+ * @param [in] file_name Name of the file to path/save the image object
* @param [in] image_object The handle to the image object which will be saved
* @return @c 0 on success, otherwise a negative error value
* @retval #MEDIA_VISION_ERROR_NONE Successful
* @brief Loads an image object from the file.
*
* @since_tizen 3.0
- * @remarks @a image_object is loaded from the application's data directory.
+ * @remarks @a image_object is loaded from the absolute path directory.
+ * Use @ref app_get_data_path for the private app storage path or
+ * @ref app_get_shared_data_path for the app shared storage path.
* @a image_object must be destroyed using
* @ref mv_image_object_destroy().
- * @param [in] file_name Name of file to load the image object
+ * @param [in] file_name Name of path/file to load the image object
* @param [out] image_object The handle to the image object which will be
* filled
* @return @c 0 on success, otherwise a negative error value
* @brief Saves the image tracking model.
*
* @since_tizen 3.0
- * @remarks @a image_tracking_model is saved to the application's data directory.
- * @param [in] file_name Name of file to save the model
+ * @remarks @a image_tracking_model is saved to the absolute path directory.
+ * Use @ref app_get_data_path for the private app storage path or
+ * @ref app_get_shared_data_path for the app shared storage path.
+ * @param [in] file_name Name of path/file to save the model
* @param [in] image_tracking_model The handle to the image tracking model
* to be saved
* @return @c 0 on success, otherwise a negative error value
* @brief Loads an image tracking model from the file.
*
* @since_tizen 3.0
- * @remarks @a image_tracking_model is loaded from the application's data directory.
+ * @remarks @a image_tracking_model is loaded from the absolute path directory.
+ * Use @ref app_get_data_path for the private app storage path or
+ * @ref app_get_shared_data_path for the app shared storage path.
* @a image_tracking_model must be destroyed using
* @ref mv_image_tracking_model_destroy.
- * @param [in] file_name Name of file to load model
+ * @param [in] file_name Name of path/file to load model
* @param [out] image_tracking_model The handle to the image tracking
* model to be filled
* @return @c 0 on success, otherwise a negative error value
#include "mv_private.h"
#include "mv_common.h"
-#include <app_common.h>
-
#include <map>
#include <stdio.h>
if (!m_recognizer.empty()) {
std::string filePath;
- char *cPath = app_get_data_path();
- if (NULL == cPath)
- filePath = fileName;
- else
- filePath = std::string(cPath) + fileName;
+
+ filePath = fileName;
std::string prefixPath = filePath.substr(0, filePath.find_last_of('/'));
LOGD("prefixPath: %s", prefixPath.c_str());
int FaceRecognitionModel::load(const std::string& fileName)
{
std::string filePath;
- char *cPath = app_get_data_path();
- if (NULL == cPath)
- filePath = fileName;
- else
- filePath = std::string(cPath) + fileName;
+
+ filePath = fileName;
if (access(filePath.c_str(), F_OK)) {
LOGE("Can't load face recognition model. File[%s] doesn't existed.", filePath.c_str());
#include "mv_private.h"
#include "mv_common.h"
-#include <app_common.h>
-
#include <unistd.h>
namespace MediaVision {
}
std::string filePath;
- char *cPath = app_get_data_path();
- if (NULL == cPath)
- filePath = fileName;
- else
- filePath = std::string(cPath) + fileName;
+
+ filePath = fileName;
std::string prefixPath = filePath.substr(0, filePath.find_last_of('/'));
LOGD("prefixPath: %s", prefixPath.c_str());
int FaceTrackingModel::load(const std::string& fileName)
{
std::string filePath;
- char *cPath = app_get_data_path();
- if (NULL == cPath)
- filePath = fileName;
- else
- filePath = std::string(cPath) + fileName;
+
+ filePath = fileName;
if (access(filePath.c_str(), F_OK)) {
LOGE("Can't load face tracking model. File[%s] doesn't existed.", filePath.c_str());
#include "mv_private.h"
#include "mv_common.h"
-#include <app_common.h>
-
#include <opencv/cv.h>
#include <opencv2/features2d/features2d.hpp>
int ImageObject::save(const char *fileName) const
{
std::string filePath;
- char *cPath = app_get_data_path();
- if (NULL == cPath)
- filePath = fileName;
- else
- filePath = std::string(cPath) + std::string(fileName);
+
+ filePath = fileName;
std::string prefixPath = filePath.substr(0, filePath.find_last_of('/'));
LOGD("prefixPath: %s", prefixPath.c_str());
int ImageObject::load(const char *fileName)
{
std::string filePath;
- char *cPath = app_get_data_path();
- if (NULL == cPath)
- filePath = fileName;
- else
- filePath = std::string(cPath) + std::string(fileName);
+
+ filePath = fileName;
if (access(filePath.c_str(), F_OK)) {
LOGE("Can't load image object model. Path[%s] doesn't existed.", filePath.c_str());
#include "mv_private.h"
#include "mv_common.h"
-#include <app_common.h>
-
#include <fstream>
#include <unistd.h>
int ImageTrackingModel::save(const char *filepath) const
{
std::string filePath;
- char *cPath = app_get_data_path();
- if (NULL == cPath)
- filePath = std::string(filepath);
- else
- filePath = std::string(cPath) + std::string(filepath);
+
+ filePath = std::string(filepath);
std::string prefixPath = filePath.substr(0, filePath.find_last_of('/'));
LOGD("prefixPath: %s", prefixPath.c_str());
int ImageTrackingModel::load(const char *filepath)
{
std::string filePath;
- char *cPath = app_get_data_path();
- if (NULL == cPath)
- filePath = std::string(filepath);
- else
- filePath = std::string(cPath) + std::string(filepath);
+
+ filePath = std::string(filepath);
if (access(filePath.c_str(),F_OK)) {
LOGE("Can't load tracking model. Path[%s] doesn't existed.", filepath);
Name: capi-media-vision
Summary: Media Vision library for Tizen Native API
-Version: 0.3.3
+Version: 0.3.4
Release: 0
Group: Multimedia/Framework
License: Apache-2.0 and BSD-2.0
Source0: %{name}-%{version}.tar.gz
BuildRequires: cmake
BuildRequires: pkgconfig(capi-media-tool)
-BuildRequires: pkgconfig(capi-appfw-application)
BuildRequires: pkgconfig(libtbm)
BuildRequires: pkgconfig(dlog)
BuildRequires: pkgconfig(capi-system-info)