private bool _audioEnabled;
private bool _videoEnabled;
private StreamRecorderVideoFormat _sourceFormat;
+ private const string Feature = "http://tizen.org/feature/multimedia.stream_recorder";
+
+ private static bool IsSupported()
+ {
+ return System.Information.TryGetValue(Feature, out bool isSupported) && isSupported;
+ }
/// <summary>
/// Initialize a new instance of the <see cref="StreamRecorder"/> class.
/// </summary>
/// <exception cref="NotSupportedException">The feature is not supported.</exception>
/// <since_tizen> 3 </since_tizen>
+ /// <feature> http://tizen.org/feature/multimedia.stream_recorder </feature>
public StreamRecorder()
{
+ if (IsSupported() == false)
+ {
+ throw new NotSupportedException(
+ $"The feature({Feature}) is not supported on the current device.");
+ }
+
try
{
Native.Create(out _handle).ThrowIfError("Failed to create stream recorder.");