mirror of
https://github.com/ossrs/srs.git
synced 2025-03-09 15:49:59 +00:00
RTC: Directly send without sendmmsg
This commit is contained in:
parent
4f6b24ea12
commit
f03bf601e4
10 changed files with 15 additions and 449 deletions
|
@ -271,7 +271,6 @@ SrsStatistic::SrsStatistic()
|
|||
perf_rtp = new SrsStatisticCategory();
|
||||
perf_rtc = new SrsStatisticCategory();
|
||||
perf_bytes = new SrsStatisticCategory();
|
||||
perf_dropped = new SrsStatisticCategory();
|
||||
}
|
||||
|
||||
SrsStatistic::~SrsStatistic()
|
||||
|
@ -312,7 +311,6 @@ SrsStatistic::~SrsStatistic()
|
|||
srs_freep(perf_rtp);
|
||||
srs_freep(perf_rtc);
|
||||
srs_freep(perf_bytes);
|
||||
srs_freep(perf_dropped);
|
||||
}
|
||||
|
||||
SrsStatistic* SrsStatistic::instance()
|
||||
|
@ -666,29 +664,6 @@ srs_error_t SrsStatistic::dumps_perf_bytes(SrsJsonObject* obj)
|
|||
return srs_success;
|
||||
}
|
||||
|
||||
void SrsStatistic::perf_on_dropped(int nn_msgs, int nn_rtc, int nn_dropped)
|
||||
{
|
||||
// a: System AVFrames.
|
||||
// b: RTC frames.
|
||||
// c: Dropped frames.
|
||||
perf_dropped->a += nn_msgs;
|
||||
perf_dropped->b += nn_rtc;
|
||||
perf_dropped->c += nn_dropped;
|
||||
|
||||
perf_dropped->nn += nn_dropped;
|
||||
}
|
||||
|
||||
srs_error_t SrsStatistic::dumps_perf_dropped(SrsJsonObject* obj)
|
||||
{
|
||||
obj->set("avframes", SrsJsonAny::integer(perf_dropped->a));
|
||||
obj->set("rtc_frames", SrsJsonAny::integer(perf_dropped->b));
|
||||
obj->set("rtc_dropeed", SrsJsonAny::integer(perf_dropped->c));
|
||||
|
||||
obj->set("nn", SrsJsonAny::integer(perf_dropped->nn));
|
||||
|
||||
return srs_success;
|
||||
}
|
||||
|
||||
void SrsStatistic::reset_perf()
|
||||
{
|
||||
srs_freep(perf_iovs);
|
||||
|
@ -697,7 +672,6 @@ void SrsStatistic::reset_perf()
|
|||
srs_freep(perf_rtp);
|
||||
srs_freep(perf_rtc);
|
||||
srs_freep(perf_bytes);
|
||||
srs_freep(perf_dropped);
|
||||
|
||||
perf_iovs = new SrsStatisticCategory();
|
||||
perf_msgs = new SrsStatisticCategory();
|
||||
|
@ -705,7 +679,6 @@ void SrsStatistic::reset_perf()
|
|||
perf_rtp = new SrsStatisticCategory();
|
||||
perf_rtc = new SrsStatisticCategory();
|
||||
perf_bytes = new SrsStatisticCategory();
|
||||
perf_dropped = new SrsStatisticCategory();
|
||||
}
|
||||
|
||||
void SrsStatistic::perf_on_packets(SrsStatisticCategory* p, int nb_msgs)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue