Inside the app I'm developping, I have to include a VoIP audio chat service for group call with PushToTalk (1 talks, N listen).
I don't need SIP, because I already developped my own signaling protocol in order to do and receive the call.
The service should be peer-to-peer, that is the VoIP packets should go directly from the talker to the N listeners without involving a server.
The transport network will be 90% of the times GSM(UMTS/LTE), 10% Wi-Fi
I'm not an expert, but according to what I read on the web, due to the group call I suppose it's needed multicast.
It's seems that native [url removed, login to view] packet doesn't support multicast, so I guess it's needed some other RTP solution (JMF?); I also understood that android uses audiorecord and audiotracks classes.
Of course the expert VoIP programmer can suggest other better solutions.
The output of the required job is a Java class for Android so made:
- 1 method, I'll call it "SendVoice", that somewhere in my app will be invoked in order to capture Mic audio of the android cellular and to be sent to the N listener;
- it is invoked by the talker cellular;
- arguments of "SendVoice": "address of multicast group" ; "port of multicast group";
- the programmer can consider to have inside the loop that sends the packets a condition "getIsTrasmittingInGroupCall()"; when it becames false means that sending must stop and the loop must end.
- 1 method, I'll call it "ReceiveVoice", that somewhere in my app will be invoked in order to receive the audio sent by the talker and to be played by the android speaker cellular;
- it is invoked by the listener cellular and will be in a own new thread;
- arguments of "ReceiveVoice": "address of multicast group" ; "port of multicast group";
- the programmer can consider to have inside the loop that waits and listens the packets a condition "getIsReceivingInGroupCall()"; when it becames false means that receiving must stop and the loop must end.