mirror of
https://git.roussel.pro/telecom-paris/pact.git
synced 2026-02-09 02:20:17 +01:00
code test pour tester les fps
This commit is contained in:
@@ -12,6 +12,8 @@ class CameraEditor {
|
||||
this.images = {};
|
||||
this._startup();
|
||||
this._loadImages();
|
||||
this.startupTime;
|
||||
this.frameCount = 0;
|
||||
}
|
||||
|
||||
_startup() {
|
||||
@@ -59,6 +61,10 @@ class CameraEditor {
|
||||
}
|
||||
|
||||
_frame() {
|
||||
if(this.startupTime == undefined){
|
||||
this.startupTime = Date.now();
|
||||
}
|
||||
this.frameCount++;
|
||||
const context = canvas.getContext("2d");
|
||||
if(this.streaming) {
|
||||
if (this.width && this.height) {
|
||||
|
||||
Reference in New Issue
Block a user