* limitations under the License.
*/
using System;
+using System.Threading;
using Tizen.Internals.Errors;
namespace Tizen.Multimedia
/// </summary>
/// <seealso cref="Player.ErrorOccurred"/>
/// <seealso cref="PlayerErrorOccurredEventArgs"/>
+ /// <since_tizen> 3 </since_tizen>
public enum PlayerError
{
+ /// <summary>
+ /// File does not exists.
+ /// </summary>
NoSuchFile = ErrorCode.NoSuchFile,
+
+ /// <summary>
+ /// Internal error.
+ /// </summary>
InternalError = ErrorCode.InvalidOperation,
+
+ /// <summary>
+ /// No space.
+ /// </summary>
NoSpaceOnDevice = PlayerErrorCode.NoSpaceOnDevice,
- FeatureNotSupported = ErrorCode.NotSupported,
- PermissionDenied = ErrorCode.PermissionDenied,
+
+ /// <summary>
+ /// Not enough buffer.
+ /// </summary>
BufferSpace = ErrorCode.BufferSpace,
+
+ /// <summary>
+ /// <see cref="Player.SetPlayPositionAsync(int, bool)"/> failed.
+ /// </summary>
SeekFailed = PlayerErrorCode.SeekFailed,
+
+ /// <summary>
+ /// Invalid state.
+ /// </summary>
InvalidState = PlayerErrorCode.InvalidState,
+
+ /// <summary>
+ /// Not supported file.
+ /// </summary>
NotSupportedFile = PlayerErrorCode.NotSupportedFile,
+
+ /// <summary>
+ /// Invalid uri.
+ /// </summary>
InvalidUri = PlayerErrorCode.InvalidUri,
- SoundPolicy = PlayerErrorCode.SoundPolicyError,
+
+ /// <summary>
+ /// Connection to service failed.
+ /// </summary>
ConnectionFailed = PlayerErrorCode.ConnectionFailed,
- VideoCaptureFailed = PlayerErrorCode.VideoCaptureFailed,
- DrmExpired = PlayerErrorCode.DrmExpired,
- DrmNoLicense = PlayerErrorCode.DrmNoLicense,
- DrmFutureUse = PlayerErrorCode.DrmFutureUse,
+
+ /// <summary>
+ /// Not permitted DRM.
+ /// </summary>
DrmNotPermitted = PlayerErrorCode.DrmNotPermitted,
- ResourceLimit = PlayerErrorCode.ResourceLimit,
+
+ /// <summary>
+ /// Service disconnected.
+ /// </summary>
ServiceDisconnected = PlayerErrorCode.ServiceDisconnected,
+
+ /// <summary>
+ /// Not supported audio codec.
+ /// </summary>
+ /// <since_tizen> 4 </since_tizen>
+ AudioCodecNotSupported = PlayerErrorCode.NotSupportedAudioCodec,
+
+ /// <summary>
+ /// Not supported video codec.
+ /// </summary>
+ /// <since_tizen> 4 </since_tizen>
+ VideoCodecNotSupported = PlayerErrorCode.NotSupportedVideoCodec,
+
+ /// <summary>
+ /// Not supported subtitle file.
+ /// </summary>
SubtitleNotSupported = PlayerErrorCode.NotSupportedSubtitle,
}
/// <summary>
/// Specifies states that a <see cref="Player"/> can have.
/// </summary>
+ /// <since_tizen> 3 </since_tizen>
public enum PlayerState
{
/// <summary>
/// Initial state, unprepared.
/// </summary>
- /// <see cref="Player.Unprepare"/>
+ /// <seealso cref="Player.Unprepare"/>
Idle = 1,
/// <summary>
/// Prepared.
/// </summary>
- /// <see cref="Player.PrepareAsync"/>
+ /// <seealso cref="Player.PrepareAsync()"/>
+ /// <seealso cref="Player.PrepareAsync(CancellationToken)"/>
Ready,
/// <summary>
Paused,
/// <summary>
- /// Preparing in progress.
+ /// Preparation in progress.
/// </summary>
- /// <seealso cref="Player.PrepareAsync"/>/>
+ /// <remarks>In this state, other methods and properties cannot be set.</remarks>
+ /// <seealso cref="Player.PrepareAsync()"/>
+ /// <seealso cref="Player.PrepareAsync(CancellationToken)"/>
Preparing,
}
}
/// <summary>
- /// Specifies audio latency modes for <see cref="Player"/> .
+ /// Specifies audio latency modes for <see cref="Player"/>.
/// </summary>
/// <seealso cref="Player.AudioLatencyMode"/>
+ /// <since_tizen> 3 </since_tizen>
public enum AudioLatencyMode
{
/// <summary>
High,
}
-
- /// <summary>
- /// Specifies display rotation modes for <see cref="Player"/>.
- /// </summary>
- /// <seealso cref="Display.Rotation"/>
- public enum PlayerDisplayRotation
- {
- /// <summary>
- /// Display is not rotated
- /// </summary>
- RotationNone,
-
- /// <summary>
- /// Display is rotated 90 degrees
- /// </summary>
- Rotation90,
-
- /// <summary>
- /// Display is rotated 180 degrees
- /// </summary>
- Rotation180,
-
- /// <summary>
- /// Display is rotated 270 degrees
- /// </summary>
- Rotation270
- }
-
-
/// <summary>
- /// Specifies display modes for <see cref="Player"/>
+ /// Specifies display modes for <see cref="Player"/>.
/// </summary>
- /// <seealso cref="Display.Mode"/>
+ /// <seealso cref="PlayerDisplaySettings.Mode"/>
+ /// <since_tizen> 3 </since_tizen>
public enum PlayerDisplayMode
{
/// <summary>
CroppedFull,
/// <summary>
- /// Origin size (if surface size is larger than video size(width/height)) or
- /// Letter box (if video size(width/height) is larger than surface size).
+ /// Original size (if surface size is larger than video size(width/height)) or
+ /// letter box (if video size(width/height) is larger than surface size).
/// </summary>
OriginalOrFull,
/// <summary>
- /// Region of interest, See <see cref="Display.SetRoi(Rectangle)"/>.
+ /// Region of interest.
/// </summary>
+ /// <seealso cref="PlayerDisplaySettings.SetRoi(Rectangle)"/>
Roi
}
internal enum StreamType
{
/// <summary>
- /// Audio element stream type
+ /// Audio element stream type.
/// </summary>
Audio = 1,
/// <summary>
- /// Video element stream type
+ /// Video element stream type.
/// </summary>
Video,
/// <summary>
- /// Text type
+ /// Text type.
/// </summary>
Text
}
/// </summary>
/// <seealso cref="MediaStreamConfiguration.BufferStatusChanged"/>
/// <seealso cref="MediaStreamBufferStatusChangedEventArgs"/>
+ /// <since_tizen> 3 </since_tizen>
public enum MediaStreamBufferStatus
{
/// <summary>
/// Specifies the reason for the playback interruption.
/// </summary>
/// <seealso cref="Player.PlaybackInterrupted"/>
+ /// <since_tizen> 3 </since_tizen>
public enum PlaybackInterruptionReason
{
+ /// <summary>
+ /// Interrupted by a resource conflict and the <see cref="Player"/> will be unprepared automatically.
+ /// </summary>
ResourceConflict = 4
}
/// Specifies keys for the metadata.
/// </summary>
/// <seealso cref="StreamInfo.GetMetadata(StreamMetadataKey)"/>
+ /// <since_tizen> 3 </since_tizen>
public enum StreamMetadataKey
{
+ /// <summary>
+ /// Album.
+ /// </summary>
Album,
+
+ /// <summary>
+ /// Artists.
+ /// </summary>
Artist,
+
+ /// <summary>
+ /// Author.
+ /// </summary>
Author,
+
+ /// <summary>
+ /// Genre.
+ /// </summary>
Genre,
+
+ /// <summary>
+ /// Title.
+ /// </summary>
Title,
+
+ /// <summary>
+ /// Year.
+ /// </summary>
Year
}
+
+ /// <summary>
+ /// Enumeration of audio extract option.
+ /// </summary>
+ /// <seealso cref="Player.EnableExportingAudioData"/>
+ /// <since_tizen> 6 </since_tizen>
+ public enum PlayerAudioExtractOption
+ {
+ /// <summary>
+ /// Sync multi-channel audio stream with the playback clock.
+ /// </summary>
+ Default = 0x00,
+
+ /// <summary>
+ /// No sync with the playback clock.
+ /// </summary>
+ NoSyncWithClock = 0x01,
+
+ /// <summary>
+ /// Splits one interleaved multi-channel audio stream into several mono audio streams.
+ /// </summary>
+ Deinterleave = 0x02,
+
+ /// <summary>
+ /// Doesn't sync with clock and doesn't split multi-channel audio stream into several mono audio streams.
+ /// </summary>
+ NoSyncAndDeinterleave = 0x03,
+ }
+
+ /// <summary>
+ /// Specifies the types of a codec for <see cref="Player"/>.
+ /// </summary>
+ /// <seealso cref="Player.AudioCodecType"/>
+ /// <since_tizen> 6 </since_tizen>
+ public enum CodecType
+ {
+ /// <summary>
+ /// An optional flag for using the H/W codec.
+ /// </summary>
+ Hardware,
+
+ /// <summary>
+ /// An optional flag for using the S/W codec
+ /// </summary>
+ Software,
+ }
}