1
0
mirror of https://github.com/psychopy/psychojs.git synced 2025-05-10 10:40:54 +00:00

Merge pull request #544 from lightest/hw_accel_check_improvements

added checkWebGLSupport flag check in openWindow();
This commit is contained in:
Alain Pitiot 2022-11-30 10:52:19 +01:00 committed by GitHub
commit c20bbef448
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -436,6 +436,12 @@ export class Window extends PsychObject
this._size[0] = window.innerWidth;
this._size[1] = window.innerHeight;
if (this._psychoJS._checkWebGLSupport)
{
// see checkWebGLSupport() method for details.
PIXI.settings.FAIL_IF_MAJOR_PERFORMANCE_CAVEAT = true;
}
// create a PIXI renderer and add it to the document:
this._renderer = PIXI.autoDetectRenderer({
width: this._size[0],