SDPMedia

The contents of the SDP "m=" field with all related fields.

class SDPMedia {
GstSDPMedia cInstance;
}

Members

Functions

addAttribute
gstsdp.types.SDPResult addAttribute(string key, string value)

Add the attribute with key and value to media.

addBandwidth
gstsdp.types.SDPResult addBandwidth(string bwtype, uint bandwidth)

Add the bandwidth information with bwtype and bandwidth to media.

addConnection
gstsdp.types.SDPResult addConnection(string nettype, string addrtype, string address, uint ttl, uint addrNumber)

Add the given connection parameters to media.

addFormat
gstsdp.types.SDPResult addFormat(string format)

Add the format information to media.

asText
string asText()

Convert the contents of media to a text string.

attributesLen
uint attributesLen()

Get the number of attribute fields in media.

attributesToCaps
gstsdp.types.SDPResult attributesToCaps(gst.caps.Caps caps)

Mapping of attributes of #GstSDPMedia to #GstCaps

bandwidthsLen
uint bandwidthsLen()

Get the number of bandwidth fields in media.

connectionsLen
uint connectionsLen()

Get the number of connection fields in media.

copy
gstsdp.types.SDPResult copy(gstsdp.sdpmedia.SDPMedia copy)

Allocate a new copy of media and store the result in copy. The value in copy should be release with gst_sdp_media_free function.

formatsLen
uint formatsLen()

Get the number of formats in media.

getAttribute
gstsdp.sdpattribute.SDPAttribute getAttribute(uint idx)

Get the attribute at position idx in media.

getAttributeVal
string getAttributeVal(string key)

Get the first attribute value for key in media.

getAttributeValN
string getAttributeValN(string key, uint nth)

Get the nth attribute value for key in media.

getBandwidth
gstsdp.sdpbandwidth.SDPBandwidth getBandwidth(uint idx)

Get the bandwidth at position idx in media.

getCapsFromMedia
gst.caps.Caps getCapsFromMedia(int pt)

Mapping of caps from SDP fields:

getConnection
gstsdp.sdpconnection.SDPConnection getConnection(uint idx)

Get the connection at position idx in media.

getFormat
string getFormat(uint idx)

Get the format information at position idx in media.

getInformation
string getInformation()

Get the information of media

getKey
gstsdp.sdpkey.SDPKey getKey()

Get the encryption information from media.

getMedia
string getMedia()

Get the media description of media.

getNumPorts
uint getNumPorts()

Get the number of ports for media.

getPort
uint getPort()

Get the port number for media.

getProto
string getProto()

Get the transport protocol of media

insertAttribute
gstsdp.types.SDPResult insertAttribute(int idx, gstsdp.sdpattribute.SDPAttribute attr)

Insert the attribute to media at idx. When idx is -1, the attribute is appended.

insertBandwidth
gstsdp.types.SDPResult insertBandwidth(int idx, gstsdp.sdpbandwidth.SDPBandwidth bw)

Insert the bandwidth information to media at idx. When idx is -1, the bandwidth is appended.

insertConnection
gstsdp.types.SDPResult insertConnection(int idx, gstsdp.sdpconnection.SDPConnection conn)

Insert the connection information to media at idx. When idx is -1, the connection is appended.

insertFormat
gstsdp.types.SDPResult insertFormat(int idx, string format)

Insert the format information to media at idx. When idx is -1, the format is appended.

parseKeymgmt
gstsdp.types.SDPResult parseKeymgmt(gstsdp.mikeymessage.MIKEYMessage mikey)

Creates a new #GstMIKEYMessage after parsing the key-mgmt attribute from a #GstSDPMedia.

removeAttribute
gstsdp.types.SDPResult removeAttribute(uint idx)

Remove the attribute in media at idx.

removeBandwidth
gstsdp.types.SDPResult removeBandwidth(uint idx)

Remove the bandwidth information in media at idx.

removeConnection
gstsdp.types.SDPResult removeConnection(uint idx)

Remove the connection information in media at idx.

removeFormat
gstsdp.types.SDPResult removeFormat(uint idx)

Remove the format information in media at idx.

replaceAttribute
gstsdp.types.SDPResult replaceAttribute(uint idx, gstsdp.sdpattribute.SDPAttribute attr)

Replace the attribute in media at idx with attr.

replaceBandwidth
gstsdp.types.SDPResult replaceBandwidth(uint idx, gstsdp.sdpbandwidth.SDPBandwidth bw)

Replace the bandwidth information in media at idx with bw.

replaceConnection
gstsdp.types.SDPResult replaceConnection(uint idx, gstsdp.sdpconnection.SDPConnection conn)

Replace the connection information in media at idx with conn.

replaceFormat
gstsdp.types.SDPResult replaceFormat(uint idx, string format)

Replace the format information in media at idx with format.

setInformation
gstsdp.types.SDPResult setInformation(string information)

Set the media information of media to information.

setKey
gstsdp.types.SDPResult setKey(string type, string data)

Adds the encryption information to media.

setMedia
gstsdp.types.SDPResult setMedia(string med)

Set the media description of media to med.

setPortInfo
gstsdp.types.SDPResult setPortInfo(uint port, uint numPorts)

Set the port information in media.

setProto
gstsdp.types.SDPResult setProto(string proto)

Set the media transport protocol of media to proto.

uninit
gstsdp.types.SDPResult uninit()

Free all resources allocated in media. media should not be used anymore after this function. This function should be used when media was allocated on the stack and initialized with gstsdp.sdpmedia.SDPMedia.init_.

Static functions

init_
gstsdp.types.SDPResult init_(gstsdp.sdpmedia.SDPMedia media)

Initialize media so that its contents are as if it was freshly allocated with gstsdp.sdpmedia.SDPMedia.new_. This function is mostly used to initialize a media allocated on the stack. gstsdp.sdpmedia.SDPMedia.uninit undoes this operation.

new_
gstsdp.types.SDPResult new_(gstsdp.sdpmedia.SDPMedia media)

Allocate a new GstSDPMedia and store the result in media.

setMediaFromCaps
gstsdp.types.SDPResult setMediaFromCaps(gst.caps.Caps caps, gstsdp.sdpmedia.SDPMedia media)

Mapping of caps to SDP fields: