Class RTPEvent
Inheritance
System.Object
RTPEvent
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: SIPSorcery.Net
Assembly: SIPSorcery.dll
Syntax
public class RTPEvent
Constructors
| Improve this Doc View SourceRTPEvent(Byte, Boolean, UInt16, UInt16, Int32)
Create a new RTP event object.
Declaration
public RTPEvent(byte eventID, bool endOfEvent, ushort volume, ushort totalDuration, int payloadTypeID)
Parameters
Type | Name | Description |
---|---|---|
System.Byte | eventID | The ID for the event. For a DTMF tone this is the digit/letter to represent. |
System.Boolean | endOfEvent | If true the end of event flag will be set. |
System.UInt16 | volume | The volume level to set. |
System.UInt16 | totalDuration | The event duration. |
System.Int32 | payloadTypeID | The ID of the event payload type. This gets set in the RTP header. |
RTPEvent(Byte[])
Extract and load an RTP Event from a packet buffer.
Declaration
public RTPEvent(byte[] packet)
Parameters
Type | Name | Description |
---|---|---|
System.Byte[] | packet | The packet buffer containing the RTP Event. |
Fields
| Improve this Doc View SourceDEFAULT_VOLUME
Declaration
public const ushort DEFAULT_VOLUME = 10
Field Value
Type | Description |
---|---|
System.UInt16 |
DTMF_PACKET_LENGTH
Declaration
public const int DTMF_PACKET_LENGTH = 4
Field Value
Type | Description |
---|---|
System.Int32 |
DUPLICATE_COUNT
Declaration
public const int DUPLICATE_COUNT = 3
Field Value
Type | Description |
---|---|
System.Int32 |
Properties
| Improve this Doc View SourceDuration
The duration of the current event payload. This value is set in the RTP event data payload.
Declaration
public ushort Duration { get; set; }
Property Value
Type | Description |
---|---|
System.UInt16 |
EndOfEvent
If true the end of event flag will be set.
Declaration
public bool EndOfEvent { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
EventID
The ID for the event. For a DTMF tone this is the digit/letter to represent.
Declaration
public byte EventID { get; }
Property Value
Type | Description |
---|---|
System.Byte |
PayloadTypeID
The ID of the event payload type. This gets set in the RTP header.
Declaration
public int PayloadTypeID { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
TotalDuration
The duration for the full event.
Declaration
public ushort TotalDuration { get; }
Property Value
Type | Description |
---|---|
System.UInt16 |
Volume
The volume level to set.
Declaration
public ushort Volume { get; }
Property Value
Type | Description |
---|---|
System.UInt16 |
Methods
| Improve this Doc View SourceGetEventPayload()
Gets the raw buffer for the event.
Declaration
public byte[] GetEventPayload()
Returns
Type | Description |
---|---|
System.Byte[] | A raw byte buffer for the event. |