File: bandwidth.h

package info (click to toggle)
neatvnc 0.9.1%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 804 kB
  • sloc: ansic: 11,804; cpp: 572; makefile: 14
file content (14 lines) | stat: -rw-r--r-- 359 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#pragma once

struct bwe_sample {
	int bytes;
	int departure_time;
	int arrival_time; // round-trip arrival time
};

struct bwe* bwe_create(int rtt_min);
void bwe_destroy(struct bwe* self);

void bwe_feed(struct bwe* self, const struct bwe_sample* sample);
void bwe_update_rtt_min(struct bwe* self, int rtt_min);
int bwe_get_estimate(const struct bwe* self);