fix shadow and lathe progress reporting
This commit is contained in:
parent
f81e002766
commit
68ff3391ce
3 changed files with 3 additions and 11 deletions
|
|
@ -7,10 +7,6 @@ export class OpIndex extends CamOp {
|
|||
super(state, op);
|
||||
}
|
||||
|
||||
weight() {
|
||||
return 3;
|
||||
}
|
||||
|
||||
async slice(progress) {
|
||||
let { op, state } = this;
|
||||
|
||||
|
|
|
|||
|
|
@ -21,10 +21,6 @@ class OpShadow extends CamOp {
|
|||
super(state, op);
|
||||
}
|
||||
|
||||
weight() {
|
||||
return 3;
|
||||
}
|
||||
|
||||
async slice(progress) {
|
||||
let state = this.state;
|
||||
|
||||
|
|
@ -68,7 +64,7 @@ class OpShadow extends CamOp {
|
|||
.setLayer("shadow", {line: 0x888800, thin: true })
|
||||
.addPolys(shadow, { thin: true });
|
||||
}
|
||||
progress(0.5 + i / tzindex.length, 'shadow');
|
||||
progress(0.5 + (i / tzindex.length) * 0.5, 'shadow');
|
||||
}
|
||||
|
||||
if (devel && slices.length) {
|
||||
|
|
|
|||
|
|
@ -203,13 +203,13 @@ export class Topo {
|
|||
await gpu.loadTerrain({
|
||||
triangles: vertices,
|
||||
boundsOverride,
|
||||
onProgress(pct) { onupdate(pct/100) }
|
||||
onProgress: (pct) => onupdate(pct / 1000)
|
||||
});
|
||||
let output = await gpu.generateToolpaths({
|
||||
xStep,
|
||||
yStep: 1,
|
||||
zFloor: zBottom,
|
||||
onProgress(i,j) { onupdate(i/j) }
|
||||
onProgress: (i,j) => onupdate(0.1 + i / j)
|
||||
});
|
||||
gpu.terminate();
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue