-
Notifications
You must be signed in to change notification settings - Fork 148
/
main.js
40 lines (33 loc) · 969 Bytes
/
main.js
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
// entry point:
function main(e){
document.getElementById('notice').style.display = 'none';
const videoElement = document.getElementById('myVideo');
videoElement['play']();
if (videoElement['currentTime'] && videoElement['videoWidth'] && videoElement['videoHeight']){
start(videoElement);
} else {
setTimeout(main, 100);
videoElement['play']();
}
}
function start(videoElement){
JeelizWebojiThreeHelper.init({
canvasThreeId: 'webojiCanvas',
canvasId: 'jeelizFaceExpressionsCanvas',
assetsParentPath: '../../../assets/3D/',
NNCPath: '../../../dist/',
//RACCOON :
meshURL: 'meshes/fox11_v0.json',
matParameters: {
diffuseMapURL: 'textures/Fox_albedo.png',
specularMapURL: 'textures/Fox_specular.png',
flexMapURL: 'textures/Fox_flex.png'
},
position: [0,-80,0],
scale: 1.2,
videoSettings: {
videoElement: videoElement
}
});
}
window.addEventListener('click', main);