Class MediaPacketSource

Definition

Namespace:
Tizen.Multimedia.Remoting
Assembly:
Tizen.Multimedia.Remoting.dll

Represents a media packet source.

C#
Copy
public sealed class MediaPacketSource : MediaSource
Inheritance
object
MediaPacketSource

Constructors

View Source

MediaPacketSource(AudioMediaFormat)

Initializes a new instance of the MediaPacketSource class with the specified AudioMediaFormat.

Declaration
C#
Copy
public MediaPacketSource(AudioMediaFormat audioMediaFormat)
Parameters
Type Name Description
AudioMediaFormat audioMediaFormat

The AudioMediaFormat for this source.

Exceptions
Type Condition
System.ArgumentNullException

audioMediaFormat is null.

System.ArgumentException

audioMediaFormat is not supported.

View Source

MediaPacketSource(VideoMediaFormat)

Initializes a new instance of the MediaPacketSource class with the specified VideoMediaFormat.

Declaration
C#
Copy
public MediaPacketSource(VideoMediaFormat videoMediaFormat)
Parameters
Type Name Description
VideoMediaFormat videoMediaFormat

The VideoMediaFormat for this source.

Exceptions
Type Condition
System.ArgumentNullException

videoMediaFormat is null.

System.ArgumentException

videoMediaFormat is not supported.

Properties

View Source

AudioConfiguration

Gets the audio configuration, or null if no AudioMediaFormat is specified in the constructor.

Declaration
C#
Copy
public MediaPacketSourceConfiguration AudioConfiguration { get; }
Property Value
Type Description
MediaPacketSourceConfiguration
View Source

SupportedAudioTypes

Gets all supported audio types.

Declaration
C#
Copy
public static IEnumerable<MediaFormatAudioMimeType> SupportedAudioTypes { get; }
Property Value
Type Description
System.Collections.Generic.IEnumerable<T><MediaFormatAudioMimeType>
View Source

SupportedVideoTypes

Gets all supported video types.

Declaration
C#
Copy
public static IEnumerable<MediaFormatVideoMimeType> SupportedVideoTypes { get; }
Property Value
Type Description
System.Collections.Generic.IEnumerable<T><MediaFormatVideoMimeType>
View Source

VideoConfiguration

Gets the video configuration, or null if no VideoMediaFormat is specified in the constructor.

Declaration
C#
Copy
public MediaPacketSourceConfiguration VideoConfiguration { get; }
Property Value
Type Description
MediaPacketSourceConfiguration

Methods

View Source

Push(MediaPacket)

Pushes elementary stream to decode audio or video.

Declaration
C#
Copy
public void Push(MediaPacket packet)
Parameters
Type Name Description
MediaPacket packet

The MediaPacket to decode.

Remarks

This source must be set as a source to a WebRTC and the WebRTC must be in the Negotiating or Playing state

Exceptions
Type Condition
System.InvalidOperationException

This source is not set as a source to a WebRTC.
-or-
The WebRTC is not in the valid state.

System.ArgumentNullException

packet is null.

System.ObjectDisposedException

packet has been disposed.

System.ArgumentException

packet is neither video nor audio type.
-or-
The format of packet is not matched with the specified format in the constructor.

See Also