本文整理匯總了TypeScript中makerjs.model.move方法的典型用法代碼示例。如果您正苦於以下問題:TypeScript model.move方法的具體用法?TypeScript model.move怎麽用?TypeScript model.move使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類makerjs.model
的用法示例。
在下文中一共展示了model.move方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的TypeScript代碼示例。
示例1:
// const expanded = MakerJs.model.expandPaths(makerPath, STROKE);
const points = [
[0, 0],
[0, BOARD - SCALE],
[BOARD - SCALE, 0],
[BOARD - SCALE, BOARD - SCALE],
[(BOARD - SCALE) / 2, (BOARD - SCALE) / 2]
// [-SCALE / 2, SCALE / 2],
// [BOARD - SCALE * 3/2, SCALE / 2],
// [-SCALE/2, -BOARD + SCALE * 3/2],
// [BOARD - SCALE * 3/2, -BOARD + SCALE * 3/2],
];
const holes: MakerJs.IModel = new MakerJs.models.Holes(2, points);
MakerJs.model.move(holes, [0 - SCALE / 2, 0 - SCALE / 2]);
/*
The Stack To Cut
stacked paper with approx semicircular path
*/
const expanded = {};
const layerOptions = {};
const MARGIN = 12;
const COLS = 3;
for (let i = 0; i < PAGES; i++) {
const depth = THICKNESS * (PAGES - i - 1);