diff --git a/src/Tizen.Multimedia.MediaPlayer/Interop/Interop.Player.cs b/src/Tizen.Multimedia.MediaPlayer/Interop/Interop.Player.cs
index 585510fea2e..e48e2418f97 100644
--- a/src/Tizen.Multimedia.MediaPlayer/Interop/Interop.Player.cs
+++ b/src/Tizen.Multimedia.MediaPlayer/Interop/Interop.Player.cs
@@ -387,6 +387,12 @@ internal static extern PlayerErrorCode GetTrackLanguageCode(IntPtr player, Strea
[DllImport(Libraries.Player, EntryPoint = "player_get_audio_codec_type")]
internal static extern PlayerErrorCode GetAudioCodecType(IntPtr player, out CodecType type);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_set_video_codec_type")]
+ internal static extern PlayerErrorCode SetVideoCodecType(IntPtr player, CodecType type);
+
+ [DllImport(Libraries.Player, EntryPoint = "player_get_video_codec_type")]
+ internal static extern PlayerErrorCode GetVideoCodecType(IntPtr player, out CodecType type);
}
internal class PlayerHandle : SafeHandle
diff --git a/src/Tizen.Multimedia.MediaPlayer/Player/Player.Properties.cs b/src/Tizen.Multimedia.MediaPlayer/Player/Player.Properties.cs
index e180bb553dd..9decb5cab71 100644
--- a/src/Tizen.Multimedia.MediaPlayer/Player/Player.Properties.cs
+++ b/src/Tizen.Multimedia.MediaPlayer/Player/Player.Properties.cs
@@ -14,11 +14,7 @@
* limitations under the License.
*/
using System;
-using System.Threading.Tasks;
-using System.Runtime.InteropServices;
using System.Diagnostics;
-using System.IO;
-using System.Threading;
using NativeDisplay = Interop.Display;
using static Interop;
@@ -740,6 +736,48 @@ public CodecType AudioCodecType
}
}
+ ///
+ /// Gets or sets the codec type of the video decoder.
+ ///
+ /// A specifies the type.
+ /// The default codec type could be different depending on the device capability.
+ ///
+ /// To set, the player must be in the state.
+ /// If H/W video codec type is not supported in some cases, S/W video codec type could be used instead.
+ /// The availability could be changed depending on the codec capability.
+ ///
+ /// The player has already been disposed.
+ /// The value is not valid.
+ ///
+ /// The player is not in the valid state.
+ /// -or-
+ /// Operation failed; internal error.
+ ///
+ /// The selected codec is not supported.
+ /// 11
+ public CodecType VideoCodecType
+ {
+ get
+ {
+ ValidateNotDisposed();
+
+ NativePlayer.GetVideoCodecType(Handle, out var value).
+ ThrowIfFailed(this, "Failed to get the type of the video codec");
+
+ return value;
+ }
+ set
+ {
+ ValidateNotDisposed();
+ ValidatePlayerState(PlayerState.Idle);
+
+ ValidationUtil.ValidateEnum(typeof(CodecType), value, nameof(value));
+
+ NativePlayer.SetVideoCodecType(Handle, value).
+ ThrowIfFailed(this, "Failed to set the type of the video codec");
+ }
+ }
+
private SphericalVideo _sphericalVideo;
///
diff --git a/src/Tizen.Multimedia.MediaPlayer/Player/PlayerEnums.cs b/src/Tizen.Multimedia.MediaPlayer/Player/PlayerEnums.cs
index ac58ce4d22b..137fc1a5865 100644
--- a/src/Tizen.Multimedia.MediaPlayer/Player/PlayerEnums.cs
+++ b/src/Tizen.Multimedia.MediaPlayer/Player/PlayerEnums.cs
@@ -327,7 +327,6 @@ public enum PlayerAudioExtractOption
NoSyncAndDeinterleave = 0x03,
}
-
///
/// Specifies the types of a codec for .
///