class H323AudioCapability

This class describes the interface to an audio codec used to transfer data via the logical channels opened and managed by the H323 control channel.

Inheritance:


Public Methods

[more] Construction
[more] Identification functions
[more] Operations
[more] Protocol manipulation


Inherited from H323RealTimeCapability:


Inherited from H323Capability:

Public Methods

Overrides from class PObject

Member variable access

Protected Fields

oCapabilityDirection capabilityDirection


Documentation

This class describes the interface to an audio codec used to transfer data via the logical channels opened and managed by the H323 control channel.

An application may create a descendent off this class and override functions as required for descibing the codec.

o Construction

o H323AudioCapability( unsigned rxPacketSize, unsigned txPacketSize )
Create an audio based capability.
Parameters:
rxPacketSize - Maximum size of an audio packet in frames
txPacketSize - Desired transmit size of an audio packet frames

o Identification functions

ovirtual MainTypes GetMainType() const
Get the main type of the capability. Always returns e_Audio.

o Operations

ovirtual unsigned GetDefaultSessionID() const
Get the default RTP session. This function gets the default RTP session ID for the capability type. For example audio capabilities return the value RTP_Session::DefaultAudioSessionID etc.

The default behaviour returns zero, indicating it is not an RTP based capability.

ovirtual void SetTxFramesInPacket( unsigned frames )
Set the maximum size (in frames) of data that will be transmitted in a single PDU.

This will also be the desired number that will be sent by most codec implemetations.

The default behaviour sets the txFramesInPacket variable.

Parameters:
frames - Number of frames per packet

ovirtual unsigned GetTxFramesInPacket() const
Get the maximum size (in frames) of data that will be transmitted in a single PDU.

The default behaviour sends the txFramesInPacket variable.

ovirtual unsigned GetRxFramesInPacket() const
Get the maximum size (in frames) of data that can be received in a single PDU.

The default behaviour sends the rxFramesInPacket variable.

o Protocol manipulation

ovirtual BOOL OnSendingPDU( H245_Capability & pdu ) const
This function is called whenever and outgoing TerminalCapabilitySet PDU is being constructed for the control channel. It allows the capability to set the PDU fields from information in members specific to the class.

The default behaviour calls the OnSendingPDU() function with a more specific PDU type.

Parameters:
pdu - PDU to set information on

ovirtual BOOL OnSendingPDU( H245_DataType & pdu ) const
This function is called whenever and outgoing OpenLogicalChannel PDU is being constructed for the control channel. It allows the capability to set the PDU fields from information in members specific to the class.

The default behaviour calls the OnSendingPDU() function with a more specific PDU type.

Parameters:
pdu - PDU to set information on

ovirtual BOOL OnSendingPDU( H245_ModeElement & pdu ) const
This function is called whenever and outgoing RequestMode PDU is being constructed for the control channel. It allows the capability to set the PDU fields from information in members specific to the class.

The default behaviour calls the OnSendingPDU() function with a more specific PDU type.

Parameters:
pdu - PDU to set information on

ovirtual BOOL OnSendingPDU( H245_AudioCapability & pdu, unsigned packetSize ) const
This function is called whenever and outgoing TerminalCapabilitySet or OpenLogicalChannel PDU is being constructed for the control channel. It allows the capability to set the PDU fields from information in members specific to the class.

The default behaviour assumes the pdu is an integer number of frames per packet.

Parameters:
pdu - PDU to set information on
packetSize - Packet size to use in capability

ovirtual BOOL OnSendingPDU( H245_AudioMode & pdu ) const
This function is called whenever and outgoing RequestMode PDU is being constructed for the control channel. It allows the capability to set the PDU fields from information in members specific to the class.

The default behaviour sets the PDUs tag according to the GetSubType() function (translated to different enum).

Parameters:
pdu - PDU to set information on

ovirtual BOOL OnReceivedPDU( const H245_Capability & pdu )
This function is called whenever and incoming TerminalCapabilitySet PDU is received on the control channel, and a new H323Capability descendent was created. This completes reading fields from the PDU into the classes members.

If the function returns FALSE then the received PDU codec description is not supported, so will be ignored.

The default behaviour calls the OnReceivedPDU() that takes a H245_AudioCapability and clamps the txFramesInPacket.

Parameters:
pdu - PDU to get information from

ovirtual BOOL OnReceivedPDU( const H245_DataType & pdu, BOOL receiver )
This function is called whenever and incoming OpenLogicalChannel PDU has been used to construct the control channel. It allows the capability to set from the PDU fields, information in members specific to the class.

The default behaviour calls the OnReceivedPDU() that takes a H245_AudioCapability and clamps the txFramesInPacket or rxFramesInPacket.

Parameters:
pdu - PDU to get information from
receiver - Is receiver OLC

ovirtual BOOL OnReceivedPDU( const H245_AudioCapability & pdu, unsigned & packetSize )
This function is called whenever and incoming TerminalCapabilitySet or OpenLogicalChannel PDU has been used to construct the control channel. It allows the capability to set from the PDU fields, information in members specific to the class.

The default behaviour assumes the pdu is an integer number of frames per packet.

Parameters:
pdu - PDU to get information from
packetSize - Packet size to use in capability


Direct child classes:
H323_LIDCapability
H323_GSM0610Capability
H323_G729Capability
H323_G729ACapability
H323_G7231Capability
H323_G711Capability
H323NonStandardAudioCapability

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.