mirror of
https://github.com/nasa/openmct.git
synced 2025-06-14 21:28:12 +00:00
[Plot] Begin adding WebGL fallback
Begin adding code to handle case where WebGL context is lost, WTD-475.
This commit is contained in:
@ -155,6 +155,15 @@ define(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function fallbackFromWebGL() {
|
||||||
|
element.html(TEMPLATE);
|
||||||
|
canvas = element.find("canvas")[0];
|
||||||
|
chart = getChart([Canvas2DChart], canvas);
|
||||||
|
if (chart) {
|
||||||
|
doDraw(scope.draw);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Try to initialize a chart.
|
// Try to initialize a chart.
|
||||||
chart = getChart([GLChart, Canvas2DChart], canvas);
|
chart = getChart([GLChart, Canvas2DChart], canvas);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user