Fixing CI + lowering extrapolation time
This commit is contained in:
parent
a87cdc543b
commit
57262de1bf
@ -13,13 +13,13 @@ class CpuTracker {
|
||||
let time = process.hrtime.bigint()
|
||||
let usage = process.cpuUsage()
|
||||
setInterval(() => {
|
||||
let elapTime = process.hrtime.bigint();
|
||||
let elapUsage = process.cpuUsage(usage)
|
||||
const elapTime = process.hrtime.bigint();
|
||||
const elapUsage = process.cpuUsage(usage)
|
||||
usage = process.cpuUsage()
|
||||
|
||||
let elapTimeMS = elapTime - time;
|
||||
let elapUserMS = secNSec2ms(elapUsage.user)
|
||||
let elapSystMS = secNSec2ms(elapUsage.system)
|
||||
const elapTimeMS = elapTime - time;
|
||||
const elapUserMS = secNSec2ms(elapUsage.user)
|
||||
const elapSystMS = secNSec2ms(elapUsage.system)
|
||||
this.cpuPercent = Math.round(100 * (elapUserMS + elapSystMS) / Number(elapTimeMS) * 1000000)
|
||||
|
||||
time = elapTime;
|
||||
@ -27,7 +27,7 @@ class CpuTracker {
|
||||
console.log('elapsed user ms: ', elapUserMS)
|
||||
console.log('elapsed system ms:', elapSystMS)
|
||||
console.log('cpu percent: ', this.cpuPercent)*/
|
||||
}, 500);
|
||||
}, 100);
|
||||
}
|
||||
|
||||
public getCpuPercent(): number {
|
||||
|
@ -7,7 +7,7 @@ const JITSI_URL : string|undefined = (process.env.JITSI_URL === '') ? undefined
|
||||
const RESOLUTION = 3;
|
||||
const ZOOM_LEVEL = 1/*3/4*/;
|
||||
const POSITION_DELAY = 200; // Wait 200ms between sending position events
|
||||
const MAX_EXTRAPOLATION_TIME = 250; // Extrapolate a maximum of 250ms if no new movement is sent by the player
|
||||
const MAX_EXTRAPOLATION_TIME = 100; // Extrapolate a maximum of 250ms if no new movement is sent by the player
|
||||
|
||||
export {
|
||||
DEBUG_MODE,
|
||||
|
Loading…
Reference in New Issue
Block a user