expose mesh worker log function
This commit is contained in:
parent
c7a6fe1920
commit
c64337f3c4
3 changed files with 3 additions and 2 deletions
|
|
@ -2,7 +2,6 @@
|
|||
|
||||
import { THREE } from '../ext/three.js';
|
||||
const { Matrix4, Matrix3, Vector3, Box3 } = THREE;
|
||||
import { license as motoLicense } from '../moto/license.js';
|
||||
|
||||
// geometry helper functions
|
||||
const geom = {
|
||||
|
|
|
|||
|
|
@ -929,7 +929,7 @@ class MeshTool {
|
|||
}
|
||||
|
||||
pitch = p.round(3);
|
||||
geom.log(`gear pitch radius: ${pitch}`);
|
||||
log(`gear pitch radius: ${pitch}`);
|
||||
}
|
||||
|
||||
return { gear, pitch };
|
||||
|
|
|
|||
|
|
@ -35,6 +35,8 @@ function log(msg) {
|
|||
return worker.publish("mesh.log", msg);
|
||||
}
|
||||
|
||||
self.log = log;
|
||||
|
||||
function cacheUpdate(id, data) {
|
||||
return Object.assign(cache[id], data);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue