Hi Phillipp,
even i am having same problem in identifying local and remote stats.
on my peerConn i will call getstats API which will return me an array of stats.Now i want to get info like "PacketSent","codec","PacketsRecieved","bytesSent", "bytesRecieved" "packetlost", "Jitter" on that peerConn.
This is what i did..
_peerConn.getStats(function(stats){
var results = stats.result();
for(var i=0; i < results.length; i++) {
var res = results[i];
if (!res.local || res.local === res) {
showStats( res);
}
}
//obj is the returned stats array
function showStats(){
if(obj.names) {
var names = obj.names();
for(var i=0; i<names.length; i++) {
var name = names[i];
var value = obj.stat(name);
//here i check for name like "packetsent" "codec" and other required info and will take its respective value from "value" i.e obj.stat(name).
}
}
}
so what ever values i get it here should be same as that in chrome://webrtc-internals.
In-case of webrtc-internals on a particular peerConn is see ssrc_6556101_send which seems to be local stats. Then in Conn-audio-1-0 c also i see some data w.r.t bytesrecieved , packetsSent etc.... what excatly is that ??
thanks in Advance
Anil