Added MediaVision Code.Updated license file
authorrajeev ranjan <rajeev.ran@samsung.com>
Wed, 26 Oct 2016 07:23:29 +0000 (12:53 +0530)
committerPraveen Gattu <gattu.p@samsung.com>
Fri, 4 Nov 2016 06:30:14 +0000 (12:00 +0530)
Change-Id: Iaf34f0c34ec80fbaeaa6f22977cacde0b8125a6a
Signed-off-by: rajeev ranjan <rajeev.ran@samsung.com>
55 files changed:
src/Tizen.Multimedia/Interop/Interop.Libraries.cs
src/Tizen.Multimedia/Interop/Interop.MediaVision.BarCode.cs [new file with mode: 0755]
src/Tizen.Multimedia/Interop/Interop.MediaVision.Common.cs [new file with mode: 0755]
src/Tizen.Multimedia/Interop/Interop.MediaVision.Face.cs [new file with mode: 0755]
src/Tizen.Multimedia/Interop/Interop.MediaVision.Image.cs [new file with mode: 0755]
src/Tizen.Multimedia/Interop/Interop.MediaVision.Surveillance.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/Barcode.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/BarcodeDetector.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/BarcodeDetectorEngineConfiguration.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/BarcodeGenerator.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/BarcodeGeneratorEngineConfiguration.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/BarcodeImageConfiguration.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/BarcodeImageFormat.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/BarcodeType.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/Colorspace.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/EngineConfiguration.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/ErrorCorrectionLevel.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/EyeCondition.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceDetectionResult.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceDetector.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceEngineConfiguration.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceRecognitionModel.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceRecognitionModelType.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceRecognitionResult.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceRecognizer.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceTracker.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceTrackingModel.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FaceTrackingResult.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/FacialExpression.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/Image.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/ImageEngineConfiguration.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/ImageRecognitionResult.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/ImageRecognizer.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/ImageTracker.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/ImageTrackingModel.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/MediaVisionErrorFactory.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/MediaVisionSource.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/MovementDetectedEventArgs.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/MovementDetectionEventTrigger.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/PersonAppearanceChangedEventArgs.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/PersonAppearanceEventTrigger.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/PersonRecognitionEventTrigger.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/PersonRecognitionResult.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/PersonRecognizedEventArgs.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/Point.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/QrConfiguration.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/QrMode.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/Quadrangle.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/Rectangle.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/SurveillanceEngineConfiguration.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/SurveillanceEventTrigger.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/TargetAttribute.cs [new file with mode: 0755]
src/Tizen.Multimedia/MediaVision/TextAttribute.cs [new file with mode: 0755]
src/Tizen.Multimedia/Tizen.Multimedia.Net45.csproj
src/Tizen.Multimedia/Tizen.Multimedia.csproj

index e763d38..b52bc4e 100755 (executable)
@@ -1,5 +1,18 @@
-
-using System;
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
 
 internal static partial class Interop
 {
@@ -13,6 +26,7 @@ internal static partial class Interop
         public const string MediaController = "libcapi-media-controller.so.0";
         public const string MediaTool = "libcapi-media-tool.so.0";
         public const string MediaCodec = "libcapi-media-codec.so.0";
+        public const string MediaVision = "libcapi-media-vision.so.0";
         public const string Libc = "libc.so.6";
         public const string Camera = "libcapi-media-camera.so.0";
     }
diff --git a/src/Tizen.Multimedia/Interop/Interop.MediaVision.BarCode.cs b/src/Tizen.Multimedia/Interop/Interop.MediaVision.BarCode.cs
new file mode 100755 (executable)
index 0000000..fd60193
--- /dev/null
@@ -0,0 +1,55 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using Tizen.Multimedia;
+
+/// <summary>
+/// Interop APIs
+/// </summary>
+internal static partial class Interop
+{
+    /// <summary>
+    /// Interop for media vision APIs
+    /// </summary>
+    internal static partial class MediaVision
+    {
+        /// <summary>
+        /// Interop for barcode detector APIs
+        /// </summary>
+        internal static partial class BarCodeDetector
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_barcode_detect")]
+            internal static extern int Detect(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, Rectangle roi, MvBarcodeDetectedCallback detectCb, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvBarcodeDetectedCallback(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr barcodeLocations, IntPtr messages, IntPtr /* mv_barcode_type_e */ types, int numberOfBarcodes, IntPtr /* void */ userData);
+        }
+
+        /// <summary>
+        /// Interop for barcode generator APIs
+        /// </summary>
+        internal static partial class BarCodeGenerator
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_barcode_generate_source")]
+            internal static extern int GenerateSource(IntPtr /* mv_engine_config_h */ engineCfg, string message, BarcodeType /* mv_barcode_type_e */ type, QrMode /* mv_barcode_qr_mode_e */ qrEncMode, ErrorCorrectionLevel /* mv_barcode_qr_ecc_e */ qrEcc, int qrVersion, IntPtr /* mv_source_h */ image);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_barcode_generate_image")]
+            internal static extern int GenerateImage(IntPtr /* mv_engine_config_h */ engineCfg, string message, int imageWidth, int imageHeight, BarcodeType /* mv_barcode_type_e */ type, QrMode /* mv_barcode_qr_mode_e */ qrEncMode, ErrorCorrectionLevel /* mv_barcode_qr_ecc_e */ qrEcc, int qrVersion, string imagePath, BarcodeImageFormat /* mv_barcode_image_format_e */ imageFormat);
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/Interop/Interop.MediaVision.Common.cs b/src/Tizen.Multimedia/Interop/Interop.MediaVision.Common.cs
new file mode 100755 (executable)
index 0000000..bb93798
--- /dev/null
@@ -0,0 +1,124 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+
+/// <summary>
+/// Interop APIs
+/// </summary>
+internal static partial class Interop
+{
+    /// <summary>
+    /// Interop for media vision APIs
+    /// </summary>
+    internal static partial class MediaVision
+    {
+        [StructLayout(LayoutKind.Sequential)]
+        internal struct Point
+        {
+            internal int x;
+            internal int y;
+        };
+
+        [StructLayout(LayoutKind.Sequential)]
+        internal struct Rectangle
+        {
+            internal int x;
+            internal int y;
+            internal int width;
+            internal int height;
+        };
+
+        [StructLayout(LayoutKind.Sequential)]
+        internal struct Quadrangle
+        {
+            internal int x1, y1;
+            internal int x2, y2;
+            internal int x3, y3;
+            internal int x4, y4;
+        };
+
+        /// <summary>
+        /// Interop for media vision source APIs
+        /// </summary>
+        internal static partial class MediaSource
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_create_source")]
+            internal static extern int Create(out IntPtr /* mv_source_h */ source);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_destroy_source")]
+            internal static extern int Destroy(IntPtr /* mv_source_h */ source);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_source_fill_by_media_packet")]
+            internal static extern int FillMediaPacket(IntPtr /* mv_source_h */ source, IntPtr /* media_packet_h */ mediaPacket);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_source_fill_by_buffer")]
+            internal static extern int FillBuffer(IntPtr /* mv_source_h */ source, byte[] buffer, int bufferSize, uint imageWidth, uint imageHeight, Tizen.Multimedia.Colorspace colorspace);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_source_clear")]
+            internal static extern int Clear(IntPtr /* mv_source_h */ source);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_source_get_buffer")]
+            internal static extern int GetBuffer(IntPtr /* mv_source_h */ source, out IntPtr buffer, out int bufferSize);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_source_get_height")]
+            internal static extern int GetHeight(IntPtr /* mv_source_h */ source, out uint imageHeight);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_source_get_width")]
+            internal static extern int GetWidth(IntPtr /* mv_source_h */ source, out uint imageWidth);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_source_get_colorspace")]
+            internal static extern int GetColorspace(IntPtr /* mv_source_h */ source, out Tizen.Multimedia.Colorspace colorspace);
+        }
+
+        /// <summary>
+        /// Interop for engine configuration APIs
+        /// </summary>
+        internal static partial class EngineConfig
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_create_engine_config")]
+            internal static extern int Create(out IntPtr /* mv_engine_config_h */ engineConfig);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_destroy_engine_config")]
+            internal static extern int Destroy(IntPtr /* mv_engine_config_h */ engineConfig);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_engine_config_set_double_attribute")]
+            internal static extern int SetDouble(IntPtr /* mv_engine_config_h */ source, string name, double value);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_engine_config_set_int_attribute")]
+            internal static extern int SetInt(IntPtr /* mv_engine_config_h */ source, string name, int value);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_engine_config_set_bool_attribute")]
+            internal static extern int SetBool(IntPtr /* mv_engine_config_h */ source, string name, bool value);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_engine_config_set_string_attribute")]
+            internal static extern int SetString(IntPtr /* mv_engine_config_h */ source, string name, string value);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_engine_config_get_double_attribute")]
+            internal static extern int GetDouble(IntPtr /* mv_engine_config_h */ source, string name, out double value);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_engine_config_get_int_attribute")]
+            internal static extern int GetInt(IntPtr /* mv_engine_config_h */ source, string name, out int value);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_engine_config_get_bool_attribute")]
+            internal static extern int GetBool(IntPtr /* mv_engine_config_h */ source, string name, out bool value);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_engine_config_get_string_attribute")]
+            internal static extern int GetString(IntPtr /* mv_engine_config_h */ source, string name, out string value);
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/Interop/Interop.MediaVision.Face.cs b/src/Tizen.Multimedia/Interop/Interop.MediaVision.Face.cs
new file mode 100755 (executable)
index 0000000..cdd065c
--- /dev/null
@@ -0,0 +1,127 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using Tizen.Multimedia;
+
+/// <summary>
+/// Interop APIs
+/// </summary>
+internal static partial class Interop
+{
+    /// <summary>
+    /// Interop for media vision APIs
+    /// </summary>
+    internal static partial class MediaVision
+    {
+        /// <summary>
+        /// Interop for Face APIs
+        /// </summary>
+        internal static partial class Face
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_detect")]
+            internal static extern int Detect(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, MvFaceDetectedCallback detectedCb, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognize")]
+            internal static extern int Recognize(IntPtr /* mv_source_h */ source, IntPtr /* mv_face_recognition_model_h */ recognitionModel, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr faceLocation, MvFaceRecognizedCallback recognizedCb, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_track")]
+            internal static extern int Track(IntPtr /* mv_source_h */ source, IntPtr /* mv_face_tracking_model_h */ trackingModel, IntPtr /* mv_engine_config_h */ engineCfg, MvFaceTrackedCallback trackedCb, bool doLearn, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_eye_condition_recognize")]
+            internal static extern int RecognizeEyeCondition(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, Rectangle faceLocation, MvFaceEyeConditionRecognizedCallback eyeConditionRecognizedCb, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_facial_expression_recognize")]
+            internal static extern int RecognizeFacialExpression(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, Rectangle faceLocation, MvFaceFacialExpressionRecognizedCallback expressionRecognizedCb, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvFaceDetectedCallback(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr facesLocations, int numberOfFaces, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvFaceRecognizedCallback(IntPtr /* mv_source_h */ source, IntPtr /* mv_face_recognition_model_h */ recognitionModel, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr faceLocation, IntPtr faceLabel, double confidence, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvFaceTrackedCallback(IntPtr /* mv_source_h */ source, IntPtr /* mv_face_tracking_model_h */ trackingModel, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr location, double confidence, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvFaceEyeConditionRecognizedCallback(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, Rectangle faceLocation, EyeCondition /* mv_face_eye_condition_e */ eyeCondition, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvFaceFacialExpressionRecognizedCallback(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, Rectangle faceLocation, FacialExpression /* mv_face_facial_expression_e */ facialExpression, IntPtr /* void */ userData);
+        }
+
+        /// <summary>
+        /// Interop for FaceRecognitionModel APIs
+        /// </summary>
+        internal static partial class FaceRecognitionModel
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_create")]
+            internal static extern int Create(out IntPtr /* mv_face_recognition_model_h */ recognitionModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_destroy")]
+            internal static extern int Destroy(IntPtr /* mv_face_recognition_model_h */ recognitionModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_clone")]
+            internal static extern int Clone(IntPtr /* mv_face_recognition_model_h */ src, out IntPtr /* mv_face_recognition_model_h */ dst);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_save")]
+            internal static extern int Save(string fileName, IntPtr /* mv_face_recognition_model_h */ recognitionModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_load")]
+            internal static extern int Load(string fileName, out IntPtr /* mv_face_recognition_model_h */ recognitionModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_add")]
+            internal static extern int Add(IntPtr /* mv_source_h */ source, IntPtr /* mv_face_recognition_model_h */ recognitionModel, IntPtr exampleLocation, int faceLabel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_reset")]
+            internal static extern int Reset(IntPtr /* mv_face_recognition_model_h */ recognitionModel, IntPtr faceLabel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_reset")]
+            internal static extern int Remove(IntPtr /* mv_face_recognition_model_h */ recognitionModel, ref int faceLabel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_learn")]
+            internal static extern int Learn(IntPtr /* mv_engine_config_h */ engineCfg, IntPtr /* mv_face_recognition_model_h */ recognitionModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_recognition_model_query_labels")]
+            internal static extern int QueryLabels(IntPtr /* mv_face_recognition_model_h */ recognitionModel, out IntPtr labels, out uint numberOfLabels);
+        }
+
+        /// <summary>
+        /// Interop for FaceTrackingModel APIs
+        /// </summary>
+        internal static partial class FaceTrackingModel
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_tracking_model_create")]
+            internal static extern int Create(out IntPtr /* mv_face_tracking_model_h */ trackingModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_tracking_model_destroy")]
+            internal static extern int Destroy(IntPtr /* mv_face_tracking_model_h */ trackingModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_tracking_model_prepare")]
+            internal static extern int Prepare(IntPtr /* mv_face_tracking_model_h */ trackingModel, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr /* mv_source_h */ source, IntPtr location);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_tracking_model_clone")]
+            internal static extern int Clone(IntPtr /* mv_face_tracking_model_h */ src, out IntPtr /* mv_face_tracking_model_h */ dst);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_tracking_model_save")]
+            internal static extern int Save(string fileName, IntPtr /* mv_face_tracking_model_h */ trackingModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_face_tracking_model_load")]
+            internal static extern int Load(string fileName, out IntPtr /* mv_face_tracking_model_h */ trackingModel);
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/Interop/Interop.MediaVision.Image.cs b/src/Tizen.Multimedia/Interop/Interop.MediaVision.Image.cs
new file mode 100755 (executable)
index 0000000..0aa9834
--- /dev/null
@@ -0,0 +1,102 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+
+/// <summary>
+/// Interop APIs
+/// </summary>
+internal static partial class Interop
+{
+    /// <summary>
+    /// Interop for Media vision APIs
+    /// </summary>
+    internal static partial class MediaVision
+    {
+        /// <summary>
+        /// Interop for Image APIs
+        /// </summary>
+        internal static partial class Image
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_recognize")]
+            internal static extern int Recognize(IntPtr /* mv_source_h */ source, IntPtr /* mv_image_object_h */ imageObjects, int numberOfObjects, IntPtr /* mv_engine_config_h */ engineCfg, MvImageRecognizedCallback recognizedCb, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_track")]
+            internal static extern int Track(IntPtr /* mv_source_h */ source, IntPtr /* mv_image_tracking_model_h */ imageTrackingModel, IntPtr /* mv_engine_config_h */ engineCfg, MvImageTrackedCallback trackedCb, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_create")]
+            internal static extern int Create(out IntPtr /* mv_image_object_h */ imageObject);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_destroy")]
+            internal static extern int Destroy(IntPtr /* mv_image_object_h */ imageObject);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_fill")]
+            internal static extern int Fill(IntPtr /* mv_image_object_h */ imageObject, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr /* mv_source_h */ source, IntPtr location);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_get_recognition_rate")]
+            internal static extern int GetRecognitionRate(IntPtr /* mv_image_object_h */ imageObject, out double recognitionRate);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_set_label")]
+            internal static extern int SetLabel(IntPtr /* mv_image_object_h */ imageObject, int label);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_get_label")]
+            internal static extern int GetLabel(IntPtr /* mv_image_object_h */ imageObject, out int label);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_clone")]
+            internal static extern int Clone(IntPtr /* mv_image_object_h */ src, out IntPtr /* mv_image_object_h */ dst);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_save")]
+            internal static extern int Save(string fileName, IntPtr /* mv_image_object_h */ imageObject);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_object_load")]
+            internal static extern int Load(string fileName, out IntPtr /* mv_image_object_h */ imageObject);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvImageRecognizedCallback(IntPtr /* mv_source_h */ source, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr /* mv_image_object_h */ imageObjects, IntPtr locations, uint numberOfObjects, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvImageTrackedCallback(IntPtr /* mv_source_h */ source, IntPtr /* mv_image_tracking_model_h */ imageTrackingModel, IntPtr /* mv_engine_config_h */ engineCfg, IntPtr location, IntPtr /* void */ userData);
+        }
+
+        /// <summary>
+        /// Interop for ImageTrackingModel APIs
+        /// </summary>
+        internal static partial class ImageTrackingModel
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_tracking_model_create")]
+            internal static extern int Create(out IntPtr /* mv_image_tracking_model_h */ imageTrackingModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_tracking_model_set_target")]
+            internal static extern int SetTarget(IntPtr /* mv_image_object_h */ imageObject, IntPtr /* mv_image_tracking_model_h */ imageTrackingModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_tracking_model_destroy")]
+            internal static extern int Destroy(IntPtr /* mv_image_tracking_model_h */ imageTrackingModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_tracking_model_refresh")]
+            internal static extern int Refresh(IntPtr /* mv_image_tracking_model_h */ imageTrackingModel, IntPtr /* mv_engine_config_h */ engineCfg);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_tracking_model_clone")]
+            internal static extern int Clone(IntPtr /* mv_image_tracking_model_h */ src, out IntPtr /* mv_image_tracking_model_h */ dest);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_tracking_model_save")]
+            internal static extern int Save(string fileName, IntPtr /* mv_image_tracking_model_h */ imageTrackingModel);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_image_tracking_model_load")]
+            internal static extern int Load(string fileName, out IntPtr /* mv_image_tracking_model_h */ imageTrackingModel);
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/Interop/Interop.MediaVision.Surveillance.cs b/src/Tizen.Multimedia/Interop/Interop.MediaVision.Surveillance.cs
new file mode 100755 (executable)
index 0000000..6c0ac1e
--- /dev/null
@@ -0,0 +1,81 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+
+/// <summary>
+/// Interop APIs
+/// </summary>
+internal static partial class Interop
+{
+    /// <summary>
+    /// Interop for media vision APIs
+    /// </summary>
+    internal static partial class MediaVision
+    {
+        /// <summary>
+        /// Interop for surveillance APIs
+        /// </summary>
+        internal static partial class Surveillance
+        {
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_event_trigger_create")]
+            internal static extern int EventTriggerCreate(string eventType, out IntPtr /* mv_surveillance_event_trigger_h */ trigger);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_event_trigger_destroy")]
+            internal static extern int EventTriggerDestroy(IntPtr /* mv_surveillance_event_trigger_h */ trigger);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_get_event_trigger_type")]
+            internal static extern int GetEventTriggerType(IntPtr /* mv_surveillance_event_trigger_h */ trigger, out string eventType);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_set_event_trigger_roi")]
+            internal static extern int SetEventTriggerRoi(IntPtr /* mv_surveillance_event_trigger_h */ trigger, int numberOfPoints, IntPtr roi);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_get_event_trigger_roi")]
+            internal static extern int GetEventTriggerRoi(IntPtr /* mv_surveillance_event_trigger_h */ trigger, out int numberOfPoints, out IntPtr roi);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_subscribe_event_trigger")]
+            internal static extern int SubscribeEventTrigger(IntPtr /* mv_surveillance_event_trigger_h */ trigger, int videoStreamId, IntPtr /* mv_engine_config_h */ engineCfg, MvSurveillanceEventOccurredCallback callback, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_unsubscribe_event_trigger")]
+            internal static extern int UnsubscribeEventTrigger(IntPtr /* mv_surveillance_event_trigger_h */ trigger, int videoStreamId);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_push_source")]
+            internal static extern int PushSource(IntPtr /* mv_source_h */ source, int videoStreamId);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_foreach_supported_event_type")]
+            internal static extern int ForeachSupportedEventType(MvSurveillanceEventTypeCallback callback, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_foreach_event_result_name")]
+            internal static extern int ForeachEventResultName(string eventType, MvSurveillanceEventResultNameCallback callback, IntPtr /* void */ userData);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_get_result_value")]
+            internal static extern int GetResultCount(IntPtr /* mv_surveillance_result_h */ result, string name, out int /* void */ value);
+
+            [DllImport(Libraries.MediaVision, EntryPoint = "mv_surveillance_get_result_value")]
+            internal static extern int GetResultValue(IntPtr /* mv_surveillance_result_h */ result, string name, IntPtr /* void */ value);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate void MvSurveillanceEventOccurredCallback(IntPtr /* mv_surveillance_event_trigger_h */ trigger, IntPtr /* mv_source_h */ source, int videoStreamId, IntPtr /* mv_surveillance_result_h */ eventResult, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate bool MvSurveillanceEventTypeCallback(string eventType, IntPtr /* void */ userData);
+
+            [UnmanagedFunctionPointerAttribute(CallingConvention.Cdecl)]
+            internal delegate bool MvSurveillanceEventResultNameCallback(string name, IntPtr /* void */ userData);
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/Barcode.cs b/src/Tizen.Multimedia/MediaVision/Barcode.cs
new file mode 100755 (executable)
index 0000000..1fc5c25
--- /dev/null
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents a detected barcode.
+    /// </summary>
+    public class Barcode
+    {
+        internal Barcode()
+        {
+        }
+
+        /// <summary>
+        /// The quadrangle location of detected barcode
+        /// </summary>
+        public Quadrangle Location { get; internal set; }
+
+        /// <summary>
+        /// The decoded message of barcode
+        /// </summary>
+        public string Message { get; internal set; }
+
+        /// <summary>
+        /// The type of detected barcode
+        /// </summary>
+        public BarcodeType Type { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/BarcodeDetector.cs b/src/Tizen.Multimedia/MediaVision/BarcodeDetector.cs
new file mode 100755 (executable)
index 0000000..2f91b15
--- /dev/null
@@ -0,0 +1,110 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+using System.Runtime.InteropServices;
+using System.Threading.Tasks;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class contains the Media Vision barcode detect API.\n
+    /// These APIs can be used for detecting barcodes on image sources, reading encoded messages, getting barcode types.
+    /// </summary>
+    public static class BarcodeDetector
+    {
+        /// <summary>
+        /// Detects barcode(s) on source and reads message from it.
+        /// </summary>
+        /// <param name="source">The media vision source object</param>
+        /// <param name="config">The configuration of the barcode detector engine </param>
+        /// <param name="roi">Region of interest - rectangular area on the source which will be used for barcode detection Note that roi should be inside area on the source.</param>
+        /// <returns>Returns list of barcode detected asynchronously</returns>
+        /// <code>
+        ///
+        /// </code>
+        public static async Task<List<Barcode>> DetectAsync(MediaVisionSource source, BarcodeDetectorEngineConfiguration config, Rectangle roi)
+        {
+            TaskCompletionSource<List<Barcode>> tcsBarcodeList = new TaskCompletionSource<List<Barcode>>();
+            Interop.MediaVision.Rectangle rectangle = new Interop.MediaVision.Rectangle()
+            {
+                x = roi.Point.X,
+                y = roi.Point.Y,
+                width = roi.Width,
+                height = roi.Height
+            };
+
+            // Define native callback
+            Interop.MediaVision.BarCodeDetector.MvBarcodeDetectedCallback detectedCb = (IntPtr mvSource, IntPtr engineCfg, IntPtr barcodeLocations, IntPtr messages, IntPtr types, int numberOfBarcodes, IntPtr userData) =>
+            {
+                try
+                {
+                    Log.Info(MediaVisionLog.Tag, String.Format("Barcodes detected, count : {0}", numberOfBarcodes));
+                    List<Barcode> barcodes = new List<Barcode>();
+                    if (numberOfBarcodes > 0)
+                    {
+                        IntPtr[] msgPtr = new IntPtr[numberOfBarcodes];
+                        Marshal.Copy(messages, msgPtr, 0, numberOfBarcodes);
+
+                        // Prepare list of barcodes
+                        for (int i = 0; i < numberOfBarcodes; i++)
+                        {
+                            Interop.MediaVision.Quadrangle location = (Interop.MediaVision.Quadrangle)Marshal.PtrToStructure(barcodeLocations, typeof(Interop.MediaVision.Quadrangle));
+                            string message = Marshal.PtrToStringAnsi(msgPtr[i]);
+                            BarcodeType type = (BarcodeType)Marshal.ReadInt32(types);
+                            Quadrangle quadrangle = new Quadrangle()
+                            {
+                                Points = new Point[4]
+                                {
+                                    new Point(location.x1, location.y1),
+                                    new Point(location.x2, location.y2),
+                                    new Point(location.x3, location.y3),
+                                    new Point(location.x4, location.y4)
+                                }
+                            };
+                            Log.Info(MediaVisionLog.Tag, String.Format("Location : {0}, Message : {1}, Type : {2}", quadrangle.ToString(), message, type));
+                            Barcode barcode = new Barcode()
+                            {
+                                Location = quadrangle,
+                                Message = message,
+                                Type = type
+                            };
+                            barcodes.Add(barcode);
+                            barcodeLocations = IntPtr.Add(barcodeLocations, sizeof(int) * 8);
+                            types = IntPtr.Add(barcodeLocations, sizeof(BarcodeType));
+                        }
+                    }
+
+                    if (!tcsBarcodeList.TrySetResult(barcodes))
+                    {
+                        Log.Info(MediaVisionLog.Tag, "Failed to set result");
+                        tcsBarcodeList.TrySetException(new InvalidOperationException("Failed to set result"));
+                    }
+                }
+                catch(Exception ex)
+                {
+                    Log.Info(MediaVisionLog.Tag, "exception :" + ex.ToString());
+                    tcsBarcodeList.TrySetException(ex);
+                }
+            };
+            int ret = Interop.MediaVision.BarCodeDetector.Detect(source._sourceHandle, config._engineHandle, rectangle, detectedCb, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to detect barcode.");
+            return await tcsBarcodeList.Task;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/BarcodeDetectorEngineConfiguration.cs b/src/Tizen.Multimedia/MediaVision/BarcodeDetectorEngineConfiguration.cs
new file mode 100755 (executable)
index 0000000..130754b
--- /dev/null
@@ -0,0 +1,73 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents concrete EngineConfig for BarcodeDetector
+    /// </summary>
+    public class BarcodeDetectorEngineConfiguration : EngineConfiguration
+    {
+        private const string _targetAttributeKey = "MV_BARCODE_DETECT_ATTR_TARGET";
+        private TargetAttribute _targetAttr = TargetAttribute.All;
+
+        /// <summary>
+        /// The default constructor of BarcodeDetectorEngineConfig class
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public BarcodeDetectorEngineConfiguration()
+            : base()
+        {
+        }
+
+        /// <summary>
+        /// Sets and gets target attribute of the engine configuration
+        /// </summary>
+        public TargetAttribute TargetAttribute
+        {
+            get
+            {
+                return _targetAttr;
+            }
+
+            set
+            {
+                if (!IsValid(value))
+                {
+                    throw new ArgumentException("TargetAttribute value is invalid");
+                }
+
+                Add<int>(_targetAttributeKey, (int)value);
+                _targetAttr = value;
+            }
+        }
+
+        private bool IsValid(TargetAttribute value)
+        {
+            if (value == TargetAttribute.Unavailable)
+            {
+                Log.Error(MediaVisionLog.Tag, "Invalid TargetAttribute");
+                return false;
+            }
+
+            return true;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/BarcodeGenerator.cs b/src/Tizen.Multimedia/MediaVision/BarcodeGenerator.cs
new file mode 100755 (executable)
index 0000000..01559c8
--- /dev/null
@@ -0,0 +1,119 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class contains the Media Vision barcode generate API.\n
+    /// These APIs can be used for generating the barcodes and QR codes.
+    /// Different encoding types <see cref="QrMode"/> , error correction codes <see cref="ErrorCorrectionLevel"/>  and code versions are supported for QRCodes.
+    /// </summary>
+    public static class BarcodeGenerator
+    {
+        /// <summary>
+        /// Generates <see cref="MediaVisionSource"/> with barcode image.
+        /// </summary>
+        /// <remarks>
+        /// If the text attribute of engine configuration is set to <see cref="TextAttribute.Visible"/> , InvalidOperationException will be thrown when type is <see cref="BarcodeType.QR"/>
+        /// </remarks>
+        /// <param name="config">The configuration of the bar code generator engine</param>
+        /// <param name="message">The message to be encoded in the barcode</param>
+        /// <param name="type">Type of the barcode to be generated</param>
+        /// <param name="source">The media vision source object which will be used to fill by the buffer with generated image</param>
+        /// <param name="qrConfig">The QrConfig object - required for QR codes only</param>
+        /// <code>
+        /// 
+        /// </code>
+        public static MediaVisionSource GenerateSource(BarcodeGeneratorEngineConfiguration config, string message, BarcodeType type, QrConfiguration qrConfig = null)
+        {
+            if (string.IsNullOrEmpty(message) ||
+                type == BarcodeType.Undefined ||
+                (type == BarcodeType.QR &&
+                (qrConfig == null ||
+                qrConfig.ErrorCorrectionLevel == ErrorCorrectionLevel.Unavailable ||
+                qrConfig.Mode == QrMode.Unavailable ||
+                qrConfig.Version < 1 ||
+                qrConfig.Version > 40)))
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            MediaVisionSource source = new MediaVisionSource();
+            int ret = (type == BarcodeType.QR) ?
+                        Interop.MediaVision.BarCodeGenerator.GenerateSource(config._engineHandle, message, type, qrConfig.Mode, qrConfig.ErrorCorrectionLevel, qrConfig.Version, source._sourceHandle) :
+                        Interop.MediaVision.BarCodeGenerator.GenerateSource(config._engineHandle, message, type, QrMode.Unavailable, ErrorCorrectionLevel.Unavailable, 0, source._sourceHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to generate source");
+            return source;
+        }
+
+        /// <summary>
+        /// Generates image file with barcode.
+        /// </summary>
+        /// <remarks>
+        /// If the text attribute of engine configuration is set to <see cref="TextAttribute.Visible"/> ,
+        /// InvalidOperationException will be thrown when type is <see cref="BarcodeType.QR"/>\n
+        /// </remarks>
+        /// <param name="config">The configuration of the bar code generator engine</param>
+        /// <param name="message">The message to be encoded in the barcode</param>
+        /// <param name="type">Type of the barcode to be generated</param>
+        /// <param name="imageConfig">The BarcodeImageConfig object that contains information about the file to be generated</param>
+        /// <param name="qrConfig">The QrConfig object - required for QR codes only</param>
+        /// <code>
+        /// 
+        /// </code>
+        public static void GenerateImage(BarcodeGeneratorEngineConfiguration config, string message, BarcodeType type, BarcodeImageConfiguration imageConfig, QrConfiguration qrConfig = null)
+        {
+            if (string.IsNullOrEmpty(message) ||
+                imageConfig == null ||
+                string.IsNullOrEmpty(imageConfig.Path) ||
+                type == BarcodeType.Undefined ||
+                (type == BarcodeType.QR &&
+                (qrConfig == null ||
+                qrConfig.ErrorCorrectionLevel == ErrorCorrectionLevel.Unavailable ||
+                qrConfig.Mode == QrMode.Unavailable ||
+                qrConfig.Version < 1 ||
+                qrConfig.Version > 40)))
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            int ret = (type == BarcodeType.QR) ?
+                        Interop.MediaVision.BarCodeGenerator.GenerateImage(config._engineHandle,
+                                                                            message,
+                                                                            imageConfig.Width,
+                                                                            imageConfig.Height,
+                                                                            type,
+                                                                            qrConfig.Mode,
+                                                                            qrConfig.ErrorCorrectionLevel,
+                                                                            qrConfig.Version,
+                                                                            imageConfig.Path,
+                                                                            imageConfig.Format) :
+                        Interop.MediaVision.BarCodeGenerator.GenerateImage(config._engineHandle,
+                                                                            message,
+                                                                            imageConfig.Width,
+                                                                            imageConfig.Height,
+                                                                            type,
+                                                                            QrMode.Unavailable,
+                                                                            ErrorCorrectionLevel.Unavailable,
+                                                                            0,
+                                                                            imageConfig.Path,
+                                                                            imageConfig.Format);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to generate image");
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/BarcodeGeneratorEngineConfiguration.cs b/src/Tizen.Multimedia/MediaVision/BarcodeGeneratorEngineConfiguration.cs
new file mode 100755 (executable)
index 0000000..cb861bf
--- /dev/null
@@ -0,0 +1,117 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents concrete EngineConfig for BarcodeGenerator
+    /// </summary>
+    public class BarcodeGeneratorEngineConfiguration : EngineConfiguration
+    {
+        private const string _textAttributeKey = "MV_BARCODE_GENERATE_ATTR_TEXT";
+        private const string _frontColorAttributeKey = "MV_BARCODE_GENERATE_ATTR_COLOR_FRONT";
+        private const string _backColorAttributeKey = "MV_BARCODE_GENERATE_ATTR_COLOR_BACK";
+        private TextAttribute _textAttr = TextAttribute.Invisible;
+        private string _frontColor = "000000";
+        private string _backColor = "ffffff";
+
+        /// <summary>
+        /// The default constructor of BarcodeGeneratorEngineConfig class
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public BarcodeGeneratorEngineConfiguration()
+            : base()
+        {
+        }
+
+        /// <summary>
+        /// Sets and gets text attribute of the engine configuration
+        /// </summary>
+        public TextAttribute TextAttribute
+        {
+            get
+            {
+                return _textAttr;
+            }
+
+            set
+            {
+                if (!IsValid(value))
+                {
+                    throw new ArgumentException("TextAttribute value is invalid");
+                }
+
+                Add<int>(_textAttributeKey, (int)value);
+                _textAttr = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets barcode's foreground color attribute of the engine configuration.
+        /// </summary>
+        /// <remarks>
+        /// This attribute represents RGB color as a hex triplet with six digits.
+        /// </remarks>
+        public string FrontColor
+        {
+            get
+            {
+                return _frontColor;
+            }
+
+            set
+            {
+                Add<string>(_frontColorAttributeKey, value);
+                _frontColor = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets barcode's background color attribute of the engine configuration.
+        /// </summary>
+        /// <remarks>
+        /// This property represents RGB color as a hex triplet with six digits.
+        /// </remarks>
+        public string BackColor
+        {
+            get
+            {
+                return _backColor;
+            }
+
+            set
+            {
+                Add<string>(_backColorAttributeKey, value);
+                _backColor = value;
+            }
+        }
+
+        private bool IsValid(TextAttribute value)
+        {
+            if (value == TextAttribute.Unavailable)
+            {
+                Log.Error(MediaVisionLog.Tag, "Invalid TextAttribute");
+                return false;
+            }
+
+            return true;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/BarcodeImageConfiguration.cs b/src/Tizen.Multimedia/MediaVision/BarcodeImageConfiguration.cs
new file mode 100755 (executable)
index 0000000..2dc288c
--- /dev/null
@@ -0,0 +1,70 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents the configuration details for the barcode image file to be generated by BarcodeGenerator
+    /// </summary>
+    public class BarcodeImageConfiguration
+    {
+        /// <summary>
+        /// The constructor of the BarcodeImageConfig class
+        /// </summary>
+        /// <remarks>
+        /// The mediastorage privilege http://tizen.org/privilege/mediastorage is needed if image path is relevant to media storage.\n
+        /// The externalstorage privilege http://tizen.org/privilege/externalstorage is needed if image path is relevant to external storage.
+        /// </remarks>
+        /// <param name="width">The width of the generated image</param>
+        /// <param name="height">The height of the generated image</param>
+        /// <param name="path">The path to the file that has to be generated</param>
+        /// <param name="imageFormat">The format of the output image</param>
+        /// <code>
+        /// BarcodeImageConfiguration imageConfig = new BarcodeImageConfiguration(500, 400, "/opt/usr/test-barcode-generate-new", BarcodeImageFormat.JPG);
+        /// </code>
+        public BarcodeImageConfiguration(int width, int height, string path, BarcodeImageFormat imageFormat)
+        {
+            Width = width;
+            Height = height;
+            Path = path;
+            Format = imageFormat;
+        }
+
+        /// <summary>
+        /// Gets the width of the generated image
+        /// </summary>
+        public int Width { get; }
+
+        /// <summary>
+        /// Gets the height of the generated image
+        /// </summary>
+        public int Height { get; }
+
+        /// <summary>
+        /// Gets the path to the file that has to be generated
+        /// </summary>
+        /// <remarks>
+        /// The mediastorage privilege http://tizen.org/privilege/mediastorage is needed if image path is relevant to media storage.\n
+        /// The externalstorage privilege http://tizen.org/privilege/externalstorage is needed if image path is relevant to external storage.
+        /// </remarks>
+        public string Path { get; }
+
+        /// <summary>
+        /// Gets the format of the output image
+        /// </summary>
+        public BarcodeImageFormat Format { get; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/BarcodeImageFormat.cs b/src/Tizen.Multimedia/MediaVision/BarcodeImageFormat.cs
new file mode 100755 (executable)
index 0000000..25c0ced
--- /dev/null
@@ -0,0 +1,45 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration for supported image formats for the barcode generation.
+    /// </summary>
+    public enum BarcodeImageFormat
+    {
+        /// <summary>
+        /// Unavailable image format
+        /// </summary>
+        Unavailable = -1,
+        /// <summary>
+        /// BMP image format
+        /// </summary>
+        BMP,
+        /// <summary>
+        /// JPEG image format
+        /// </summary>
+        JPG,
+        /// <summary>
+        /// PNG image format
+        /// </summary>
+        PNG,
+        /// <summary>
+        /// The number of supported image format
+        /// </summary>
+        NUM
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/BarcodeType.cs b/src/Tizen.Multimedia/MediaVision/BarcodeType.cs
new file mode 100755 (executable)
index 0000000..2b04dd6
--- /dev/null
@@ -0,0 +1,64 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration for supported barcode types.
+    /// </summary>
+    /// <remarks>
+    /// QR codes (versions 1 to 40) and set of 1D barcodes are supported
+    /// </remarks>
+    public enum BarcodeType
+    {
+        /// <summary>
+        /// 2D barcode - Quick Response code
+        /// </summary>
+        QR,
+        /// <summary>
+        /// 1D barcode - Universal Product Code with 12-digit
+        /// </summary>
+        UPC_A,
+        /// <summary>
+        /// 1D barcode - Universal Product Code with 6-digit
+        /// </summary>
+        UPC_E,
+        /// <summary>
+        /// 1D barcode - International Article Number with 8-digit
+        /// </summary>
+        EAN_8,
+        /// <summary>
+        /// 1D barcode - International Article Number with 13-digit
+        /// </summary>
+        EAN_13,
+        /// <summary>
+        /// 1D barcode - Code 128
+        /// </summary>
+        CODE128,
+        /// <summary>
+        /// 1D barcode - Code 39
+        /// </summary>
+        CODE39,
+        /// <summary>
+        /// 1D barcode - Interleaved Two of Five
+        /// </summary>
+        I2_5,
+        /// <summary>
+        /// Undefined
+        /// </summary>
+        Undefined
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/Colorspace.cs b/src/Tizen.Multimedia/MediaVision/Colorspace.cs
new file mode 100755 (executable)
index 0000000..7e90566
--- /dev/null
@@ -0,0 +1,73 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration for Media Vision colorspace
+    /// </summary>
+    public enum Colorspace
+    {
+        /// <summary>
+        /// The colorspace type is invalid
+        /// </summary>
+        Invalid,
+        /// <summary>
+        /// The colorspace type is Y800
+        /// </summary>
+        Y800,
+        /// <summary>
+        /// The colorspace type is I420
+        /// </summary>
+        I420,
+        /// <summary>
+        /// The colorspace type is NV12
+        /// </summary>
+        NV12,
+        /// <summary>
+        /// The colorspace type is YV12
+        /// </summary>
+        YV12,
+        /// <summary>
+        /// The colorspace type is NV21
+        /// </summary>
+        NV21,
+        /// <summary>
+        /// The colorspace type is YUYV
+        /// </summary>
+        YUYV,
+        /// <summary>
+        /// The colorspace type is UYVY
+        /// </summary>
+        UYVY,
+        /// <summary>
+        /// The colorspace type is 422P
+        /// </summary>
+        P422,
+        /// <summary>
+        /// The colorspace type is RGB565
+        /// </summary>
+        RGB565,
+        /// <summary>
+        /// The colorspace type is RGB888
+        /// </summary>
+        RGB888,
+        /// <summary>
+        /// The colorspace type is RGBA
+        /// </summary>
+        RGBA
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/EngineConfiguration.cs b/src/Tizen.Multimedia/MediaVision/EngineConfiguration.cs
new file mode 100755 (executable)
index 0000000..f4a44bb
--- /dev/null
@@ -0,0 +1,119 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents an abstract EngineConfiguration class.\n
+    /// It provides dictionary functionality. It means that it is possible to set (key, value) pairs to this class \n
+    /// and use them to transfer these values to the engine part underlying Media Vision API. \n
+    /// Information on which attributes can be set is provided together with concrete engines.
+    /// </summary>
+    public abstract class EngineConfiguration : IDisposable
+    {
+        internal IntPtr _engineHandle = IntPtr.Zero;
+        private readonly IDictionary<string, object> _config = new Dictionary<string, object>();
+        private bool _disposed = false;
+
+        /// <summary>
+        /// Constructor of the EngineConfig class.
+        /// </summary>
+        internal EngineConfiguration()
+        {
+            int ret = Interop.MediaVision.EngineConfig.Create(out _engineHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to create media vision engine.");
+        }
+
+        /// <summary>
+        /// Destructor of the EngineConfig class.
+        /// </summary>
+        ~EngineConfiguration()
+        {
+            Dispose(false);
+        }
+
+        internal void Add<T>(string key, T value)
+        {
+            int ret = 0;
+            object val = (object)value;
+            if (typeof(T) == typeof(double))
+            {
+                ret = Interop.MediaVision.EngineConfig.SetDouble(_engineHandle, key, (double)val);
+            }
+            else if (typeof(T) == typeof(int))
+            {
+                ret = Interop.MediaVision.EngineConfig.SetInt(_engineHandle, key, (int)val);
+            }
+            else if (typeof(T) == typeof(bool))
+            {
+                ret = Interop.MediaVision.EngineConfig.SetBool(_engineHandle, key, (bool)val);
+            }
+            else if (typeof(T) == typeof(string))
+            {
+                ret = Interop.MediaVision.EngineConfig.SetString(_engineHandle, key, (string)val);
+            }
+
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to add attribute");
+            _config.Add(key, val);
+        }
+
+        internal object Get(string key)
+        {
+            if (_config.ContainsKey(key))
+            {
+                return _config[key];
+            }
+            else
+            {
+                Log.Error(MediaVisionLog.Tag, "Attribute was not set");
+                return null;
+            }
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object.
+        /// </summary>
+        public void Dispose()
+        {
+            Dispose(true);
+            GC.SuppressFinalize(this);
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
+        /// </summary>
+        /// <param name="disposing">If true, disposes any disposable objects. If false, does not dispose disposable objects.</param>
+        protected virtual void Dispose(bool disposing)
+        {
+            if (_disposed)
+            {
+                return;
+            }
+
+            if (disposing)
+            {
+                // Free managed objects
+            }
+
+            Interop.MediaVision.EngineConfig.Destroy(_engineHandle);
+            _disposed = true;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/ErrorCorrectionLevel.cs b/src/Tizen.Multimedia/MediaVision/ErrorCorrectionLevel.cs
new file mode 100755 (executable)
index 0000000..bd717cc
--- /dev/null
@@ -0,0 +1,48 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration for supported QR code error correction level.
+    /// </summary>
+    /// <remarks>
+    /// This is unavailable for 1D barcodes
+    /// </remarks>
+    public enum ErrorCorrectionLevel
+    {
+        /// <summary>
+        /// Recovery up to 7% losses
+        /// </summary>
+        Low,
+        /// <summary>
+        /// Recovery up to 15% losses
+        /// </summary>
+        Medium,
+        /// <summary>
+        /// Recovery up to 25% losses
+        /// </summary>
+        Quartile,
+        /// <summary>
+        /// Recovery up to 30% losses
+        /// </summary>
+        High,
+        /// <summary>
+        /// Unavailable
+        /// </summary>
+        Unavailable
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/EyeCondition.cs b/src/Tizen.Multimedia/MediaVision/EyeCondition.cs
new file mode 100755 (executable)
index 0000000..b2fd3de
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration for eyes state type.
+    /// </summary>
+    public enum EyeCondition
+    {
+        /// <summary>
+        /// Eyes are open
+        /// </summary>
+        Open,
+        /// <summary>
+        /// Eyes are closed
+        /// </summary>
+        Closed,
+        /// <summary>
+        /// The eyes condition wasn't determined
+        /// </summary>
+        NotFound
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceDetectionResult.cs b/src/Tizen.Multimedia/MediaVision/FaceDetectionResult.cs
new file mode 100755 (executable)
index 0000000..9443982
--- /dev/null
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System.Collections.Generic;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents result of face detection operation.
+    /// </summary>
+    public class FaceDetectionResult
+    {
+        internal FaceDetectionResult()
+        {
+        }
+
+        /// <summary>
+        /// Gets the rectangular locations of the detected faces.
+        /// </summary>
+        public List<Rectangle> Locations { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceDetector.cs b/src/Tizen.Multimedia/MediaVision/FaceDetector.cs
new file mode 100755 (executable)
index 0000000..f9c9f6f
--- /dev/null
@@ -0,0 +1,91 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+using System.Runtime.InteropServices;
+using System.Threading.Tasks;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents the interface for media vision face detection.
+    /// </summary>
+    public static class FaceDetector
+    {
+        /// <summary>
+        /// Performs face detection on the source for the engine_conf.\n
+        /// Use this function to launch face detection algorithm configured by @a config configuration.
+        /// Each time when DetectAsync is called, a set of the detected faces at the media source are received asynchronously.
+        /// </summary>
+        /// <param name="source">The source of the media where faces will be detected</param>
+        /// <param name="config">The configuration of engine will be used for detecting. If NULL, then default settings will be used.</param>
+        /// <returns>Returns the FaceDetectionResult asynchronously</returns>
+        /// <code>
+        /// 
+        /// </code>
+        public static async Task<FaceDetectionResult> DetectAsync(MediaVisionSource source, FaceEngineConfiguration config = null)
+        {
+            if (source == null)
+            {
+                throw new ArgumentException("Invalid source");
+            }
+            TaskCompletionSource<FaceDetectionResult> tcsResult = new TaskCompletionSource<FaceDetectionResult>();
+            // Define native callback
+            Interop.MediaVision.Face.MvFaceDetectedCallback faceDetectedCb = (IntPtr sourceHandle, IntPtr engineCfgHandle, IntPtr facesLocations, int numberOfFaces, IntPtr userData) =>
+            {
+                try
+                {
+                    Log.Info(MediaVisionLog.Tag, String.Format("Faces detected, count : {0}", numberOfFaces));
+                    List<Rectangle> locations = new List<Rectangle>();
+                    if (numberOfFaces > 0)
+                    {
+                        // Prepare list of locations
+                        for (int i = 0; i < numberOfFaces; i++)
+                        {
+                            Interop.MediaVision.Rectangle location = (Interop.MediaVision.Rectangle)Marshal.PtrToStructure(facesLocations, typeof(Interop.MediaVision.Rectangle));
+                            Rectangle rect = new Rectangle(new Point(location.x, location.y), location.width, location.height);
+                            Log.Info(MediaVisionLog.Tag, String.Format("Face {0} detected at : ({1}, {2})", i + 1, rect.Point.X, rect.Point.Y));
+                            locations.Add(rect);
+                            facesLocations = IntPtr.Add(facesLocations, sizeof(int) * 4);
+                        }
+                    }
+
+                    FaceDetectionResult result = new FaceDetectionResult()
+                    {
+                        Locations = locations
+                    };
+
+                    if (!tcsResult.TrySetResult(result))
+                    {
+                        Log.Info(MediaVisionLog.Tag, "Failed to set result");
+                        tcsResult.TrySetException(new InvalidOperationException("Failed to set result"));
+                    }
+                }
+                catch (Exception ex)
+                {
+                    Log.Info(MediaVisionLog.Tag, "exception :" + ex.ToString());
+                    tcsResult.TrySetException(ex);
+                }
+            };
+
+            int ret = Interop.MediaVision.Face.Detect(source._sourceHandle, (config != null) ? config._engineHandle : IntPtr.Zero, faceDetectedCb, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to perform face detection.");
+            return await tcsResult.Task;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceEngineConfiguration.cs b/src/Tizen.Multimedia/MediaVision/FaceEngineConfiguration.cs
new file mode 100755 (executable)
index 0000000..e95438f
--- /dev/null
@@ -0,0 +1,215 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents concrete EngineConfig for Face detection and recognition
+    /// </summary>
+    public class FaceEngineConfiguration : EngineConfiguration
+    {
+        // List of predefined keys
+        private const string _faceDetectionModelFilePathKey = "MV_FACE_DETECTION_MODEL_FILE_PATH";
+        private const string _faceRecognitionModelTypeKey = "MV_FACE_RECOGNITION_MODEL_TYPE";
+        private const string _faceDetectionRoiXKey = "MV_FACE_DETECTION_ROI_X";
+        private const string _faceDetectionRoiYKey = "MV_FACE_DETECTION_ROI_Y";
+        private const string _faceDetectionRoiWidthKey = "MV_FACE_DETECTION_ROI_WIDTH";
+        private const string _faceDetectionRoiHeightKey = "MV_FACE_DETECTION_ROI_HEIGHT";
+        private const string _faceDetectionMinWidthKey = "MV_FACE_DETECTION_MIN_SIZE_WIDTH";
+        private const string _faceDetectionMinHeightKey = "MV_FACE_DETECTION_MIN_SIZE_HEIGHT";
+        // Values are cached below to prevent interop calls for get operation
+        private string _faceDetectionModelFilePathValue;
+        private FaceRecognitionModelType _faceRecognitionModelTypeValue = FaceRecognitionModelType.LBPH;
+        private int _faceDetectionRoiXValue = -1;
+        private int _faceDetectionRoiYValue = -1;
+        private int _faceDetectionRoiWidthValue = -1;
+        private int _faceDetectionRoiHeightValue = -1;
+        private int _faceDetectionMinWidthValue = -1;
+        private int _faceDetectionMinHeightValue = -1;
+
+        /// <summary>
+        /// The default constructor of FaceEngineConfig class
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public FaceEngineConfiguration()
+            : base()
+        {
+        }
+
+        /// <summary>
+        /// Sets and gets face detection haarcascade xml file attribute of the engine configuration.
+        /// </summary>
+        public string ModelFilePath
+        {
+            get
+            {
+                return _faceDetectionModelFilePathValue;
+            }
+
+            set
+            {
+                Add<string>(_faceDetectionModelFilePathKey, value);
+                _faceDetectionModelFilePathValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the method used for face recognition model learning attribute of the engine configuration.
+        /// </summary>
+        public FaceRecognitionModelType ModelType
+        {
+            get
+            {
+                return _faceRecognitionModelTypeValue;
+            }
+
+            set
+            {
+                if (value == FaceRecognitionModelType.Unknown)
+                {
+                    throw new ArgumentException("ModelType value is invalid");
+                }
+
+                Add<int>(_faceRecognitionModelTypeKey, (int)value);
+                _faceRecognitionModelTypeValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets minimum height of face which will be detected as attribute of the engine configuration.
+        /// </summary>
+        /// <remarks>
+        /// Default value is -1 (all detected faces will be applied) can be changed to specify the minimum face height.
+        /// </remarks>
+        public int MinimumHeight
+        {
+            get
+            {
+                return _faceDetectionMinHeightValue;
+            }
+
+            set
+            {
+                Add<int>(_faceDetectionMinHeightKey, value);
+                _faceDetectionMinHeightValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets minimum width of face which will be detected as attribute of the engine configuration.
+        /// </summary>
+        /// <remarks>
+        /// Default value is -1 (all detected faces will be applied) can be changed to specify the minimum face width.
+        /// </remarks>
+        public int MinimumWidth
+        {
+            get
+            {
+                return _faceDetectionMinWidthValue;
+            }
+
+            set
+            {
+                Add<int>(_faceDetectionMinWidthKey, value);
+                _faceDetectionMinWidthValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets height of face detection roi as attribute of the engine configuration.
+        /// </summary>
+        /// <remarks>
+        /// Default value is -1 (the roi will be a full image) can be changed to specify the roi for face detection.
+        /// </remarks>
+        public int RoiHeight
+        {
+            get
+            {
+                return _faceDetectionRoiHeightValue;
+            }
+
+            set
+            {
+                Add<int>(_faceDetectionRoiHeightKey, value);
+                _faceDetectionRoiHeightValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets width of face detection roi as attribute of the engine configuration.
+        /// </summary>
+        /// <remarks>
+        /// Default value is -1 (the roi will be a full image) can be changed to specify the roi for face detection
+        /// </remarks>
+        public int RoiWidth
+        {
+            get
+            {
+                return _faceDetectionRoiWidthValue;
+            }
+
+            set
+            {
+                Add<int>(_faceDetectionRoiWidthKey, value);
+                _faceDetectionRoiWidthValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets X coordinate of face detection roi as attribute of the engine configuration.
+        /// </summary>
+        /// <remarks>
+        /// Default value is -1 (the roi will be a full image) can be changed to specify the roi for face detection
+        /// </remarks>
+        public int RoiX
+        {
+            get
+            {
+                return _faceDetectionRoiXValue;
+            }
+
+            set
+            {
+                Add<int>(_faceDetectionRoiXKey, value);
+                _faceDetectionRoiXValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets Y coordinate of face detection roi as attribute of the engine configuration.
+        /// </summary>
+        /// <remarks>
+        /// Default value is -1 (the roi will be a full image) can be changed to specify the roi for face detection
+        /// </remarks>
+        public int RoiY
+        {
+            get
+            {
+                return _faceDetectionRoiYValue;
+            }
+
+            set
+            {
+                Add<int>(_faceDetectionRoiYKey, value);
+                _faceDetectionRoiYValue = value;
+            }
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceRecognitionModel.cs b/src/Tizen.Multimedia/MediaVision/FaceRecognitionModel.cs
new file mode 100755 (executable)
index 0000000..3b487cd
--- /dev/null
@@ -0,0 +1,220 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents face recognition model interface
+    /// </summary>
+    public class FaceRecognitionModel : IDisposable
+    {
+        internal IntPtr _recognitionModelHandle = IntPtr.Zero;
+        private bool _disposed = false;
+
+        /// <summary>
+        /// Construct of FaceRecognitionModel class
+        /// </summary>
+        public FaceRecognitionModel()
+        {
+            int ret = Interop.MediaVision.FaceRecognitionModel.Create(out _recognitionModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to create FaceRecognitionModel.");
+        }
+
+        /// <summary>
+        /// Construct of FaceRecognitionModel class which creates and loads recognition model from file.
+        /// </summary>
+        /// <remarks>
+        /// FaceRecognitionModel is loaded from the absolute path directory.\n
+        /// Models has been saved by <see cref="Save()"/> function can be loaded with this function
+        /// </remarks>
+        /// <param name="fileName">Name of path/file to load the model</param>
+        /// <seealso cref="Save()"/>
+        /// <code>
+        /// 
+        /// </code>
+        public FaceRecognitionModel(string fileName)
+        {
+            int ret = Interop.MediaVision.FaceRecognitionModel.Load(fileName, out _recognitionModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to load FaceRecognitionModel from file.");
+        }
+
+        /// <summary>
+        /// Destructor of the FaceRecognitionModel class.
+        /// </summary>
+        ~FaceRecognitionModel()
+        {
+            Dispose(false);
+        }
+
+        /// <summary>
+        /// Gets labels list
+        /// </summary>
+        public int[] FaceLabels
+        {
+            get
+            {
+                IntPtr labelsArrayPtr;
+                uint numOfLabels = 0;
+                int ret = Interop.MediaVision.FaceRecognitionModel.QueryLabels(_recognitionModelHandle, out labelsArrayPtr, out numOfLabels);
+                if (ret != 0)
+                {
+                    Tizen.Log.Error(MediaVisionLog.Tag, "Failed to get face labels");
+                    return null;
+                }
+
+                int[] labels = new int[numOfLabels];
+                for (int i = 0; i < numOfLabels; i++)
+                {
+                    labels[i] = Marshal.ReadInt32(labelsArrayPtr);
+                    labelsArrayPtr = IntPtr.Add(labelsArrayPtr, sizeof(int));
+                }
+
+                return labels;
+            }
+        }
+
+        /// <summary>
+        /// Calls this method to save recognition model to the file.
+        /// </summary>
+        /// <remarks>
+        /// RecognitionModel is saved to the absolute path directory.
+        /// </remarks>
+        /// <param name="fileName">Name of the path/file to save the model</param>
+        /// <code>
+        /// 
+        /// </code>
+        public void Save(string fileName)
+        {
+            if (string.IsNullOrEmpty(fileName))
+            {
+                throw new ArgumentException("Invalid file name");
+            }
+
+            int ret = Interop.MediaVision.FaceRecognitionModel.Save(fileName, _recognitionModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to save recognition model to file");
+        }
+
+        /// <summary>
+        /// Adds face image example to be used for face recognition model learning with <see cref="Learn()"/>.
+        /// </summary>
+        /// <param name="source">Source that contains face image</param>
+        /// <param name="location">The rectangular location of the face image at the source image.</param>
+        /// <param name="faceLabel">The label that identifies face for which example is adding. Specify the same labels for the face images of a single person when calling this method. Has to be unique for each face</param>
+        /// <code>
+        /// 
+        /// </code>
+        public void Add(MediaVisionSource source, int faceLabel, Rectangle location = null)
+        {
+            if (source == null)
+            {
+                throw new ArgumentException("Invalid source");
+            }
+
+            IntPtr ptr = IntPtr.Zero;
+            if (location != null)
+            {
+                Interop.MediaVision.Rectangle rectangle = new Interop.MediaVision.Rectangle()
+                {
+                    width = location.Width,
+                    height = location.Height,
+                    x = location.Point.X,
+                    y = location.Point.Y
+                };
+                ptr = Marshal.AllocHGlobal(Marshal.SizeOf(rectangle));
+                Marshal.StructureToPtr(rectangle, ptr, false);
+            }
+
+            int ret = Interop.MediaVision.FaceRecognitionModel.Add(source._sourceHandle, _recognitionModelHandle, ptr, faceLabel);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to add face example image");
+        }
+
+        /// <summary>
+        /// Removes from RecognitionModel all collected with <see cref="Add()"/> function face examples labeled with faceLabel.
+        /// </summary>
+        /// <param name="faceLabel">The label that identifies face for which examples will be removed from the RecognitionModel.</param>
+        /// <code>
+        /// 
+        /// </code>
+        public void Remove(int faceLabel)
+        {
+            int ret = Interop.MediaVision.FaceRecognitionModel.Remove(_recognitionModelHandle, ref faceLabel);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to remove image example");
+        }
+
+        /// <summary>
+        /// Removes all image examples known by RecognitionModel.
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public void Reset()
+        {
+            int ret = Interop.MediaVision.FaceRecognitionModel.Reset(_recognitionModelHandle, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to remove image example");
+        }
+
+        /// <summary>
+        /// Learns face recognition model.
+        /// </summary>
+        /// <remarks>
+        /// Before you start learning process, face recognition models has to be filled with training data - face image examples.
+        /// These examples has to be provided by <see cref="Add()"/> function. Usually, recognition accuracy is increased
+        /// when number of not identical examples is large. But it depends on the used learning algorithm.
+        /// </remarks>
+        /// <param name="config">The configuration of engine will be used for learning of the recognition models. If NULL, then default settings will be used</param>
+        /// <code>
+        /// 
+        /// </code>
+        public void Learn(FaceEngineConfiguration config = null)
+        {
+            int ret = Interop.MediaVision.FaceRecognitionModel.Learn((config != null) ? config._engineHandle : IntPtr.Zero, _recognitionModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to learn");
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object.
+        /// </summary>
+        public void Dispose()
+        {
+            Dispose(true);
+            GC.SuppressFinalize(this);
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
+        /// </summary>
+        /// <param name="disposing">If true, disposes any disposable objects. If false, does not dispose disposable objects.</param>
+        protected virtual void Dispose(bool disposing)
+        {
+            if (_disposed)
+            {
+                return;
+            }
+
+            if (disposing)
+            {
+                // Free managed objects
+            }
+
+            Interop.MediaVision.FaceRecognitionModel.Destroy(_recognitionModelHandle);
+            _disposed = true;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceRecognitionModelType.cs b/src/Tizen.Multimedia/MediaVision/FaceRecognitionModelType.cs
new file mode 100755 (executable)
index 0000000..c5865ef
--- /dev/null
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration for face recognition model learning attribute of the engine configuration.
+    /// </summary>
+    public enum FaceRecognitionModelType
+    {
+        /// <summary>
+        /// Unknown method
+        /// </summary>
+        Unknown = 0,
+        /// <summary>
+        /// Eigenfaces
+        /// </summary>
+        EigenFaces,
+        /// <summary>
+        /// Fisherfaces
+        /// </summary>
+        FisherFaces,
+        /// <summary>
+        /// Local Binary Patterns Histograms (LBPH) - This is the default type
+        /// </summary>
+        LBPH
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceRecognitionResult.cs b/src/Tizen.Multimedia/MediaVision/FaceRecognitionResult.cs
new file mode 100755 (executable)
index 0000000..f702d6f
--- /dev/null
@@ -0,0 +1,46 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents result of face recognition operation.
+    /// </summary>
+    public class FaceRecognitionResult
+    {
+        internal FaceRecognitionResult()
+        {
+        }
+
+        /// <summary>
+        /// Gets the label of the recognized face.
+        /// </summary>
+        public int Label { get; internal set; }
+
+        /// <summary>
+        /// Gets the location of the recognized face.
+        /// </summary>
+        public Rectangle Location { get; internal set; }
+
+        /// <summary>
+        /// The confidence of the recognition_model that face has been recognized correctly (value from 0.0 to 1.0).
+        /// No faces were recognized if confidence was 0.0. When model has been learned on large amount of examples,
+        /// threshold for this value can be high (0.85-0.95). If model was learned for small amount of examples,
+        /// then threshold can be reduced (0.5-0.85).
+        /// </summary>
+        public double Confidence { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceRecognizer.cs b/src/Tizen.Multimedia/MediaVision/FaceRecognizer.cs
new file mode 100755 (executable)
index 0000000..ed3bdcc
--- /dev/null
@@ -0,0 +1,200 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using System.Threading.Tasks;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents an interface for Face recognition functionalities.
+    /// It also contains APIs which perform facial expression recognition and eye condition recognition.
+    /// </summary>
+    public static class FaceRecognizer
+    {
+        /// <summary>
+        /// Performs face recognition on the source image synchronously.
+        /// </summary>
+        /// <param name="source">The source of the media to recognize face(s) for</param>
+        /// <param name="recognitionModel">The model to be used for recognition</param>
+        /// <param name="config">The configuration of engine will be used for recognition. If NULL, then default settings will be used</param>
+        /// <param name="location">Rectangular box bounding face image on the source. If NULL, then full source will be analyzed</param>
+        /// <returns>Returns the FaceRecognitionResult asynchronously</returns>
+        /// <code>
+        /// 
+        /// </code>
+        public static async Task<FaceRecognitionResult> RecognizeAsync(MediaVisionSource source, FaceRecognitionModel recognitionModel, FaceEngineConfiguration config = null, Rectangle location = null)
+        {
+            if (source == null || recognitionModel == null)
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            IntPtr locationPtr = IntPtr.Zero;
+            if (location != null)
+            {
+                Interop.MediaVision.Rectangle rectangle = new Interop.MediaVision.Rectangle()
+                {
+                    width = location.Width,
+                    height = location.Height,
+                    x = location.Point.X,
+                    y = location.Point.Y
+                };
+                locationPtr = Marshal.AllocHGlobal(Marshal.SizeOf(rectangle));
+                Marshal.StructureToPtr(rectangle, locationPtr, false);
+            }
+
+            TaskCompletionSource<FaceRecognitionResult> tcsResult = new TaskCompletionSource<FaceRecognitionResult>();
+
+            // Define native callback
+            Interop.MediaVision.Face.MvFaceRecognizedCallback faceRecognizedCb = (IntPtr sourceHandle, IntPtr recognitionModelHandle, IntPtr engineCfgHandle, IntPtr faceLocationPtr, IntPtr faceLabelPtr, double confidence, IntPtr userData) =>
+            {
+                try
+                {
+                    Rectangle faceLocation = null;
+                    if (faceLocationPtr != IntPtr.Zero)
+                    {
+                        Interop.MediaVision.Rectangle loc = (Interop.MediaVision.Rectangle)Marshal.PtrToStructure(faceLocationPtr, typeof(Interop.MediaVision.Rectangle));
+                        faceLocation = new Rectangle()
+                        {
+                            Width = loc.width,
+                            Height = loc.height,
+                            Point = new Point(loc.x, loc.y)
+                        };
+                    }
+
+                    int faceLabel = 0;
+                    if (faceLabelPtr != IntPtr.Zero)
+                    {
+                        faceLabel = Marshal.ReadInt32(faceLabelPtr);
+                    }
+
+                    Log.Info(MediaVisionLog.Tag, String.Format("Face label {0} recognized at : ({1}, {2}), Width : {3}, Height : {4}, confidence : {5}", faceLabel, faceLocation.Point.X, faceLocation.Point.Y, faceLocation.Width, faceLocation.Height, confidence));
+                    FaceRecognitionResult result = new FaceRecognitionResult()
+                    {
+                        Location = faceLocation,
+                        Label = faceLabel,
+                        Confidence = confidence
+                    };
+
+                    if (!tcsResult.TrySetResult(result))
+                    {
+                        Log.Info(MediaVisionLog.Tag, "Failed to set result");
+                        tcsResult.TrySetException(new InvalidOperationException("Failed to set result"));
+                    }
+                }
+                catch (Exception ex)
+                {
+                    Log.Info(MediaVisionLog.Tag, "exception :" + ex.ToString());
+                    tcsResult.TrySetException(ex);
+                }
+            };
+
+
+            int ret = Interop.MediaVision.Face.Recognize(source._sourceHandle, recognitionModel._recognitionModelHandle,
+                            (config != null) ? config._engineHandle : IntPtr.Zero, locationPtr, faceRecognizedCb, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to perform face recognition.");
+
+            return await tcsResult.Task;
+        }
+
+        /// <summary>
+        /// Determines eye-blink condition for @a location on media source.
+        /// </summary>
+        /// <param name="source">The source of the media to recognize eye-blink condition for</param>
+        /// <param name="location">The location bounding the face at the source</param>
+        /// <param name="config">The configuration of engine will be used for eye-blink condition recognition. If NULL, the default configuration will be used</param>
+        /// <returns>Returns the EyeCondition asynchronously</returns>
+        public static async Task<EyeCondition> RecognizeEyeConditionAsync(MediaVisionSource source, Rectangle location, FaceEngineConfiguration config = null)
+        {
+            if (source == null || location == null)
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            Interop.MediaVision.Rectangle rectangle = new Interop.MediaVision.Rectangle()
+            {
+                width = location.Width,
+                height = location.Height,
+                x = location.Point.X,
+                y = location.Point.Y
+            };
+
+            TaskCompletionSource<EyeCondition> tcsResult = new TaskCompletionSource<EyeCondition>();
+
+            // Define native callback
+            Interop.MediaVision.Face.MvFaceEyeConditionRecognizedCallback eyeConditionRecognizedCb = (IntPtr sourceHandle, IntPtr engineCfgHandle, Interop.MediaVision.Rectangle faceLocation, EyeCondition eyeCondition, IntPtr userData) =>
+            {
+                Log.Info(MediaVisionLog.Tag, String.Format("Eye condition recognized, eye condition : {0}", eyeCondition));
+                if (!tcsResult.TrySetResult(eyeCondition))
+                {
+                    Log.Info(MediaVisionLog.Tag, "Failed to set result");
+                    tcsResult.TrySetException(new InvalidOperationException("Failed to set result"));
+                }
+            };
+
+            int ret = Interop.MediaVision.Face.RecognizeEyeCondition(source._sourceHandle, (config != null) ? config._engineHandle : IntPtr.Zero,
+                             rectangle, eyeConditionRecognizedCb, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to perform eye condition recognition.");
+
+            return await tcsResult.Task;
+        }
+
+        /// <summary>
+        /// Determines facial expression for @a location on media source.
+        /// </summary>
+        /// <param name="source">The source of the media to recognize facial expression for</param>
+        /// <param name="location">The location bounding the face at the source</param>
+        /// <param name="config">The configuration of engine to be used for expression recognition</param>
+        /// <returns>Returns the FacialExpression asynchronously</returns>
+        public static async Task<FacialExpression> RecognizeFacialExpressionAsync(MediaVisionSource source, Rectangle location, FaceEngineConfiguration config = null)
+        {
+            if (source == null || location == null)
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            Interop.MediaVision.Rectangle rectangle = new Interop.MediaVision.Rectangle()
+            {
+                width = location.Width,
+                height = location.Height,
+                x = location.Point.X,
+                y = location.Point.Y
+            };
+
+            TaskCompletionSource<FacialExpression> tcsResult = new TaskCompletionSource<FacialExpression>();
+
+            // Define native callback
+            Interop.MediaVision.Face.MvFaceFacialExpressionRecognizedCallback facialExpressionRecognizedCb = (IntPtr sourceHandle, IntPtr engineCfgHandle, Interop.MediaVision.Rectangle faceLocation, FacialExpression facialExpression, IntPtr userData) =>
+            {
+                Log.Info(MediaVisionLog.Tag, String.Format("Facial expression recognized, expression : {0}", facialExpression));
+                if (!tcsResult.TrySetResult(facialExpression))
+                {
+                    Log.Info(MediaVisionLog.Tag, "Failed to set result");
+                    tcsResult.TrySetException(new InvalidOperationException("Failed to set result"));
+                }
+            };
+
+            int ret = Interop.MediaVision.Face.RecognizeFacialExpression(source._sourceHandle, (config != null) ? config._engineHandle : IntPtr.Zero,
+                             rectangle, facialExpressionRecognizedCb, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to perform facial expression recognition.");
+
+            return await tcsResult.Task;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceTracker.cs b/src/Tizen.Multimedia/MediaVision/FaceTracker.cs
new file mode 100755 (executable)
index 0000000..0a3bdf5
--- /dev/null
@@ -0,0 +1,101 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using System.Threading.Tasks;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class contains the Media Vision face tracking API which performs tracking
+    /// on <see cref="MediaVisionSource"/> for <see cref="FaceTrackingModel"/>
+    /// </summary>
+    public static class FaceTracker
+    {
+        /// <summary>
+        /// Performs face tracking on the @a source for the @a trackingModel.\n
+        /// Use this function to launch face tracking algorithm configured by @a config configuration using
+        /// @a trackingModel tracking model. Each time when this function is called, new location determined for the tracked face
+        /// and model confidence that location is determined correctly are returned.
+        /// </summary>
+        /// <param name="source">The source of the media to recognize face for</param>
+        /// <param name="trackingModel">The model will be used for tracking</param>
+        /// <param name="doLearn">The model learning flag. If it is set true then model will try to learn (if it supports learning feature), otherwise model will be not learned during the invoking tracking iteration. Learning process improves tracking correctness, but can decrease tracking performance</param>
+        /// <param name="config">The configuration of engine will be used for tracking. If NULL, the default configuration will be used.</param>
+        /// <returns>Returns the FaceTrackingResult with new location and confidence asynchronously</returns>
+        /// <code>
+        /// 
+        /// </code>
+        public static async Task<FaceTrackingResult> TrackAsync(MediaVisionSource source, FaceTrackingModel trackingModel, bool doLearn, FaceEngineConfiguration config = null)
+        {
+            if (source == null || trackingModel == null)
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            TaskCompletionSource<FaceTrackingResult> tcsResult = new TaskCompletionSource<FaceTrackingResult>();
+
+            // Define native callback
+            Interop.MediaVision.Face.MvFaceTrackedCallback faceTrackedCb = (IntPtr sourceHandle, IntPtr trackingModelHandle, IntPtr engineCfgHandle, IntPtr locationPtr, double confidence, IntPtr userData) =>
+            {
+                try
+                {
+                    Quadrangle faceLocation = null;
+                    if (locationPtr != IntPtr.Zero)
+                    {
+                        Interop.MediaVision.Quadrangle location = (Interop.MediaVision.Quadrangle)Marshal.PtrToStructure(locationPtr, typeof(Interop.MediaVision.Quadrangle));
+                        faceLocation = new Quadrangle()
+                        {
+                            Points = new Point[4]
+                            {
+                            new Point(location.x1, location.y1),
+                            new Point(location.x2, location.y2),
+                            new Point(location.x3, location.y3),
+                            new Point(location.x4, location.y4)
+                            }
+                        };
+
+                        Log.Info(MediaVisionLog.Tag, String.Format("Tracked location : {0}, confidence : {1}", faceLocation.ToString(), confidence));
+                    }
+
+                    FaceTrackingResult result = new FaceTrackingResult()
+                    {
+                        Location = faceLocation,
+                        Confidence = confidence
+                    };
+
+                    if (!tcsResult.TrySetResult(result))
+                    {
+                        Log.Info(MediaVisionLog.Tag, "Failed to set result");
+                        tcsResult.TrySetException(new InvalidOperationException("Failed to set result"));
+                    }
+                }
+                catch (Exception ex)
+                {
+                    Log.Info(MediaVisionLog.Tag, "exception :" + ex.ToString());
+                    tcsResult.TrySetException(ex);
+                }
+            };
+
+            int ret = Interop.MediaVision.Face.Track(source._sourceHandle, trackingModel._trackingModelHandle, (config != null) ? config._engineHandle : IntPtr.Zero, faceTrackedCb, doLearn, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to perform face tracking.");
+
+            return await tcsResult.Task;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceTrackingModel.cs b/src/Tizen.Multimedia/MediaVision/FaceTrackingModel.cs
new file mode 100755 (executable)
index 0000000..93adb76
--- /dev/null
@@ -0,0 +1,150 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents face tracking model interface
+    /// </summary>
+    public class FaceTrackingModel : IDisposable
+    {
+        internal IntPtr _trackingModelHandle = IntPtr.Zero;
+        private bool _disposed = false;
+
+        /// <summary>
+        /// Construct of FaceTrackingModel class
+        /// </summary>
+        /// <code>
+        /// var model = new FaceTrackingModel();
+        /// </code>
+        public FaceTrackingModel()
+        {
+            int ret = Interop.MediaVision.FaceTrackingModel.Create(out _trackingModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to create FaceTrackingModel.");
+        }
+
+        /// <summary>
+        /// Construct of FaceTrackingModel class which creates and loads tracking model from file.
+        /// </summary>
+        /// <remarks>
+        /// FaceTrackingModel is loaded from the absolute path directory.\n
+        /// Models has been saved by <see cref="Save()"/> function can be loaded with this function
+        /// </remarks>
+        /// <param name="fileName">Name of path/file to load the model</param>
+        /// <seealso cref="Save()"/>
+        /// <seealso cref="Prepare()"/>
+        /// <code>
+        /// 
+        /// </code>
+        public FaceTrackingModel(string fileName)
+        {
+            int ret = Interop.MediaVision.FaceTrackingModel.Load(fileName, out _trackingModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to load FaceTrackingModel from file.");
+        }
+
+        /// <summary>
+        /// Destructor of the FaceTrackingModel class.
+        /// </summary>
+        ~FaceTrackingModel()
+        {
+            Dispose(false);
+        }
+
+        /// <summary>
+        /// Calls this function to initialize tracking model by the location of the face to be tracked.
+        /// </summary>
+        /// <param name="config">The configuration of engine will be used for model preparing. If NULL, then default settings will be used.</param>
+        /// <param name="source">The source where face location is specified. Usually it is the first frame of the video or the first image in the continuous image sequence planned to be used for tracking</param>
+        /// <param name="location">The quadrangle-shaped location determining position of the face to be tracked on the source. If NULL, then tracking model will try to find previously tracked face by itself. Don't set NULL when called first time for the tracking model.</param>
+        public void Prepare(FaceEngineConfiguration config, MediaVisionSource source, Quadrangle location = null)
+        {
+            if (source == null)
+            {
+                throw new ArgumentException("Invalid source");
+            }
+
+            IntPtr ptr = IntPtr.Zero;
+            if (location != null)
+            {
+                Interop.MediaVision.Quadrangle quadrangle = new Interop.MediaVision.Quadrangle()
+                {
+                    x1 = location.Points[0].X, y1 = location.Points[0].Y,
+                    x2 = location.Points[1].X, y2 = location.Points[1].Y,
+                    x3 = location.Points[2].X, y3 = location.Points[2].Y,
+                    x4 = location.Points[3].X, y4 = location.Points[3].Y
+                };
+                ptr = Marshal.AllocHGlobal(Marshal.SizeOf(quadrangle));
+                Marshal.StructureToPtr(quadrangle, ptr, false);
+            }
+
+            int ret = Interop.MediaVision.FaceTrackingModel.Prepare(_trackingModelHandle,
+                                                                    (config != null) ? config._engineHandle : IntPtr.Zero,
+                                                                    source._sourceHandle, ptr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to prepare tracking model.");
+        }
+
+        /// <summary>
+        /// Calls this method to save tracking model to the file.
+        /// </summary>
+        /// <remarks>
+        /// TrackingModel is saved to the absolute path directory.
+        /// </remarks>
+        /// <param name="fileName">Name of the path/file to save the model</param>
+        public void Save(string fileName)
+        {
+            if (string.IsNullOrEmpty(fileName))
+            {
+                throw new ArgumentException("Invalid file name");
+            }
+
+            int ret = Interop.MediaVision.FaceTrackingModel.Save(fileName, _trackingModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to save tracking model to file");
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object.
+        /// </summary>
+        public void Dispose()
+        {
+            Dispose(true);
+            GC.SuppressFinalize(this);
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
+        /// </summary>
+        /// <param name="disposing">If true, disposes any disposable objects. If false, does not dispose disposable objects.</param>
+        protected virtual void Dispose(bool disposing)
+        {
+            if (_disposed)
+            {
+                return;
+            }
+
+            if (disposing)
+            {
+                // Free managed objects
+            }
+
+            Interop.MediaVision.FaceTrackingModel.Destroy(_trackingModelHandle);
+            _disposed = true;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FaceTrackingResult.cs b/src/Tizen.Multimedia/MediaVision/FaceTrackingResult.cs
new file mode 100755 (executable)
index 0000000..6e88303
--- /dev/null
@@ -0,0 +1,39 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents result of face tracking operation.
+    /// </summary>
+    public class FaceTrackingResult
+    {
+        internal FaceTrackingResult()
+        {
+        }
+
+        /// <summary>
+        /// Gets the quadrangle-shaped location which determines new position of the tracked face on the source.
+        /// </summary>
+        public Quadrangle Location { get; internal set; }
+
+        /// <summary>
+        /// The confidence of the tracking_model that new location of the face was determined correctly
+        /// (value from 0.0 to 1.0). If no location was determined during last track iteration, then value is 0.0
+        /// </summary>
+        public double Confidence { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/FacialExpression.cs b/src/Tizen.Multimedia/MediaVision/FacialExpression.cs
new file mode 100755 (executable)
index 0000000..aab257c
--- /dev/null
@@ -0,0 +1,57 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration for expression types can be determined for faces.
+    /// </summary>
+    public enum FacialExpression
+    {
+        /// <summary>
+        /// Unknown face expression
+        /// </summary>
+        Unknown,
+        /// <summary>
+        /// Face expression is neutral
+        /// </summary>
+        Neutral,
+        /// <summary>
+        /// Face expression is smiling
+        /// </summary>
+        Smile,
+        /// <summary>
+        /// Face expression is sadness
+        /// </summary>
+        Sadness,
+        /// <summary>
+        /// Face expression is surprise
+        /// </summary>
+        Surprise,
+        /// <summary>
+        /// Face expression is anger
+        /// </summary>
+        Anger,
+        /// <summary>
+        /// Face expression is fear
+        /// </summary>
+        Fear,
+        /// <summary>
+        /// Face expression is disgust
+        /// </summary>
+        Disgust
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/Image.cs b/src/Tizen.Multimedia/MediaVision/Image.cs
new file mode 100755 (executable)
index 0000000..bb9135b
--- /dev/null
@@ -0,0 +1,179 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using Tizen.Multimedia;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents an interface for Image objects.
+    /// </summary>
+    public class Image : IDisposable
+    {
+        internal IntPtr _imageObjectHandle = IntPtr.Zero;
+        private bool _disposed = false;
+
+        /// <summary>
+        /// Constructor of Image object class
+        /// </summary>
+        public Image()
+        {
+            int ret = Interop.MediaVision.Image.Create(out _imageObjectHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to create image object");
+        }
+
+        /// <summary>
+        /// Constructor of image object class
+        /// </summary>
+        /// <param name="fileName">Name of path/file to load the image object</param>
+        public Image(string fileName)
+        {
+            ret = Interop.MediaVision.Image.Load(fileName, out _imageObjectHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to load image object from file");
+        }
+
+        /// <summary>
+        /// Destructor of ImageObject
+        /// </summary>
+        ~Image()
+        {
+            Dispose(false);
+        }
+
+        /// <summary>
+        /// Sets and gets a label for the image object
+        /// </summary>
+        public int Label
+        {
+            get
+            {
+                int label = 0;
+                MediaVisionError ret = (MediaVisionError) Interop.MediaVision.Image.GetLabel(_imageObjectHandle, out label);
+                if (ret != MediaVisionError.None)
+                {
+                    Tizen.Log.Error(MediaVisionLog.Tag, "Failed to get label");
+                }
+
+                return label;
+            }
+
+            set
+            {
+                int ret = Interop.MediaVision.Image.SetLabel(_imageObjectHandle, value);
+                MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to set label");
+            }
+        }
+
+        /// <summary>
+        /// Gets a value that determines how well an image object can be recognized.
+        /// </summary>
+        public double RecognitionRate
+        {
+            get
+            {
+                double rate = 0;
+                MediaVisionError ret = (MediaVisionError) Interop.MediaVision.Image.GetRecognitionRate(_imageObjectHandle, out rate);
+                if (ret != MediaVisionError.None)
+                {
+                    Tizen.Log.Error(MediaVisionLog.Tag, "Failed to get recognition rate, error : " + ret);
+                }
+
+                return rate;
+            }
+        }
+
+        /// <summary>
+        /// Fills the image object.\n
+        /// Extracts data from @a source image which will be needed for recognition of depicted object in @a location.
+        /// </summary>
+        /// <param name="source">The source image where image object is depicted</param>
+        /// <param name="config">The configuration of engine which will be used for extract recognition data from source. If NULL, then default settings will be used.</param>
+        /// <param name="location">Location of the image object on the source image, or NULL if the object is shown in full</param>
+        public void Fill(MediaVisionSource source, ImageEngineConfiguration config = null, Rectangle location = null)
+        {
+            if (source == null)
+            {
+                throw new ArgumentException("Inalid source");
+            }
+
+            IntPtr locationPtr = IntPtr.Zero;
+            if (location != null)
+            {
+                Interop.MediaVision.Rectangle rectangle = new Interop.MediaVision.Rectangle()
+                {
+                    width = location.Width,
+                    height = location.Height,
+                    x = location.Point.X,
+                    y = location.Point.Y
+                };
+                locationPtr = Marshal.AllocHGlobal(Marshal.SizeOf(rectangle));
+                Marshal.StructureToPtr(rectangle, locationPtr, false);
+            }
+
+            int ret = Interop.MediaVision.Image.Fill(_imageObjectHandle,
+                                                    (config != null) ? config._engineHandle : IntPtr.Zero,
+                                                    source._sourceHandle, locationPtr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to fill the image object");
+        }
+
+        /// <summary>
+        /// Saves the image object.
+        /// </summary>
+        /// <param name="fileName">Name of the file to path/save the image object</param>
+        public void Save(string fileName)
+        {
+            if (string.IsNullOrEmpty(fileName))
+            {
+                throw new ArgumentException("Inalid file name");
+            }
+
+            int ret = Interop.MediaVision.Image.Save(fileName, _imageObjectHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to save the image object");
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object.
+        /// </summary>
+        public void Dispose()
+        {
+            Dispose(true);
+            GC.SuppressFinalize(this);
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
+        /// </summary>
+        /// <param name="disposing">If true, disposes any disposable objects. If false, does not dispose disposable objects.</param>
+        protected virtual void Dispose(bool disposing)
+        {
+            if (_disposed)
+            {
+                return;
+            }
+
+            if (disposing)
+            {
+                // Free managed objects
+            }
+
+            Interop.MediaVision.Image.Destroy(_imageObjectHandle);
+            _disposed = true;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/ImageEngineConfiguration.cs b/src/Tizen.Multimedia/MediaVision/ImageEngineConfiguration.cs
new file mode 100755 (executable)
index 0000000..9d48821
--- /dev/null
@@ -0,0 +1,324 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents concrete EngineConfig for image recognition and tracking
+    /// </summary>
+    public class ImageEngineConfiguration : EngineConfiguration
+    {
+        // List of predefined keys
+        private const string _imageRecognitionObjectScaleFactorKey = "MV_IMAGE_RECOGNITION_OBJECT_SCALE_FACTOR";
+        private const string _imageRecognitionObjectMaxKeypointsKey = "MV_IMAGE_RECOGNITION_OBJECT_MAX_KEYPOINTS_NUM";
+        private const string _imageRecognitionSceneScaleFactorKey = "MV_IMAGE_RECOGNITION_SCENE_SCALE_FACTOR";
+        private const string _imageRecognitionSceneMaxKeypointsKey = "MV_IMAGE_RECOGNITION_SCENE_MAX_KEYPOINTS_NUM";
+        private const string _imageRecognitionMinKeypointsMatchKey = "MV_IMAGE_RECOGNITION_MIN_MATCH_NUM";
+        private const string _imageRecognitionReqMatchPartKey = "MV_IMAGE_RECOGNITION_REQ_MATCH_PART";
+        private const string _imageRecognitionTolerantPartMatchingErrorKey = "MV_IMAGE_RECOGNITION_TOLERANT_MATCH_PART_ERR";
+        private const string _imageTrackingHistoryAmountKey = "MV_IMAGE_TRACKING_HISTORY_AMOUNT";
+        private const string _imageTrackingExpectedOffsetKey = "MV_IMAGE_TRACKING_EXPECTED_OFFSET";
+        private const string _imageTrackingUseStabilizationKey = "MV_IMAGE_TRACKING_USE_STABLIZATION";
+        private const string _imageTrackingStabilizationTolerantShiftKey = "MV_IMAGE_TRACKING_STABLIZATION_TOLERANT_SHIFT";
+        private const string _imageTrackingStabilizationSpeedKey = "MV_IMAGE_TRACKING_STABLIZATION_SPEED";
+        private const string _imageTrackingStabilizationAccelarationKey = "MV_IMAGE_TRACKING_STABLIZATION_ACCELERATION";
+
+        // Values are cached below to prevent interop calls for get operation
+        private double _imageRecognitionObjectScaleFactorValue = 1.2;
+        private int _imageRecognitionObjectMaxKeypointsValue = 1000;
+        private double _imageRecognitionSceneScaleFactorValue = 1.2;
+        private int _imageRecognitionSceneMaxKeypointsValue = 5000;
+        private int _imageRecognitionMinKeypointsMatchValue = 30;
+        private double _imageRecognitionReqMatchPartValue = 0.05;
+        private double _imageRecognitionTolerantPartMatchingErrorValue = 0.1;
+        private int _imageTrackingHistoryAmountValue = 3;
+        private double _imageTrackingExpectedOffsetValue = 0;
+        private bool _imageTrackingUseStabilizationValue = true;
+        private double _imageTrackingStabilizationTolerantShiftValue;
+        private double _imageTrackingStabilizationSpeedValue = 0.3;
+        private double _imageTrackingStabilizationAccelarationValue = 0.1;
+
+        /// <summary>
+        /// The default constructor of ImageEngineConfiguration class
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public ImageEngineConfiguration()
+            : base()
+        {
+        }
+
+        /// <summary>
+        /// Sets and gets the image to be recognized scale factor attribute of the engine configuration.\n
+        /// The value of the factor will be used for resizing of the images (objects) for recognition.
+        /// Scale factor is the double value and the defalut is 1.2
+        /// </summary>
+        public double ObjectScaleFactor
+        {
+            get
+            {
+                return _imageRecognitionObjectScaleFactorValue;
+            }
+
+            set
+            {
+                Add<double>(_imageRecognitionObjectScaleFactorKey, value);
+                _imageRecognitionObjectScaleFactorValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the maximum keypoints should be detected on the image attribute of the engine configuration.\n
+        /// The maximal number of keypoints can be selected on the image object to calculate descriptors.
+        /// This keypoints will be used for image (object) recognition and has to be specified as integer number and the defalut is 1000.
+        /// </summary>
+        public int ObjectMaxKeyPoints
+        {
+            get
+            {
+                return _imageRecognitionObjectMaxKeypointsValue;
+            }
+
+            set
+            {
+                Add<int>(_imageRecognitionObjectMaxKeypointsKey, (int)value);
+                _imageRecognitionObjectMaxKeypointsValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the scene scale factor attribute of the engine configuration.\n
+        /// The value of the factor will be used for resizing of the scene including the images (objects) for recognition.
+        /// Scale factor is the double value and the defalut is 1.2
+        /// </summary>
+        public double SceneScaleFactor
+        {
+            get
+            {
+                return _imageRecognitionSceneScaleFactorValue;
+            }
+
+            set
+            {
+                Add<double>(_imageRecognitionSceneScaleFactorKey, value);
+                _imageRecognitionSceneScaleFactorValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets set the maximum keypoints should be detected on the scene attribute of the engine configuration.\n
+        /// The maximal number of keypoints can be selected on the scene including the images (objects) to calculate descriptors.
+        /// This keypoints will be used for image recognition and has to be specified as unsigned integer and the defalut is 5000.
+        /// </summary>
+        public int SceneMaxKeyPoints
+        {
+            get
+            {
+                return _imageRecognitionSceneMaxKeypointsValue;
+            }
+
+            set
+            {
+                Add<int>(_imageRecognitionSceneMaxKeypointsKey, value);
+                _imageRecognitionSceneMaxKeypointsValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the minimum number of keypoints matches required for recognition attribute of the engine configuration.\n
+        /// The minimal number of keypoints should be matched between an image and a scene.
+        /// It will be taken into account for image objects recognition. Value is unsigned integer and the defalut is 30.
+        /// </summary>
+        public int MinKeyPointsMatches
+        {
+            get
+            {
+                return _imageRecognitionMinKeypointsMatchValue;
+            }
+
+            set
+            {
+                Add<int>(_imageRecognitionMinKeypointsMatchKey, value);
+                _imageRecognitionMinKeypointsMatchValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the required matching part for the image recognition attribute of the engine configuration.\n
+        /// To recognize occluded or hidden an image by other images, required relative part of the matches in respect to the total
+        /// amount of matching keypoints required for image recognition. Too low value will result in unsustainable behavior,
+        /// but effect of object overlapping will be reduced. Value can be from 0 to 1 and the defalut is 0.05.
+        /// </summary>
+        public double RequiredMatchingPart
+        {
+            get
+            {
+                return _imageRecognitionReqMatchPartValue;
+            }
+
+            set
+            {
+                if (value < 0 || value > 1)
+                {
+                    throw new ArgumentException("Invalid value");
+                }
+
+                Add<double>(_imageRecognitionReqMatchPartKey, value);
+                _imageRecognitionReqMatchPartValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the part matching error for the image recognition attribute of the engine configuration.\n
+        /// Allowable error of matches number. Value can be from 0 to 1 and the defalut is 0.1
+        /// </summary>
+        public double TolerantPartMatchingError
+        {
+            get
+            {
+                return _imageRecognitionTolerantPartMatchingErrorValue;
+            }
+
+            set
+            {
+                if (value < 0 || value > 1)
+                {
+                    throw new ArgumentException("Invalid value");
+                }
+
+                Add<double>(_imageRecognitionTolerantPartMatchingErrorKey, value);
+                _imageRecognitionTolerantPartMatchingErrorValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the number of recognition results in the tracking history attribute of the engine configuration.\n
+        /// Number of previous recognition results, which will influence the stabilization. Value is unsigned integer and the defalut is 3.
+        /// </summary>
+        public int TrackingHistoryAmount
+        {
+            get
+            {
+                return _imageTrackingHistoryAmountValue;
+            }
+
+            set
+            {
+                Add<int>(_imageTrackingHistoryAmountKey, value);
+                _imageTrackingHistoryAmountValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the expected tracking offset attribute of the engine configuration.\n
+        /// Relative offset value, for which the object offset is expected (relative to the object size in the current frame).
+        /// Value is a double and the defalut is 0.
+        /// </summary>
+        public double ExpectedTrackingOffset
+        {
+            get
+            {
+                return _imageTrackingExpectedOffsetValue;
+            }
+
+            set
+            {
+                Add<double>(_imageTrackingExpectedOffsetKey, value);
+                _imageTrackingExpectedOffsetValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the acceleration of the tracking stabilization attribute of the engine configuration.\n
+        /// Acceleration will be used for image stabilization (relative to the distance from current location to stabilized location).
+        /// Value is double from 0 to 1 and the defalut is 0.1.
+        /// </summary>
+        public double TrackingStabilizationAccelaration
+        {
+            get
+            {
+                return _imageTrackingStabilizationAccelarationValue;
+            }
+
+            set
+            {
+                if (value < 0 || value > 1)
+                {
+                    throw new ArgumentException("Invalid value");
+                }
+
+                Add<double>(_imageTrackingStabilizationAccelarationKey, value);
+                _imageTrackingStabilizationAccelarationValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the speed of the tracking stabilization attribute of the engine configuration.\n
+        /// Start speed will be used for image stabilization. Value is a double and the defalut is 0.3.
+        /// </summary>
+        public double TrackingStabilizationSpeed
+        {
+            get
+            {
+                return _imageTrackingStabilizationSpeedValue;
+            }
+
+            set
+            {
+                Add<double>(_imageTrackingStabilizationSpeedKey, value);
+                _imageTrackingStabilizationSpeedValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets the relative tolerant shift for the tracking stabilization attribute of the engine configuration.\n
+        /// It is component of tolerant shift which will be ignored by stabilization process.
+        /// </summary>
+        public double TrackingStabilizationTolerantShift
+        {
+            get
+            {
+                return _imageTrackingStabilizationTolerantShiftValue;
+            }
+
+            set
+            {
+                Add<double>(_imageTrackingStabilizationTolerantShiftKey, value);
+                _imageTrackingStabilizationTolerantShiftValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Enables/disables the contour stabilization during tracking process. Default value is true.
+        /// </summary>
+        public bool UseTrackingStabilization
+        {
+            get
+            {
+                return _imageTrackingUseStabilizationValue;
+            }
+
+            set
+            {
+                Add<bool>(_imageTrackingUseStabilizationKey, value);
+                _imageTrackingUseStabilizationValue = value;
+            }
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/ImageRecognitionResult.cs b/src/Tizen.Multimedia/MediaVision/ImageRecognitionResult.cs
new file mode 100755 (executable)
index 0000000..4668ce7
--- /dev/null
@@ -0,0 +1,35 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System.Collections.Generic;
+
+namespace Tizen.Multimedia
+{
+    public class ImageRecognitionResult
+    {
+        /// <summary>
+        /// This class represents result of image recognition operation.
+        /// </summary>
+        internal ImageRecognitionResult()
+        {
+        }
+
+        /// <summary>
+        /// The locations of image objects on the source image.
+        /// </summary>
+        public List<Quadrangle> Locations { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/ImageRecognizer.cs b/src/Tizen.Multimedia/MediaVision/ImageRecognizer.cs
new file mode 100755 (executable)
index 0000000..863c168
--- /dev/null
@@ -0,0 +1,116 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+using System;
+using System.Collections.Generic;
+using System.Runtime.InteropServices;
+using System.Threading.Tasks;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents an interface for image recognition functionality.
+    /// </summary>
+    public static class ImageRecognizer
+    {
+        /// <summary>
+        /// Recognizes the given image objects on the source image.\n
+        /// Use this function to launch image recognition algorithm configured by @a config configuration.
+        /// </summary>
+        /// <param name="source">The source image on which image objects will be recognized</param>
+        /// <param name="imageObjects">The array of image objects which will be processed as targets of recognition</param>
+        /// <param name="config">The configuration of engine which will be used for recognition. If NULL, then default settings will be used.</param>
+        /// <returns>Returns ImageRecognitionResult asynchronously</returns>
+        public static async Task<ImageRecognitionResult> RecognizeAsync(MediaVisionSource source, Image[] imageObjects, ImageEngineConfiguration config = null)
+        {
+            if (source == null || imageObjects.Length == 0)
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            IntPtr[] ptrArray = new IntPtr[imageObjects.Length];
+            for (int i = 0; i < imageObjects.Length; i++)
+            {
+                if (imageObjects[i] == null)
+                {
+                    throw new ArgumentException("Invalid parameter");
+                }
+
+                ptrArray[i] = imageObjects[i]._imageObjectHandle;
+            }
+
+            int size = Marshal.SizeOf(typeof(IntPtr)) * ptrArray.Length;
+            IntPtr imageObjectsPtr = Marshal.AllocHGlobal(size);
+
+            Marshal.Copy(ptrArray, 0, imageObjectsPtr, ptrArray.Length);
+
+            TaskCompletionSource<ImageRecognitionResult> tcsResult = new TaskCompletionSource<ImageRecognitionResult>();
+
+            // Define native callback
+            Interop.MediaVision.Image.MvImageRecognizedCallback imageRecognizedCb = (IntPtr sourceHandle, IntPtr engineCfgHandle, IntPtr imageObjectsHandle, IntPtr locationsPtr, uint numberOfObjects, IntPtr userData) =>
+            {
+                try
+                {
+                    List<Quadrangle> locations = new List<Quadrangle>();
+                    if (numberOfObjects > 0)
+                    {
+                        IntPtr[] imageLocationsPtr = new IntPtr[numberOfObjects];
+                        Marshal.Copy(locationsPtr, imageLocationsPtr, 0, (int)numberOfObjects);
+
+                        // Prepare list of locations
+                        for (int i = 0; i < numberOfObjects; i++)
+                        {
+                            Interop.MediaVision.Quadrangle location = (Interop.MediaVision.Quadrangle)Marshal.PtrToStructure(imageLocationsPtr[i], typeof(Interop.MediaVision.Quadrangle));
+                            Quadrangle quadrangle = new Quadrangle()
+                            {
+                                Points = new Point[4]
+                                {
+                                new Point(location.x1, location.y1),
+                                new Point(location.x2, location.y2),
+                                new Point(location.x3, location.y3),
+                                new Point(location.x4, location.y4)
+                                }
+                            };
+                            Log.Info(MediaVisionLog.Tag, String.Format("Image recognized, Location : {0}", quadrangle.ToString()));
+                            locations.Add(quadrangle);
+                        }
+                    }
+
+                    ImageRecognitionResult result = new ImageRecognitionResult()
+                    {
+                        Locations = locations
+                    };
+
+                    if (!tcsResult.TrySetResult(result))
+                    {
+                        Log.Info(MediaVisionLog.Tag, "Failed to set result");
+                        tcsResult.TrySetException(new InvalidOperationException("Failed to set result"));
+                    }
+                }
+                catch (Exception ex)
+                {
+                    Log.Info(MediaVisionLog.Tag, "exception :" + ex.ToString());
+                    tcsResult.TrySetException(ex);
+                }
+            };
+
+            int ret = Interop.MediaVision.Image.Recognize(source._sourceHandle, imageObjectsPtr, ptrArray.Length, (config != null) ? config._engineHandle : IntPtr.Zero, imageRecognizedCb, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to perform image recognition.");
+
+            return await tcsResult.Task;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/ImageTracker.cs b/src/Tizen.Multimedia/MediaVision/ImageTracker.cs
new file mode 100755 (executable)
index 0000000..9fd2505
--- /dev/null
@@ -0,0 +1,91 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using System.Threading.Tasks;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class contains the Media Vision image tracking API which performs tracking
+    /// on <see cref="MediaVisionSource"/> for <see cref="ImageTrackingModel"/>
+    /// </summary>
+    public static class ImageTracker
+    {
+        /// <summary>
+        /// Tracks the given image tracking model on the current frame asynchronously.
+        /// </summary>
+        /// <param name="source">The current image of sequence where image tracking model will be tracked</param>
+        /// <param name="trackingModel">The image tracking model which processed as target of tracking</param>
+        /// <param name="config">The configuration of engine which will be used for tracking. If NULL, then default settings will be used.</param>
+        /// <returns>Returns the image object location asynchronously</returns>
+        /// <code>
+        /// 
+        /// </code>
+        public static async Task<Quadrangle> TrackAsync(MediaVisionSource source, ImageTrackingModel trackingModel, ImageEngineConfiguration config = null)
+        {
+            if (source == null || trackingModel == null)
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            TaskCompletionSource<Quadrangle> tcsResult = new TaskCompletionSource<Quadrangle>();
+
+            // Define native callback
+            Interop.MediaVision.Image.MvImageTrackedCallback imageTrackedCb = (IntPtr sourceHandle, IntPtr imageTrackingModelHandle, IntPtr engineCfgHandle, IntPtr locationPtr, IntPtr userData) =>
+            {
+                try
+                {
+                    Quadrangle imageLocation = null;
+                    if (locationPtr != IntPtr.Zero)
+                    {
+                        Interop.MediaVision.Quadrangle location = (Interop.MediaVision.Quadrangle)Marshal.PtrToStructure(locationPtr, typeof(Interop.MediaVision.Quadrangle));
+                        imageLocation = new Quadrangle()
+                        {
+                            Points = new Point[4]
+                            {
+                            new Point(location.x1, location.y1),
+                            new Point(location.x2, location.y2),
+                            new Point(location.x3, location.y3),
+                            new Point(location.x4, location.y4)
+                            }
+                        };
+
+                        Log.Info(MediaVisionLog.Tag, String.Format("Image tracked, location : {0}", imageLocation.ToString()));
+                    }
+
+                    if (!tcsResult.TrySetResult(imageLocation))
+                    {
+                        Log.Info(MediaVisionLog.Tag, "Failed to set result");
+                        tcsResult.TrySetException(new InvalidOperationException("Failed to set result"));
+                    }
+                }
+                catch (Exception ex)
+                {
+                    Log.Info(MediaVisionLog.Tag, "exception :" + ex.ToString());
+                    tcsResult.TrySetException(ex);
+                }
+            };
+
+            int ret = Interop.MediaVision.Image.Track(source._sourceHandle, trackingModel._trackingModelHandle, (config != null) ? config._engineHandle : IntPtr.Zero, imageTrackedCb, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to perform image tracking.");
+
+            return await tcsResult.Task;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/ImageTrackingModel.cs b/src/Tizen.Multimedia/MediaVision/ImageTrackingModel.cs
new file mode 100755 (executable)
index 0000000..c59eed4
--- /dev/null
@@ -0,0 +1,142 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents image tracking model interface
+    /// </summary>
+    public class ImageTrackingModel
+    {
+        internal IntPtr _trackingModelHandle = IntPtr.Zero;
+        private bool _disposed = false;
+
+        /// <summary>
+        /// Construct of ImageTrackingModel class
+        /// </summary>
+        public ImageTrackingModel()
+        {
+            int ret = Interop.MediaVision.ImageTrackingModel.Create(out _trackingModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to create FaceTrackingModel.");
+        }
+
+        /// <summary>
+        /// Construct of ImageTrackingModel class which creates and loads tracking model from file.
+        /// </summary>
+        /// <remarks>
+        /// ImageTrackingModel is loaded from the absolute path directory.\n
+        /// Models has been saved by <see cref="Save()"/> function can be loaded with this function
+        /// </remarks>
+        /// <param name="fileName">Name of path/file to load the model</param>
+        /// <seealso cref="Save()"/>
+        /// <seealso cref="Prepare()"/>
+        /// <code>
+        /// 
+        /// </code>
+        public ImageTrackingModel(string fileName)
+        {
+            int ret = Interop.MediaVision.ImageTrackingModel.Load(fileName, out _trackingModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to load ImageTrackingModel from file.");
+        }
+
+        /// <summary>
+        /// Destructor of the ImageTrackingModel class.
+        /// </summary>
+        ~ImageTrackingModel()
+        {
+            Dispose(false);
+        }
+
+        /// <summary>
+        /// Sets target of image tracking model.\n
+        /// Sets image object which will be tracked by using tracking functionality with this tracking model.
+        /// </summary>
+        /// <param name="imageObject">Image object which will be set as target for tracking</param>
+        public void SetTarget(Image imageObject)
+        {
+            if (imageObject == null)
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            int ret = Interop.MediaVision.ImageTrackingModel.SetTarget(imageObject._imageObjectHandle, _trackingModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to set target of image tracking model");
+        }
+
+        /// <summary>
+        /// Refreshes the state of image tracking model.\n
+        /// Clears moving history and change state to undetected. This function is usually called each time before tracking is started
+        /// for the new sequence of sources which is not the direct continuation of the sequence for which tracking has been performed before.
+        /// Tracking algorithm will try to find image by itself.
+        /// </summary>
+        /// <param name="config">Image engine configuration. If null, default configuration will be used</param>
+        public void Refresh(ImageEngineConfiguration config = null)
+        {
+            int ret = Interop.MediaVision.ImageTrackingModel.Refresh(_trackingModelHandle, (config != null) ? config._engineHandle : IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to refresh state");
+        }
+
+        /// <summary>
+        /// Calls this method to save tracking model to the file.
+        /// </summary>
+        /// <remarks>
+        /// TrackingModel is saved to the absolute path directory.
+        /// </remarks>
+        /// <param name="fileName">Name of the path/file to save the model</param>
+        public void Save(string fileName)
+        {
+            if (string.IsNullOrEmpty(fileName))
+            {
+                throw new ArgumentException("Invalid file name");
+            }
+
+            int ret = Interop.MediaVision.ImageTrackingModel.Save(fileName, _trackingModelHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to save tracking model to file");
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object.
+        /// </summary>
+        public void Dispose()
+        {
+            Dispose(true);
+            GC.SuppressFinalize(this);
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
+        /// </summary>
+        /// <param name="disposing">If true, disposes any disposable objects. If false, does not dispose disposable objects.</param>
+        protected virtual void Dispose(bool disposing)
+        {
+            if (_disposed)
+            {
+                return;
+            }
+
+            if (disposing)
+            {
+                // Free managed objects
+            }
+
+            Interop.MediaVision.ImageTrackingModel.Destroy(_trackingModelHandle);
+            _disposed = true;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/MediaVisionErrorFactory.cs b/src/Tizen.Multimedia/MediaVision/MediaVisionErrorFactory.cs
new file mode 100755 (executable)
index 0000000..6986b3d
--- /dev/null
@@ -0,0 +1,135 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using Tizen.Internals.Errors;
+
+namespace Tizen.Multimedia
+{
+    internal static class MediaVisionLog
+    {
+        internal const string Tag = "Tizen.Multimedia.MediaVision";
+    }
+
+    /// <summary>
+    /// Enumeration for media vision's error codes.
+    /// </summary>
+    internal enum MediaVisionError
+    {
+        MediaVisionErrorCode = -0x019D0000,
+        /// <summary>
+        /// Successful
+        /// </summary>
+        None = ErrorCode.None,
+        /// <summary>
+        /// Not supported
+        /// </summary>
+        NotSupported = ErrorCode.NotSupported,
+        /// <summary>
+        /// Message too long
+        /// </summary>
+        MsgTooLong = ErrorCode.MsgTooLong,
+        /// <summary>
+        /// No data
+        /// </summary>
+        NoData = ErrorCode.NoData,
+        /// <summary>
+        /// Key not available
+        /// </summary>
+        KeyNotAvailable = ErrorCode.KeyNotAvailable,
+        /// <summary>
+        /// Out of memory
+        /// </summary>
+        OutOfMemory = ErrorCode.OutOfMemory,
+        /// <summary>
+        /// Invalid parameter
+        /// </summary>
+        InvalidParameter = ErrorCode.InvalidParameter,
+        /// <summary>
+        /// Invalid operation
+        /// </summary>
+        InvalidOperation = ErrorCode.InvalidOperation,
+        /// <summary>
+        /// Permission denied
+        /// </summary>
+        PermissionDenied = ErrorCode.PermissionDenied,
+        /// <summary>
+        /// Not supported format
+        /// </summary>
+        NotSupportedFormat = MediaVisionErrorCode | 0x01,
+        /// <summary>
+        /// Internal error
+        /// </summary>
+        Internal = MediaVisionErrorCode | 0x02,
+        /// <summary>
+        /// Invalid data
+        /// </summary>
+        InvalidData = MediaVisionErrorCode | 0x03,
+        /// <summary>
+        /// Invalid path (Since 3.0)
+        /// </summary>
+        InvalidPath = MediaVisionErrorCode | 0x04
+    }
+
+    internal static class MediaVisionErrorFactory
+    {
+        internal static void CheckAndThrowException(int error, string msg)
+        {
+            MediaVisionError e = (MediaVisionError)error;
+            if (e != MediaVisionError.None)
+            {
+                Log.Error(MediaVisionLog.Tag, String.Format("{0} : {1}", e.ToString(), msg));
+                throw GetException(error, msg);
+            }
+        }
+
+        internal static Exception GetException(int err, string msg)
+        {
+            MediaVisionError e = (MediaVisionError)err;
+            switch (e)
+            {
+                case MediaVisionError.None:
+                    return null;
+                case MediaVisionError.NotSupported:
+                    throw new NotSupportedException("Not Supported: " + msg);
+                case MediaVisionError.MsgTooLong:
+                    throw new InvalidOperationException("Message too long: " + msg);
+                case MediaVisionError.NoData:
+                    throw new InvalidOperationException("No Data: " + msg);
+                case MediaVisionError.KeyNotAvailable:
+                    throw new InvalidOperationException("Key Not Available: " + msg);
+                case MediaVisionError.OutOfMemory:
+                    throw new OutOfMemoryException("Out of Memory: " + msg);
+                case MediaVisionError.InvalidParameter:
+                    throw new ArgumentException("Invalid Parameter: " + msg);
+                case MediaVisionError.InvalidOperation:
+                    throw new InvalidOperationException("Invalid Opertation: " + msg);
+                case MediaVisionError.PermissionDenied:
+                    throw new UnauthorizedAccessException("Permission Denied: " + msg);
+                case MediaVisionError.NotSupportedFormat:
+                    throw new InvalidOperationException("Not Supported Format: " + msg);
+                case MediaVisionError.Internal:
+                    throw new InvalidOperationException("Internal Error: " + msg);
+                case MediaVisionError.InvalidData:
+                    throw new InvalidOperationException("Invalid Data: " + msg);
+                case MediaVisionError.InvalidPath:
+                    throw new InvalidOperationException("Invalid Path: " + msg);
+                default:
+                    throw new InvalidOperationException("Unknown Error: " + msg);
+            }
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/MediaVisionSource.cs b/src/Tizen.Multimedia/MediaVision/MediaVisionSource.cs
new file mode 100755 (executable)
index 0000000..8e3bdc5
--- /dev/null
@@ -0,0 +1,218 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Runtime.InteropServices;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents media vision source. An instance of this class has to be created \n
+    /// to keep information on image or video frame data as raw buffer. It can be created based on \n
+    /// the media data stored in memory or using the BaseMediaPacket class. \n
+    /// It provides a set of getters which allow to retrieve such image parameters as its size or colorspace (see Colorspace enumeration).
+    /// </summary>
+    public class MediaVisionSource : IDisposable
+    {
+        internal IntPtr _sourceHandle = IntPtr.Zero;
+        private bool _disposed = false;
+
+        /// <summary>
+        /// The media vision source constructor
+        /// </summary>
+        /// <code>
+        /// MediaVisionSource source = new MediaVisionSource();
+        /// </code>
+        public MediaVisionSource()
+        {
+            int ret = Interop.MediaVision.MediaSource.Create(out _sourceHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to create media vision source.");
+        }
+
+        /// <summary>
+        /// Destructor of the MediaVisionSource class.
+        /// </summary>
+        ~MediaVisionSource()
+        {
+            Dispose(false);
+        }
+
+        /// <summary>
+        /// Gets buffer of the media source.
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public byte[] Buffer
+        {
+            get
+            {
+                IntPtr byteStrPtr;
+                int byteStrSize;
+                MediaVisionError ret = (MediaVisionError)Interop.MediaVision.MediaSource.GetBuffer(_sourceHandle, out byteStrPtr, out byteStrSize);
+                if (ret != MediaVisionError.None)
+                {
+                    Log.Error(MediaVisionLog.Tag, "[{0}] : Failed to get buffer data", ret.ToString());
+                    return null;
+                }
+
+                byte[] byteStr = new byte[byteStrSize];
+                if (byteStrSize > 0)
+                {
+                    Marshal.Copy(byteStrPtr, byteStr, 0, byteStrSize);
+                }
+
+                return byteStr;
+            }
+        }
+
+        /// <summary>
+        /// Gets height of the media source.
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public uint Height
+        {
+            get
+            {
+                uint height = 0;
+                MediaVisionError ret = (MediaVisionError)Interop.MediaVision.MediaSource.GetHeight(_sourceHandle, out height);
+                if (ret != MediaVisionError.None)
+                {
+                    Log.Error(MediaVisionLog.Tag, "[{0}] : Failed to get height", ret.ToString());
+                }
+
+                return height;
+            }
+        }
+
+        /// <summary>
+        /// Gets width of the media source.
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public uint Width
+        {
+            get
+            {
+                uint width = 0;
+                MediaVisionError ret = (MediaVisionError)Interop.MediaVision.MediaSource.GetWidth(_sourceHandle, out width);
+                if (ret != MediaVisionError.None)
+                {
+                    Log.Error(MediaVisionLog.Tag, "[{0}] : Failed to get width", ret.ToString());
+                }
+
+                return width;
+            }
+        }
+
+        /// <summary>
+        /// Gets colorspace of the media source.
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public Colorspace Colorspace
+        {
+            get
+            {
+                Colorspace colorspace = Colorspace.Invalid;
+                MediaVisionError ret = (MediaVisionError)Interop.MediaVision.MediaSource.GetColorspace(_sourceHandle, out colorspace);
+                if (ret != MediaVisionError.None)
+                {
+                    Log.Error(MediaVisionLog.Tag, "[{0}] : Failed to get colorspace", ret.ToString());
+                }
+
+                return colorspace;
+            }
+        }
+
+        /// <summary>
+        /// Fills the media source based on the media packet.
+        /// </summary>
+        /// <param name="mediaPacket">The media packet from which the source will be filled</param>
+        /// <code>
+        /// 
+        /// </code>
+        /*public void FillMediaPacket(BaseMediaPacket mediaPacket)
+        {
+            int ret = Interop.MediaVision.MediaSource.FillBuffer(out _sourceHandle, mediaPacket._mediaPacketHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to fill media packet");
+        }*/
+
+        /// <summary>
+        /// Fills the media source based on the buffer and metadata.
+        /// </summary>
+        /// <param name="buffer">The buffer of image data</param>
+        /// <param name="width">The width of image data</param>
+        /// <param name="height">The height of image data</param>
+        /// <param name="colorspace">The image colorspace</param>
+        /// <seealso cref="Clear()"/>
+        /// <code>
+        /// 
+        /// </code>
+        public void FillBuffer(byte[] buffer, uint width, uint height, Colorspace colorspace)
+        {
+            int ret = Interop.MediaVision.MediaSource.FillBuffer(_sourceHandle, buffer, buffer.Length, width, height, colorspace);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to fill buffer");
+        }
+
+        /// <summary>
+        /// Clears the buffer of the media source.
+        /// </summary>
+        /// <seealso cref="FillBuffer()"/>
+        /// <code>
+        /// 
+        /// </code>
+        public void Clear()
+        {
+            int ret = Interop.MediaVision.MediaSource.Clear(_sourceHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to clear media source buffer");
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object.
+        /// </summary>
+        public void Dispose()
+        {
+            Dispose(true);
+            GC.SuppressFinalize(this);
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
+        /// </summary>
+        /// <param name="disposing">If true, disposes any disposable objects. If false, does not dispose disposable objects.</param>
+        protected virtual void Dispose(bool disposing)
+        {
+            if (_disposed)
+            {
+                return;
+            }
+
+            if (disposing)
+            {
+                // Free managed objects
+            }
+
+            Interop.MediaVision.MediaSource.Destroy(_sourceHandle);
+            _disposed = true;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/MovementDetectedEventArgs.cs b/src/Tizen.Multimedia/MediaVision/MovementDetectedEventArgs.cs
new file mode 100755 (executable)
index 0000000..d462555
--- /dev/null
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class is an event arguments of the MovementDetected event.
+    /// </summary>
+    public class MovementDetectedEventArgs : EventArgs
+    {
+        internal MovementDetectedEventArgs()
+        {
+        }
+
+        /// <summary>
+        /// The identifier of the video source where event has been detected
+        /// </summary>
+        public int VideoStreamId { get; internal set; }
+
+        /// <summary>
+        /// Gets a set of rectangular regions where movement was detected.
+        /// </summary>
+        public List<Rectangle> Regions { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/MovementDetectionEventTrigger.cs b/src/Tizen.Multimedia/MediaVision/MovementDetectionEventTrigger.cs
new file mode 100755 (executable)
index 0000000..4eecca5
--- /dev/null
@@ -0,0 +1,49 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class representsmovement detection event trigger.
+    /// </summary>
+    public class MovementDetectionEventTrigger : SurveillanceEventTrigger
+    {
+        /// <summary>
+        /// Constructor of MovementDetectionEventTrigger class
+        /// </summary>
+        public MovementDetectionEventTrigger() : base(SurveillanceEventTrigger.MovementDetectedType)
+        {
+        }
+
+        /// <summary>
+        /// This is event for a movement detection. The result will be position of regions where movement has been detected.
+        /// </summary>
+        public event EventHandler<MovementDetectedEventArgs> MovementDetected
+        {
+            add
+            {
+                base.MovementDetectedEvent += value;
+            }
+
+            remove
+            {
+                base.MovementDetectedEvent -= value;
+            }
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/PersonAppearanceChangedEventArgs.cs b/src/Tizen.Multimedia/MediaVision/PersonAppearanceChangedEventArgs.cs
new file mode 100755 (executable)
index 0000000..72696a6
--- /dev/null
@@ -0,0 +1,51 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class is an event arguments of the PersonAppearanceChanged event.
+    /// </summary>
+    public class PersonAppearanceChangedEventArgs : EventArgs
+    {
+        internal PersonAppearanceChangedEventArgs()
+        {
+        }
+
+        /// <summary>
+        /// The identifier of the video source where event has been detected
+        /// </summary>
+        public int VideoStreamId { get; internal set; }
+
+        /// <summary>
+        /// Gets a set of rectangular locations where appearances of the persons were detected.
+        /// </summary>
+        public List<Rectangle> AppearedLocations { get; internal set; }
+
+        /// <summary>
+        /// Gets a set of rectangular locations where disappearances of the persons were detected.
+        /// </summary>
+        public List<Rectangle> DisappearedLocations { get; internal set; }
+
+        /// <summary>
+        /// Gets a set of rectangular locations where persons were tracked.
+        /// </summary>
+        public List<Rectangle> TrackedLocations { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/PersonAppearanceEventTrigger.cs b/src/Tizen.Multimedia/MediaVision/PersonAppearanceEventTrigger.cs
new file mode 100755 (executable)
index 0000000..d31dfe5
--- /dev/null
@@ -0,0 +1,52 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents person appearance event trigger.
+    /// </summary>
+    public class PersonAppearanceEventTrigger : SurveillanceEventTrigger
+    {
+        /// <summary>
+        /// Constructor of PersonAppearanceEventTrigger class
+        /// </summary>
+        public PersonAppearanceEventTrigger() : base(SurveillanceEventTrigger.PersonAppearanceChangedType)
+        {
+        }
+
+        /// <summary>
+        /// This is event for a person appearing (disappearing). The result will be:
+        /// * positions of person, which were appeared;
+        /// * positions of persons, which were tracked;
+        /// * positions of persons, which were disappeared.
+        /// </summary>
+        public event EventHandler<PersonAppearanceChangedEventArgs> PersonAppearanceChanged
+        {
+            add
+            {
+                base.PersonAppearanceChangedEvent += value;
+            }
+
+            remove
+            {
+                base.PersonAppearanceChangedEvent -= value;
+            }
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/PersonRecognitionEventTrigger.cs b/src/Tizen.Multimedia/MediaVision/PersonRecognitionEventTrigger.cs
new file mode 100755 (executable)
index 0000000..3b6da67
--- /dev/null
@@ -0,0 +1,50 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents person recognition event trigger.
+    /// </summary>
+    public class PersonRecognitionEventTrigger : SurveillanceEventTrigger
+    {
+        /// <summary>
+        /// Constructor of PersonRecognizedEventTrigger class
+        /// </summary>
+        public PersonRecognitionEventTrigger() : base(SurveillanceEventTrigger.PersonRecognizedType)
+        {
+        }
+
+        /// <summary>
+        /// This is an event for a person recognition. The result will be positions (face locations) of persons, which were recognized,
+        /// their labels and confidences of the recognition models
+        /// </summary>
+        public event EventHandler<PersonRecognizedEventArgs> PersonRecognized
+        {
+            add
+            {
+                base.PersonRecognizedEvent += value;
+            }
+
+            remove
+            {
+                base.PersonRecognizedEvent -= value;
+            }
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/PersonRecognitionResult.cs b/src/Tizen.Multimedia/MediaVision/PersonRecognitionResult.cs
new file mode 100755 (executable)
index 0000000..d95b8f1
--- /dev/null
@@ -0,0 +1,43 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents result of person recognition event trigger.
+    /// </summary>
+    public class PersonRecognitionResult
+    {
+        internal PersonRecognitionResult()
+        {
+        }
+
+        /// <summary>
+        /// Gets a rectangular locations where person face was recognized.
+        /// </summary>
+        public Rectangle Location { get; internal set; }
+
+        /// <summary>
+        /// Gets a label that correspond to the recognized person.
+        /// </summary>
+        public int Label { get; internal set; }
+
+        /// <summary>
+        /// Gets a confidence value that correspond to the recognized person.
+        /// </summary>
+        public double Confidence { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/PersonRecognizedEventArgs.cs b/src/Tizen.Multimedia/MediaVision/PersonRecognizedEventArgs.cs
new file mode 100755 (executable)
index 0000000..64f65cb
--- /dev/null
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class is an event arguments of the PersonRecognized event.
+    /// </summary>
+    public class PersonRecognizedEventArgs : EventArgs
+    {
+        internal PersonRecognizedEventArgs()
+        {
+        }
+
+        /// <summary>
+        /// The identifier of the video source where event has been detected
+        /// </summary>
+        public int VideoStreamId { get; internal set; }
+
+        /// <summary>
+        /// Gets a set of information that correspond to the recognized persons
+        /// </summary>
+        public List<PersonRecognitionResult> Result { get; internal set; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/Point.cs b/src/Tizen.Multimedia/MediaVision/Point.cs
new file mode 100755 (executable)
index 0000000..4b28251
--- /dev/null
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents a point in 2D space.
+    /// </summary>
+    public class Point
+    {
+        internal Point()
+        {
+        }
+
+        /// <summary>
+        /// The constructor of Point class
+        /// </summary>
+        /// <param name="x">X-axis coordinate of the point in 2D space</param>
+        /// <param name="y">Y-axis coordinate of the point in 2D space</param>
+        /// <code>
+        /// 
+        /// </code>
+        public Point(int x, int y)
+        {
+            X = x;
+            Y = y;
+        }
+
+        /// <summary>
+        /// Gets X-axis coordinate of the point in 2D space
+        /// </summary>
+        public int X
+        {
+            get;
+            internal set;
+        }
+
+        /// <summary>
+        /// Gets Y-axis coordinate of the point in 2D space
+        /// </summary>
+        public int Y
+        {
+            get;
+            internal set;
+        }
+
+        internal new string ToString()
+        {
+            return string.Format("({0}, {1})", X, Y);
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/QrConfiguration.cs b/src/Tizen.Multimedia/MediaVision/QrConfiguration.cs
new file mode 100755 (executable)
index 0000000..8da6afd
--- /dev/null
@@ -0,0 +1,55 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents the configuration details for the QR code to be generated by BarcodeGenerator
+    /// </summary>
+    public class QrConfiguration
+    {
+        /// <summary>
+        /// The constructor of the QrConfig class
+        /// </summary>
+        /// <param name="qrMode">Encoding mode for the message (only for QR codes; for 1D barcodes set this parameter to Unavailable)</param>
+        /// <param name="ecc">Error correction level (only for QR codes; for 1D barcodes set this parameter to Unavailable)</param>
+        /// <param name="version">QR code version (for 1D barcodes set this parameter to 0)</param>
+        /// <code>
+        /// var obj = new QrConfiguration(QrMode.Numeric, ErrorCorrectionLevel.Medium, 30);
+        /// </code>
+        public QrConfiguration(QrMode qrMode, ErrorCorrectionLevel ecc, int version)
+        {
+            Mode = qrMode;
+            ErrorCorrectionLevel = ecc;
+            Version = version;
+        }
+
+        /// <summary>
+        /// Gets encoding mode for the message (only for QR codes; for 1D barcodes set this value to Unavailable)
+        /// </summary>
+        public QrMode Mode { get; }
+
+        /// <summary>
+        /// Gets error correction level (only for QR codes; for 1D barcodes set this value to Unavailable)
+        /// </summary>
+        public ErrorCorrectionLevel ErrorCorrectionLevel { get; }
+
+        /// <summary>
+        /// Gets QR code version (for 1D barcodes set this value to 0)
+        /// </summary>
+        public int Version { get; }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/QrMode.cs b/src/Tizen.Multimedia/MediaVision/QrMode.cs
new file mode 100755 (executable)
index 0000000..ca644d4
--- /dev/null
@@ -0,0 +1,45 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration for supported QR code encoding mode.
+    /// </summary>
+    public enum QrMode
+    {
+        /// <summary>
+        /// Numeric digits
+        /// </summary>
+        Numeric,
+        /// <summary>
+        /// Alphanumeric characters
+        /// </summary>
+        AlphaNumeric,
+        /// <summary>
+        /// Raw 8-bit bytes
+        /// </summary>
+        Byte,
+        /// <summary>
+        /// UTF-8 character encoding
+        /// </summary>
+        Utf8,
+        /// <summary>
+        /// Unavailable
+        /// </summary>
+        Unavailable
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/Quadrangle.cs b/src/Tizen.Multimedia/MediaVision/Quadrangle.cs
new file mode 100755 (executable)
index 0000000..246e4f4
--- /dev/null
@@ -0,0 +1,56 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents location of the object bounded by quadrangle defined by four 2D points.
+    /// </summary>
+    public class Quadrangle
+    {
+        internal Quadrangle()
+        {
+
+        }
+
+        /// <summary>
+        /// The constructor of the Quadrangle class
+        /// </summary>
+        /// <param name="points">four points that define object bounding quadrangle</param>
+        public Quadrangle(Point[] points)
+        {
+            if (points.Length != 4)
+            {
+                throw new ArgumentException("Invalid parameter");
+            }
+
+            Points = points;
+        }
+
+        /// <summary>
+        /// Gets four points that define object bounding quadrangle
+        /// </summary>
+        public Point[] Points { get; internal set; }
+
+        internal new string ToString()
+        {
+            return string.Format("[{0}, {1}, {2}, {3}]", Points[0].ToString(), Points[1].ToString(),
+                Points[2].ToString(), Points[3].ToString());
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/Rectangle.cs b/src/Tizen.Multimedia/MediaVision/Rectangle.cs
new file mode 100755 (executable)
index 0000000..fead617
--- /dev/null
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents location of the object bounded by rectangle defined by
+    /// coordinates of top left corner, width and height.
+    /// </summary>
+    public class Rectangle
+    {
+        internal Rectangle()
+        {
+        }
+
+        /// <summary>
+        /// The constructor of the Rectangle class
+        /// </summary>
+        /// <param name="point">Top left corner of rectangle coordinates</param>
+        /// <param name="width">Width of the bounding rectangle</param>
+        /// <param name="height">Height of the bounding rectangle</param>
+        /// <code>
+        /// 
+        /// </code>
+        public Rectangle(Point point, int width, int height)
+        {
+            Point = point;
+            Width = width;
+            Height = height;
+        }
+
+        /// <summary>
+        /// Gets top left corner of rectangle coordinates
+        /// </summary>
+        public Point Point { get; internal set; }
+
+        /// <summary>
+        /// Gets width of the bounding rectangle
+        /// </summary>
+        public int Width { get; internal set; }
+
+        /// <summary>
+        /// Gets height of the bounding rectangle
+        /// </summary>
+        public int Height { get; internal set; }
+
+        internal new string ToString()
+        {
+            return string.Format("Point : [{0}, {1}], Width : {2}, Height : {3}", Point.ToString(), Width, Height);
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/SurveillanceEngineConfiguration.cs b/src/Tizen.Multimedia/MediaVision/SurveillanceEngineConfiguration.cs
new file mode 100755 (executable)
index 0000000..05b09dc
--- /dev/null
@@ -0,0 +1,107 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents concrete EngineConfig for creation of video surveillance systems.
+    /// </summary>
+    public class SurveillanceEngineConfiguration : EngineConfiguration
+    {
+        private const string _faceRecognitionModelFilePathKey = "MV_SURVEILLANCE_FACE_RECOGNITION_MODEL_FILE_PATH";
+        private const string _movementDetectionThresholdKey = "MV_SURVEILLANCE_MOVEMENT_DETECTION_THRESHOLD";
+        private const string _skipFramesCountKey = "MV_SURVEILLANCE_SKIP_FRAMES_COUNT";
+        private string _faceRecognitionModelFilePathValue;
+        private int _movementDetectionThresholdValue = 10;
+        private int _skipFramesCountValue = 0;
+
+        /// <summary>
+        /// The default constructor of SurveillanceEngineConfiguration class
+        /// </summary>
+        /// <code>
+        /// 
+        /// </code>
+        public SurveillanceEngineConfiguration()
+            : base()
+        {
+        }
+
+        /// <summary>
+        /// Sets and gets face recognition model file path.\n
+        /// This value HAS TO BE set in engine configuration before subscribing on PersonRecognized event trigger.
+        /// </summary>
+        public string FaceRecognitionModelFilePath
+        {
+            get
+            {
+                return _faceRecognitionModelFilePathValue;
+            }
+
+            set
+            {
+                Add<string>(_faceRecognitionModelFilePathKey, value);
+                _faceRecognitionModelFilePathValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets movement detection threshold.\n
+        /// This value might be set in engine configuration before subscription on MovementDetected event trigger to specify sensitivity of the movement
+        /// detector. This value has to be integer in 0..255 range where 255 means that no movements will be detected, and 0 means that all frame changes
+        /// will be interpreted as movements. Default value is 10.
+        /// </summary>
+        public int MovementDetectionThreshold
+        {
+            get
+            {
+                return _movementDetectionThresholdValue;
+            }
+
+            set
+            {
+                if (value < 0 || value > 255)
+                {
+                    throw new ArgumentException("Invalid value");
+                }
+
+                Add<int>(_movementDetectionThresholdKey, value);
+                _movementDetectionThresholdValue = value;
+            }
+        }
+
+        /// <summary>
+        /// Sets and gets how many frames will be skipped during push source.\n
+        /// This integer value might be set in engine configuration to specify number of PushSource() function calls will be ignored by subscription
+        /// of the event trigger. Default value is 0. It means that no frames will be skipped and all mv_surveillance_push_source() function calls will
+        /// be processed.
+        /// </summary>
+        public int SkipFramesCount
+        {
+            get
+            {
+                return _skipFramesCountValue;
+            }
+
+            set
+            {
+                Add<int>(_skipFramesCountKey, value);
+                _skipFramesCountValue = value;
+            }
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/SurveillanceEventTrigger.cs b/src/Tizen.Multimedia/MediaVision/SurveillanceEventTrigger.cs
new file mode 100755 (executable)
index 0000000..47e570a
--- /dev/null
@@ -0,0 +1,430 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using System;
+using System.Collections.Generic;
+using System.Runtime.InteropServices;
+using static Interop.MediaVision;
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// This class represents an abstract Surveillance Event Trigger.
+    /// Media Vision Surveillance provides functionality can be utilized for creation of video surveillance systems.
+    /// The main idea underlying surveillance is event subscription model. These events can be added to the concrete
+    /// surveillance vent trigger classes.
+    /// </summary>
+    public abstract class SurveillanceEventTrigger : IDisposable
+    {
+        internal const string MovementDetectedType = "MV_SURVEILLANCE_EVENT_MOVEMENT_DETECTED";
+        internal const string PersonAppearanceChangedType = "MV_SURVEILLANCE_EVENT_PERSON_APPEARED_DISAPEARED";
+        internal const string PersonRecognizedType = "MV_SURVEILLANCE_EVENT_PERSON_RECOGNIZED";
+
+        private const string _movementNumberOfRegionsKey = "NUMBER_OF_MOVEMENT_REGIONS";
+        private const string _movementRegionsKey = "MOVEMENT_REGIONS";
+
+        private const string _personsRecognizedNumberKey = "NUMBER_OF_PERSONS";
+        private const string _personsRecognizedLocationsKey = "PERSONS_LOCATIONS";
+        private const string _personsRecognizedLabelsKey = "PERSONS_LABELS";
+        private const string _personsRecognizedConfidencesKey = "PERSONS_CONFIDENCES";
+
+        private const string _personsAppearedNumber = "NUMBER_OF_APPEARED_PERSONS";
+        private const string _personsDisappearedNumber = "NUMBER_OF_DISAPPEARED_PERSONS";
+        private const string _personsTrackedNumber = "NUMBER_OF_TRACKED_PERSONS";
+        private const string _personsAppearedLocations = "APPEARED_PERSONS_LOCATIONS";
+        private const string _personsDisappearedLocations = "DISAPPEARED_PERSONS_LOCATIONS";
+        private const string _personsTrackedLocations = "TRACKED_PERSONS_LOCATIONS";
+
+        internal IntPtr _eventTriggerHandle = IntPtr.Zero;
+        private string _eventTriggerType;
+        private bool _disposed = false;
+
+        internal event EventHandler<PersonRecognizedEventArgs> PersonRecognizedEvent;
+        internal event EventHandler<PersonAppearanceChangedEventArgs> PersonAppearanceChangedEvent;
+        internal event EventHandler<MovementDetectedEventArgs> MovementDetectedEvent;
+
+        /// <summary>
+        /// Constructor of the SurveillanceEventTrigger class.
+        /// </summary>
+        /// <param name="eventType">The type of the event trigger</param>
+        internal SurveillanceEventTrigger(string eventType)
+        {
+            _eventTriggerType = eventType;
+            int ret = Interop.MediaVision.Surveillance.EventTriggerCreate(eventType, out _eventTriggerHandle);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to create surveillance event trigger.");
+        }
+
+        /// <summary>
+        /// Destructor of the SurveillanceEventTrigger class.
+        /// </summary>
+        ~SurveillanceEventTrigger()
+        {
+            Dispose(false);
+        }
+
+        /// <summary>
+        /// Sets and gets ROI (Region Of Interest) to the event trigger
+        /// </summary>
+        public List<Point> Roi
+        {
+            get
+            {
+                int count;
+                IntPtr roiPtr;
+                int ret = Interop.MediaVision.Surveillance.GetEventTriggerRoi(_eventTriggerHandle, out count, out roiPtr);
+                if (ret != 0)
+                {
+                    Tizen.Log.Error(MediaVisionLog.Tag, "Failed to get roi");
+                    return null;
+                }
+
+                IntPtr[] pointsPtr = new IntPtr[count];
+                Marshal.Copy(roiPtr, pointsPtr, 0, count);
+
+                List<Point> points = new List<Point>();
+                for (int i = 0; i < count; i++)
+                {
+                    Interop.MediaVision.Point roi = (Interop.MediaVision.Point)Marshal.PtrToStructure(pointsPtr[i], typeof(Interop.MediaVision.Point));
+                    points.Add(new Point()
+                    {
+                        X = roi.x,
+                        Y = roi.y
+                    });
+                }
+
+                return points;
+            }
+
+            set
+            {
+                if (value.Count == 0)
+                {
+                    throw new ArgumentException("Invalid array");
+                }
+
+                IntPtr[] ptrArray = new IntPtr[value.Count];
+                for (int i = 0; i < value.Count; i++)
+                {
+                    if (value[i] == null)
+                    {
+                        throw new ArgumentException("Invalid parameter");
+                    }
+
+                    Interop.MediaVision.Point point = new Interop.MediaVision.Point()
+                    {
+                        x = value[i].X,
+                        y = value[i].Y
+                    };
+
+                    IntPtr ptr = Marshal.AllocHGlobal(Marshal.SizeOf(point));
+                    Marshal.StructureToPtr(point, ptr, false);
+                    ptrArray[i] = ptr;
+                }
+
+                int size = Marshal.SizeOf(typeof(IntPtr)) * ptrArray.Length;
+                IntPtr roiPtr = Marshal.AllocHGlobal(size);
+                Marshal.Copy(ptrArray, 0, roiPtr, ptrArray.Length);
+
+                int ret = Interop.MediaVision.Surveillance.SetEventTriggerRoi(_eventTriggerHandle, value.Count, roiPtr);
+                MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to set roi");
+            }
+        }
+
+        /// <summary>
+        /// Subscribes trigger to process sources pushed from video identified by @a videoStreamId.
+        /// </summary>
+        /// <param name="videoStreamId">The identifier of the video stream for which event trigger activation will be checked</param>
+        /// <param name="config">The engine configuration of the event</param>
+        /// <code>
+        ///
+        /// </code>
+        public void Subscribe(int videoStreamId, SurveillanceEngineConfiguration config = null)
+        {
+            Interop.MediaVision.Surveillance.MvSurveillanceEventOccurredCallback eventOccurredCb = (IntPtr trigger, IntPtr source, int streamId, IntPtr eventResult, IntPtr userData) =>
+            {
+                Tizen.Log.Info(MediaVisionLog.Tag, string.Format("Surveillance event occurred, video stream id : {0}", streamId));
+                if (eventResult != null)
+                {
+                    if (string.Equals(_eventTriggerType, MovementDetectedType))
+                    {
+                        MovementDetectedEventArgs e = GetMovementDetectedEventArgs(eventResult, streamId);
+                        MovementDetectedEvent?.Invoke(null, e);
+                    }
+                    else if (string.Equals(_eventTriggerType, PersonRecognizedType))
+                    {
+                        PersonRecognizedEventArgs e = GetPersonRecognizedEventArgs(eventResult, streamId);
+                        PersonRecognizedEvent?.Invoke(null, e);
+                    }
+                    else if (string.Equals(_eventTriggerType, PersonAppearanceChangedType))
+                    {
+                        PersonAppearanceChangedEventArgs e = GetPersonAppearanceChangedEventArgs(eventResult, streamId);
+                        PersonAppearanceChangedEvent?.Invoke(null, e);
+                    }
+                }
+            };
+
+            int ret = Interop.MediaVision.Surveillance.SubscribeEventTrigger(_eventTriggerHandle, videoStreamId, (config != null) ? config._engineHandle : IntPtr.Zero, eventOccurredCb, IntPtr.Zero);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to subscribe trigger");
+        }
+
+        /// <summary>
+        /// Unsubscribes trigger from the event
+        /// </summary>
+        /// <param name="videoStreamId">The identifier of the video source for which subscription will be stopped</param>
+        /// <code>
+        ///
+        /// </code>
+        public void Unsubscribe(int videoStreamId)
+        {
+            int ret = Interop.MediaVision.Surveillance.UnsubscribeEventTrigger(_eventTriggerHandle, videoStreamId);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to unsubscribe event trigger");
+        }
+
+        /// <summary>
+        /// Pushes source to the surveillance system to detect events.
+        /// </summary>
+        /// <param name="source">The media source</param>
+        /// <param name="videoStreamId">The identifier of video stream from which @a source is coming</param>
+        /// <code>
+        ///
+        /// </code>
+        public void PushSource(MediaVisionSource source, int videoStreamId)
+        {
+            if (source == null)
+            {
+                throw new ArgumentException("Invalid source");
+            }
+
+            int ret = Interop.MediaVision.Surveillance.PushSource(source._sourceHandle, videoStreamId);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to push source");
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object.
+        /// </summary>
+        public void Dispose()
+        {
+            Dispose(true);
+            GC.SuppressFinalize(this);
+        }
+
+        /// <summary>
+        /// Releases any unmanaged resources used by this object. Can also dispose any other disposable objects.
+        /// </summary>
+        /// <param name="disposing">If true, disposes any disposable objects. If false, does not dispose disposable objects.</param>
+        protected virtual void Dispose(bool disposing)
+        {
+            if (_disposed)
+            {
+                return;
+            }
+
+            if (disposing)
+            {
+                // Free managed objects
+            }
+
+            Interop.MediaVision.Surveillance.EventTriggerDestroy(_eventTriggerHandle);
+            _disposed = true;
+        }
+
+        private MovementDetectedEventArgs GetMovementDetectedEventArgs(IntPtr handle, int videoStreamId)
+        {
+            int count;
+            IntPtr resultPtr = IntPtr.Zero;
+            List<Rectangle> regions = new List<Rectangle>();
+
+            int ret = Interop.MediaVision.Surveillance.GetResultCount(handle, _movementNumberOfRegionsKey, out count);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result count");
+
+            resultPtr = Marshal.AllocHGlobal(Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)) * count);
+            ret = Interop.MediaVision.Surveillance.GetResultValue(handle, _movementRegionsKey, resultPtr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result");
+
+            for (int i = 0; i < count; i++)
+            {
+                Interop.MediaVision.Rectangle rect = (Interop.MediaVision.Rectangle)Marshal.PtrToStructure(resultPtr, typeof(Interop.MediaVision.Rectangle));
+                regions.Add(new Rectangle()
+                {
+                    Point = new Point()
+                    {
+                        X = rect.x,
+                        Y = rect.y
+                    },
+                    Width = rect.width,
+                    Height = rect.height
+                });
+                resultPtr = IntPtr.Add(resultPtr, Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)));
+            }
+
+            MovementDetectedEventArgs e = new MovementDetectedEventArgs()
+            {
+                VideoStreamId = videoStreamId,
+                Regions = regions
+            };
+
+            return e;
+        }
+
+        private PersonRecognizedEventArgs GetPersonRecognizedEventArgs(IntPtr handle, int videoStreamId)
+        {
+            int count;
+            List<PersonRecognitionResult> result = new List<PersonRecognitionResult>();
+
+            int ret = Interop.MediaVision.Surveillance.GetResultCount(handle, _personsRecognizedNumberKey, out count);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result count");
+
+            IntPtr locationPtr = Marshal.AllocHGlobal(Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)) * count);
+            ret = Interop.MediaVision.Surveillance.GetResultValue(handle, _personsRecognizedLocationsKey, locationPtr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get location");
+
+            IntPtr labelPtr = Marshal.AllocHGlobal(sizeof(int) * count);
+            ret = Interop.MediaVision.Surveillance.GetResultValue(handle, _personsRecognizedLabelsKey, labelPtr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get label");
+            int[] labelsArray = new int[count];
+            Marshal.Copy(labelPtr, labelsArray, 0, count);
+
+            IntPtr confidencePtr = Marshal.AllocHGlobal(sizeof(double) * count);
+            ret = Interop.MediaVision.Surveillance.GetResultValue(handle, _personsRecognizedConfidencesKey, confidencePtr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get confidence");
+            double[] confidencesArray = new double[count];
+            Marshal.Copy(confidencePtr, confidencesArray, 0, count);
+
+            for (int i = 0; i < count; i++)
+            {
+                Interop.MediaVision.Rectangle rect = (Interop.MediaVision.Rectangle)Marshal.PtrToStructure(locationPtr, typeof(Interop.MediaVision.Rectangle));
+                Rectangle location = new Rectangle()
+                {
+                    Point = new Point()
+                    {
+                        X = rect.x,
+                        Y = rect.y
+                    },
+                    Width = rect.width,
+                    Height = rect.height
+                };
+
+                result.Add(new PersonRecognitionResult()
+                {
+                    Location = location,
+                    Label = labelsArray[i],
+                    Confidence = confidencesArray[i]
+                });
+
+                locationPtr = IntPtr.Add(locationPtr, Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)));
+            }
+
+            PersonRecognizedEventArgs e = new PersonRecognizedEventArgs()
+            {
+                VideoStreamId = videoStreamId,
+                Result = result
+            };
+
+            return e;
+        }
+
+        private PersonAppearanceChangedEventArgs GetPersonAppearanceChangedEventArgs(IntPtr handle, int videoStreamId)
+        {
+            int numOfAppearedPersons, numOfDisappearedPersons, numOfTrackedPersons;
+
+            List<Rectangle> appearedLocations = new List<Rectangle>();
+            List<Rectangle> disappearedLocations = new List<Rectangle>();
+            List<Rectangle> trackedLocations = new List<Rectangle>();
+
+            int ret = Interop.MediaVision.Surveillance.GetResultCount(handle, _personsAppearedNumber, out numOfAppearedPersons);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result");
+
+            IntPtr appearedLocationPtr = Marshal.AllocHGlobal(Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)) * numOfAppearedPersons);
+            ret = Interop.MediaVision.Surveillance.GetResultValue(handle, _personsAppearedLocations, appearedLocationPtr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result");
+
+            for (int i = 0; i < numOfAppearedPersons; i++)
+            {
+                Interop.MediaVision.Rectangle rect = (Interop.MediaVision.Rectangle)Marshal.PtrToStructure(appearedLocationPtr, typeof(Interop.MediaVision.Rectangle));
+                appearedLocations.Add(new Rectangle()
+                {
+                    Point = new Point()
+                    {
+                        X = rect.x,
+                        Y = rect.y
+                    },
+                    Width = rect.width,
+                    Height = rect.height
+                });
+
+                appearedLocationPtr = IntPtr.Add(appearedLocationPtr, Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)));
+            }
+
+            ret = Interop.MediaVision.Surveillance.GetResultCount(handle, _personsDisappearedNumber, out numOfDisappearedPersons);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result");
+
+            IntPtr disAppearedLocationPtr = Marshal.AllocHGlobal(Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)) * numOfDisappearedPersons);
+            ret = Interop.MediaVision.Surveillance.GetResultValue(handle, _personsDisappearedLocations, disAppearedLocationPtr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result");
+
+            for (int i = 0; i < numOfDisappearedPersons; i++)
+            {
+                Interop.MediaVision.Rectangle rect = (Interop.MediaVision.Rectangle)Marshal.PtrToStructure(disAppearedLocationPtr, typeof(Interop.MediaVision.Rectangle));
+                disappearedLocations.Add(new Rectangle()
+                {
+                    Point = new Point()
+                    {
+                        X = rect.x,
+                        Y = rect.y
+                    },
+                    Width = rect.width,
+                    Height = rect.height
+                });
+
+                disAppearedLocationPtr = IntPtr.Add(disAppearedLocationPtr, Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)));
+            }
+
+            ret = Interop.MediaVision.Surveillance.GetResultCount(handle, _personsTrackedNumber, out numOfTrackedPersons);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result");
+
+            IntPtr trackedLocationPtr = Marshal.AllocHGlobal(Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)) * numOfTrackedPersons);
+            ret = Interop.MediaVision.Surveillance.GetResultValue(handle, _personsTrackedLocations, trackedLocationPtr);
+            MediaVisionErrorFactory.CheckAndThrowException(ret, "Failed to get result");
+
+            for (int i = 0; i < numOfTrackedPersons; i++)
+            {
+                Interop.MediaVision.Rectangle rect = (Interop.MediaVision.Rectangle)Marshal.PtrToStructure(trackedLocationPtr, typeof(Interop.MediaVision.Rectangle));
+                trackedLocations.Add(new Rectangle()
+                {
+                    Point = new Point()
+                    {
+                        X = rect.x,
+                        Y = rect.y
+                    },
+                    Width = rect.width,
+                    Height = rect.height
+                });
+
+                trackedLocationPtr = IntPtr.Add(trackedLocationPtr, Marshal.SizeOf(typeof(Interop.MediaVision.Rectangle)));
+            }
+
+            PersonAppearanceChangedEventArgs e = new PersonAppearanceChangedEventArgs()
+            {
+                VideoStreamId = videoStreamId,
+                AppearedLocations = appearedLocations,
+                DisappearedLocations = disappearedLocations,
+                TrackedLocations = trackedLocations
+            };
+
+            return e;
+        }
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/TargetAttribute.cs b/src/Tizen.Multimedia/MediaVision/TargetAttribute.cs
new file mode 100755 (executable)
index 0000000..6a36780
--- /dev/null
@@ -0,0 +1,41 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration to target attribute
+    /// </summary>
+    public enum TargetAttribute
+    {
+        /// <summary>
+        /// 1D and 2D
+        /// </summary>
+        All,
+        /// <summary>
+        /// 1D barcode only
+        /// </summary>
+        Barcode1D,
+        /// <summary>
+        /// 2D barcode only
+        /// </summary>
+        Barcode2D,
+        /// <summary>
+        /// Unavailable
+        /// </summary>
+        Unavailable
+    }
+}
diff --git a/src/Tizen.Multimedia/MediaVision/TextAttribute.cs b/src/Tizen.Multimedia/MediaVision/TextAttribute.cs
new file mode 100755 (executable)
index 0000000..1f43e0c
--- /dev/null
@@ -0,0 +1,37 @@
+/*
+ * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the License);
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an AS IS BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+namespace Tizen.Multimedia
+{
+    /// <summary>
+    /// Enumeration to text attribute
+    /// </summary>
+    public enum TextAttribute
+    {
+        /// <summary>
+        /// Invisible
+        /// </summary>
+        Invisible,
+        /// <summary>
+        /// Visible
+        /// </summary>
+        Visible,
+        /// <summary>
+        /// Unavailable
+        /// </summary>
+        Unavailable
+    }
+}
index 08354d2..6b1bbe2 100755 (executable)
     <Compile Include="Interop\Interop.MediaCodec.cs" />
     <Compile Include="Interop\Interop.MediaTool.cs" />
     <Compile Include="Interop\Interop.EvasObject.cs" />
+    <Compile Include="Interop\Interop.MediaVision.BarCode.cs" />
+    <Compile Include="Interop\Interop.MediaVision.Common.cs" />
+    <Compile Include="Interop\Interop.MediaVision.Face.cs" />
+    <Compile Include="Interop\Interop.MediaVision.Image.cs" />
+    <Compile Include="Interop\Interop.MediaVision.Surveillance.cs" />
     <Compile Include="Interop\Interop.Player.cs" />
        <Compile Include="MediaCodec\BufferStatusChangedEventArgs.cs" />
     <Compile Include="MediaCodec\EosReachedEventArgs.cs" />
     <Compile Include="MediaTool\MediaToolDebug.cs" />
     <Compile Include="MediaTool\NotEnoughMemoryException.cs" />
     <Compile Include="MediaView\MediaView.cs" />
+    <Compile Include="MediaVision\Barcode.cs" />
+    <Compile Include="MediaVision\BarcodeDetector.cs" />
+    <Compile Include="MediaVision\BarcodeDetectorEngineConfiguration.cs" />
+    <Compile Include="MediaVision\BarcodeGenerator.cs" />
+    <Compile Include="MediaVision\BarcodeGeneratorEngineConfiguration.cs" />
+    <Compile Include="MediaVision\BarcodeImageConfiguration.cs" />
+    <Compile Include="MediaVision\BarcodeImageFormat.cs" />
+    <Compile Include="MediaVision\BarcodeType.cs" />
+    <Compile Include="MediaVision\Colorspace.cs" />
+    <Compile Include="MediaVision\EngineConfiguration.cs" />
+    <Compile Include="MediaVision\ErrorCorrectionLevel.cs" />
+    <Compile Include="MediaVision\EyeCondition.cs" />
+    <Compile Include="MediaVision\FaceDetectionResult.cs" />
+    <Compile Include="MediaVision\FaceDetector.cs" />
+    <Compile Include="MediaVision\FaceEngineConfiguration.cs" />
+    <Compile Include="MediaVision\FaceRecognitionModel.cs" />
+    <Compile Include="MediaVision\FaceRecognitionModelType.cs" />
+    <Compile Include="MediaVision\FaceRecognitionResult.cs" />
+    <Compile Include="MediaVision\FaceRecognizer.cs" />
+    <Compile Include="MediaVision\FaceTracker.cs" />
+    <Compile Include="MediaVision\FaceTrackingModel.cs" />
+    <Compile Include="MediaVision\FaceTrackingResult.cs" />
+    <Compile Include="MediaVision\FacialExpression.cs" />
+    <Compile Include="MediaVision\Image.cs" />
+    <Compile Include="MediaVision\ImageEngineConfiguration.cs" />
+    <Compile Include="MediaVision\ImageRecognitionResult.cs" />
+    <Compile Include="MediaVision\ImageRecognizer.cs" />
+    <Compile Include="MediaVision\ImageTracker.cs" />
+    <Compile Include="MediaVision\ImageTrackingModel.cs" />
+    <Compile Include="MediaVision\MediaVisionErrorFactory.cs" />
+    <Compile Include="MediaVision\MediaVisionSource.cs" />
+    <Compile Include="MediaVision\MovementDetectedEventArgs.cs" />
+    <Compile Include="MediaVision\MovementDetectionEventTrigger.cs" />
+    <Compile Include="MediaVision\PersonAppearanceChangedEventArgs.cs" />
+    <Compile Include="MediaVision\PersonAppearanceEventTrigger.cs" />
+    <Compile Include="MediaVision\PersonRecognitionEventTrigger.cs" />
+    <Compile Include="MediaVision\PersonRecognitionResult.cs" />
+    <Compile Include="MediaVision\PersonRecognizedEventArgs.cs" />
+    <Compile Include="MediaVision\Point.cs" />
+    <Compile Include="MediaVision\QrConfiguration.cs" />
+    <Compile Include="MediaVision\QrMode.cs" />
+    <Compile Include="MediaVision\Quadrangle.cs" />
+    <Compile Include="MediaVision\Rectangle.cs" />
+    <Compile Include="MediaVision\SurveillanceEngineConfiguration.cs" />
+    <Compile Include="MediaVision\SurveillanceEventTrigger.cs" />
+    <Compile Include="MediaVision\TargetAttribute.cs" />
+    <Compile Include="MediaVision\TextAttribute.cs" />
     <Compile Include="Player\PlayerEnums.cs" />
     <Compile Include="Player\MediaStreamConfiguration.cs" />
     <Compile Include="Player\SubtitleTrack.cs" />
index f1dbde6..946cb07 100755 (executable)
     <Compile Include="Interop\Interop.CameraSetting.cs" />
     <Compile Include="Interop\Interop.MediaCodec.cs" />
     <Compile Include="Interop\Interop.MediaTool.cs" />
+    <Compile Include="Interop\Interop.MediaVision.BarCode.cs" />
+    <Compile Include="Interop\Interop.MediaVision.Common.cs" />
+    <Compile Include="Interop\Interop.MediaVision.Face.cs" />
+    <Compile Include="Interop\Interop.MediaVision.Image.cs" />
+    <Compile Include="Interop\Interop.MediaVision.Surveillance.cs" />
     <Compile Include="Interop\Interop.Player.cs" />
     <Compile Include="Interop\Interop.MetadataExtractor.cs" />
     <Compile Include="MediaCodec\BufferStatusChangedEventArgs.cs" />
     <Compile Include="MediaTool\MediaPacketVideoPlane.cs" />
     <Compile Include="MediaTool\MediaToolDebug.cs" />
     <Compile Include="MediaTool\NotEnoughMemoryException.cs" />
+    <Compile Include="MediaVision\Barcode.cs" />
+    <Compile Include="MediaVision\BarcodeDetector.cs" />
+    <Compile Include="MediaVision\BarcodeDetectorEngineConfiguration.cs" />
+    <Compile Include="MediaVision\BarcodeGenerator.cs" />
+    <Compile Include="MediaVision\BarcodeGeneratorEngineConfiguration.cs" />
+    <Compile Include="MediaVision\BarcodeImageConfiguration.cs" />
+    <Compile Include="MediaVision\BarcodeImageFormat.cs" />
+    <Compile Include="MediaVision\BarcodeType.cs" />
+    <Compile Include="MediaVision\Colorspace.cs" />
+    <Compile Include="MediaVision\EngineConfiguration.cs" />
+    <Compile Include="MediaVision\ErrorCorrectionLevel.cs" />
+    <Compile Include="MediaVision\EyeCondition.cs" />
+    <Compile Include="MediaVision\FaceDetectionResult.cs" />
+    <Compile Include="MediaVision\FaceDetector.cs" />
+    <Compile Include="MediaVision\FaceEngineConfiguration.cs" />
+    <Compile Include="MediaVision\FaceRecognitionModel.cs" />
+    <Compile Include="MediaVision\FaceRecognitionModelType.cs" />
+    <Compile Include="MediaVision\FaceRecognitionResult.cs" />
+    <Compile Include="MediaVision\FaceRecognizer.cs" />
+    <Compile Include="MediaVision\FaceTracker.cs" />
+    <Compile Include="MediaVision\FaceTrackingModel.cs" />
+    <Compile Include="MediaVision\FaceTrackingResult.cs" />
+    <Compile Include="MediaVision\FacialExpression.cs" />
+    <Compile Include="MediaVision\Image.cs" />
+    <Compile Include="MediaVision\ImageEngineConfiguration.cs" />
+    <Compile Include="MediaVision\ImageRecognitionResult.cs" />
+    <Compile Include="MediaVision\ImageRecognizer.cs" />
+    <Compile Include="MediaVision\ImageTracker.cs" />
+    <Compile Include="MediaVision\ImageTrackingModel.cs" />
+    <Compile Include="MediaVision\MediaVisionErrorFactory.cs" />
+    <Compile Include="MediaVision\MediaVisionSource.cs" />
+    <Compile Include="MediaVision\MovementDetectedEventArgs.cs" />
+    <Compile Include="MediaVision\MovementDetectionEventTrigger.cs" />
+    <Compile Include="MediaVision\PersonAppearanceChangedEventArgs.cs" />
+    <Compile Include="MediaVision\PersonAppearanceEventTrigger.cs" />
+    <Compile Include="MediaVision\PersonRecognitionEventTrigger.cs" />
+    <Compile Include="MediaVision\PersonRecognitionResult.cs" />
+    <Compile Include="MediaVision\PersonRecognizedEventArgs.cs" />
+    <Compile Include="MediaVision\Point.cs" />
+    <Compile Include="MediaVision\QrConfiguration.cs" />
+    <Compile Include="MediaVision\QrMode.cs" />
+    <Compile Include="MediaVision\Quadrangle.cs" />
+    <Compile Include="MediaVision\Rectangle.cs" />
+    <Compile Include="MediaVision\SurveillanceEngineConfiguration.cs" />
+    <Compile Include="MediaVision\SurveillanceEventTrigger.cs" />
+    <Compile Include="MediaVision\TargetAttribute.cs" />
+    <Compile Include="MediaVision\TextAttribute.cs" />
     <Compile Include="MetadataExtractor\MetadataEnums.cs" />
     <Compile Include="MetadataExtractor\MetadataExtractorErrorFactory.cs" />
     <Compile Include="MetadataExtractor\Synclyrics.cs" />