I am developing VOIP client and implementing last part of this on N95 device which is sending and receiving voice data over RTP using RTPSession framework.I'm enable to open and register session which is not tested yet because i need to send or receive packet on port for that.On both end i'm using my own implemted client on N95 devices.
Please anyone like to share a peace of code and give me some clues how to implement that as there is no example shipped by Nokia for RTPSession.
Here are some lines that i've coded and expected Send and Receive stream should be opened but it is not.
TInetAddr localAddr = INET_ADDR( 10,1,7,124 );
localAddr.SetPort( 30000 );
TInetAddr remoteAddr = INET_ADDR( 10,1,7,114 );
remoteAddr.SetPort( 30000 );
//opening and registering a RTPSession ....
iSession.OpenL( iSocketServer,localAddr,remoteAddr,iMaxRXSize,iConnection );
Trying to create a RRtpSendSource that doesn't work !!! Please correct me if i'm missing any step......
iSendPacket = iSendSource.NewSendPacketL( 164 /*size of G711 codec payload */ );
iSendPacket.SetPayloadType( 98 );
//writing a payload that i got from Audio proxy server buffer and trying to send that buffer to other termianl over RTP.
TDesC8& payload = iSendPacket.WritePayload();
payload = aPayload;
///Callback function definition...
void CRTPEngine::HandleRTPEvent( TAny* contextData, const TRtpEvent& aEvent )
CRTPEngine* rtpEngine = (CRTPEngine*) contextData;
_LIT8( KDebugIN, "CRTPEngine::HandleRTPEvent IN" );
rtpEngine->iObserver->WriteRTPLog( KDebugIN(), 0 );
_LIT8( KDebugOUT, "CRTPEngine::HandleRTPEvent OUT" );
rtpEngine->iObserver->WriteRTPLog( KDebugOUT(), 0 );
I'm wondering how to create send and receive Rtp sources on RTPSession!!!
Thanks in advance,