[Recorder] Change recorder feature (#32)
[platform/core/csapi/tizenfx.git] / src / Tizen.Multimedia.Recorder / Recorder / VideoRecorder.Capabilities.cs
index 7f1d3e0..0194cf5 100644 (file)
@@ -23,6 +23,7 @@ using NativeHandle = Interop.RecorderHandle;
 
 namespace Tizen.Multimedia
 {
+    /// <since_tizen> 4 </since_tizen>
     public partial class VideoRecorder
     {
         private static IEnumerable<Size> _frontResolutions;
@@ -46,6 +47,11 @@ namespace Tizen.Multimedia
 
         private static IEnumerable<Size> LoadVideoResolutions(CameraDevice device)
         {
+            if (!Features.IsSupported(RecorderFeatures.VideoRecorder))
+            {
+                throw new NotSupportedException("Video Recorder is not supported.");
+            }
+
             using (var camera = new Camera(device))
             {
                 Native.CreateVideo(camera.Handle, out var handle).ThrowIfError("Failed to get the resolutions");
@@ -60,10 +66,11 @@ namespace Tizen.Multimedia
         /// <summary>
         /// Gets the video resolutions that the current device supports.
         /// </summary>
-        /// <feature>http://tizen.org/feature/camera</feature>
+        /// <feature>http://tizen.org/feature/media.video_recording</feature>
         /// <param name="device">The camera device to retrieve the supported resolutions.</param>
         /// <exception cref="NotSupportedException">A required feature is not supported.</exception>
         /// <exception cref="ArgumentException"><paramref name="device"/> is invalid.</exception>
+        /// <since_tizen> 4 </since_tizen>
         public static IEnumerable<Size> GetSupportedVideoResolutions(CameraDevice device)
         {
             ValidationUtil.ValidateEnum(typeof(CameraDevice), device, nameof(device));
@@ -86,8 +93,9 @@ namespace Tizen.Multimedia
         /// <summary>
         /// Gets the video encoders that the current device supports.
         /// </summary>
-        /// <feature>http://tizen.org/feature/camera</feature>
+        /// <feature>http://tizen.org/feature/media.video_recording</feature>
         /// <exception cref="NotSupportedException">A required feature is not supported.</exception>
+        /// <since_tizen> 4 </since_tizen>
         public static IEnumerable<RecorderVideoCodec> GetSupportedVideoCodecs()
             => Capabilities.Value.SupportedVideoCodecs ?? throw new NotSupportedException("Video recording is not supported.");