AmRtpAudio Class Reference

binds together a AmRtpStream and an AmAudio for a session More...

#include <AmRtpAudio.h>

Inheritance diagram for AmRtpAudio:

AmRtpStream AmAudio

Public Member Functions

 AmRtpAudio (AmSession *_s=0)
bool checkInterval (unsigned int ts)
bool sendIntReached ()
int receive (unsigned int audio_buffer_ts)
void setSendOnly (bool so)
int read (unsigned int user_ts, unsigned int size)
int write (unsigned int user_ts, unsigned int size)
int get (unsigned int user_ts, unsigned char *buffer, unsigned int nb_samples)
void init (const SdpPayload *sdp_payload)
void setAdaptivePlayout (bool on)

Detailed Description

binds together a AmRtpStream and an AmAudio for a session


Member Function Documentation

int AmRtpAudio::get ( unsigned int  user_ts,
unsigned char *  buffer,
unsigned int  nb_samples 
) [virtual]

Get some samples from input stream.

Warning:
For packet based payloads / file formats, use:
           nb_sample = input buffer size / sample size of the reference format
 
whereby the format with/from which the codec works is the reference one.
Returns:
# bytes read, else -1 if error (0 is OK)

Reimplemented from AmAudio.

void AmRtpAudio::init ( const SdpPayload sdp_payload  )  [virtual]

Enables RTP stream.

Parameters:
sdp_payload payload from the SDP message.
Warning:
start() must have been called so that play and record work.

It should be called only if the stream has been completly initialized,

and only once per session. Use resume() then.

Reimplemented from AmRtpStream.

int AmRtpAudio::read ( unsigned int  user_ts,
unsigned int  size 
) [virtual]

Gets 'size' bytes directly from stream (Read,Pull).

Implements AmAudio.

int AmRtpAudio::write ( unsigned int  user_ts,
unsigned int  size 
) [virtual]

Puts 'size' bytes directly from stream (Write,Push).

Implements AmAudio.


The documentation for this class was generated from the following files:
Generated on Thu Mar 8 00:12:46 2007 for Sems by  doxygen 1.4.7
Home |  Recent changes |  Search |  Glossary |  Sitemap |  Login