aboutsummaryrefslogtreecommitdiffhomepage
path: root/experimental/docs/backend.js
blob: efb8e52ef0b23ff283c0f06a5f36efc79516a669 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
function displayBackend(displayEngine, displayList) {
    switch (displayEngine) {
        case 'all':
            displayCanvas(displayList);
            displaySvg(displayList);
            break;
        case 'Canvas':
            displayCanvas(displayList);
            break;
        case 'SVG':
            displaySvg(displayList);
            break;
        default:
            assert(0);
    }
}

function keyframeBackendInit(displayEngine, displayList, first) {
    switch (displayEngine) {
        case 'all':
        case 'Canvas':
            keyframeCanvasInit(displayList, first);
            break;
        case 'SVG':
            break;
        default:
            assert(0);
    }
}

function setupBackend(displayEngine) {
    switch (displayEngine) {
        case 'all':
        case 'Canvas':
            setupCanvas();
            setupSvg();
            break;
        case 'SVG':
            setupSvg();
            break;
        default:
            assert(0);
    }
}