上传者: 39841848
|
上传时间: 2021-12-24 16:28:37
|
文件大小: 31KB
|
文件类型: -
代码片段:
uniforms: {
uResolution: function uResolution(_ref2) {
var viewportWidth = _ref2.viewportWidth;
var viewportHeight = _ref2.viewportHeight;
return [viewportWidth, viewportHeight];
},
uTime: function uTime(_ref3) {
var tick = _ref3.tick;
return 0.01 * tick;
},
uMouse: function uMouse() {
return [pointer.position.x, pointer.position.y];
},
uMorph: function uMorph() {
return morphAmount;
},
uRandomSeed: DEV ? 138975.579831 : new Date().getTime() % 1000000, //
uGrid: function uGrid(_ref4) {
var viewportWidth = _ref4.viewportWidth;
var viewportHeight = _ref4.viewportHeight;
var ratio = 0.32;
return viewportHeight >= viewportWidth ? [1, viewportHeight / viewportWidth * ratio] : [viewportWidth / viewportHeight * ratio, 1];
}
},