mirror of
https://git.roussel.pro/telecom-paris/pact.git
synced 2026-02-09 10:30:17 +01:00
optimisation retour video avec un element video
This commit is contained in:
@@ -6,16 +6,18 @@ const STATE = {
|
||||
};
|
||||
|
||||
class StateManager {
|
||||
constructor(canvas) {
|
||||
this.canvas = canvas;
|
||||
constructor() {
|
||||
this._state = STATE.sleeping;
|
||||
this._cameraPage = new CameraPage(this.canvas);
|
||||
this._cameraPage = new CameraPage();
|
||||
this._sleepingPage = new SleepingPage();
|
||||
|
||||
this.wsClient = new WebsocketClient(
|
||||
(effects) => this._cameraPage.setEffects(effects),
|
||||
(state) => this.changeState(state)
|
||||
);
|
||||
|
||||
this._sleepingPage.enabled = true;
|
||||
this._cameraPage.enabled = false;
|
||||
|
||||
//TODO: Remove qd implémenté dans le backend
|
||||
document.getElementById("sleeping-page-continue").onclick = () => this.setState(STATE.video);
|
||||
|
||||
Reference in New Issue
Block a user