mirror of
https://github.com/Doodle3D/Doodle3D-Slicer.git
synced 2024-11-22 05:37:55 +01:00
rename file
This commit is contained in:
parent
dbc01167e5
commit
ca886afa25
@ -1,4 +1,4 @@
|
||||
import { divide } from './helpers/vector2D.js';
|
||||
import { divide } from './helpers/vector2.js';
|
||||
import { PRECISION } from '../constants.js'
|
||||
|
||||
export default function applyPrecision(layers) {
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { normalize } from './helpers/vector2D.js';
|
||||
import { normalize } from './helpers/vector2.js';
|
||||
|
||||
function addLine(vertices, lineLookup, lines, a, b, faceIndex) {
|
||||
let index;
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { scale, distanceTo } from './vector2D.js';
|
||||
import { scale, distanceTo } from './vector2.js';
|
||||
import { PRECISION, VERSION } from '../../constants.js';
|
||||
|
||||
export const MOVE = 'G';
|
||||
|
@ -1,5 +1,5 @@
|
||||
import Shape from 'clipper-js';
|
||||
import { subtract, add, scale, normalize, dot, length, distanceTo } from './vector2D.js';
|
||||
import { subtract, add, scale, normalize, dot, length, distanceTo } from './vector2.js';
|
||||
import { PRECISION } from '../../constants.js';
|
||||
|
||||
const TOLERANCE = 1 / PRECISION;
|
||||
|
@ -6,17 +6,17 @@ export const add = (a, b) => ({
|
||||
x: a.x + b.x,
|
||||
y: a.y + b.y
|
||||
});
|
||||
export const scale = (a, factor) => ({
|
||||
x: a.x * factor,
|
||||
y: a.y * factor
|
||||
export const scale = (v, factor) => ({
|
||||
x: v.x * factor,
|
||||
y: v.y * factor
|
||||
});
|
||||
export const divide = (a, factor) => ({
|
||||
x: a.x / factor,
|
||||
y: a.y / factor
|
||||
export const divide = (v, factor) => ({
|
||||
x: v.x / factor,
|
||||
y: v.y / factor
|
||||
});
|
||||
export const normal = (a) => ({
|
||||
x: -a.y,
|
||||
y: a.x
|
||||
export const normal = (v) => ({
|
||||
x: -v.y,
|
||||
y: v.x
|
||||
});
|
||||
export const equals = (a, b) => a.x === b.x && a.y === b.y;
|
||||
export const almostEquals = (a, b) => Math.abs(a.x - b.x) < 0.001 && Math.abs(a.y - b.y) < 0.001;
|
@ -1,4 +1,4 @@
|
||||
import { subtract, normal, normalize, dot, almostEquals } from './helpers/vector2D.js';
|
||||
import { subtract, normal, normalize, dot, almostEquals } from './helpers/vector2.js';
|
||||
|
||||
export default function intersectionsToShapes(layerPoints, layerFaceIndexes, faces, openObjectIndexes, settings) {
|
||||
const layers = [];
|
||||
|
@ -1,4 +1,4 @@
|
||||
import { length, distanceTo } from './helpers/vector2D.js';
|
||||
import { length, distanceTo } from './helpers/vector2.js';
|
||||
import Shape from 'clipper-js';
|
||||
|
||||
export default function optimizePaths(slices, settings) {
|
||||
|
@ -1,6 +1,6 @@
|
||||
import GCode from './helpers/GCode.js';
|
||||
import comb from './helpers/comb.js';
|
||||
import { divide } from './helpers/vector2D.js';
|
||||
import { divide } from './helpers/vector2.js';
|
||||
import { PRECISION, Z_OFFSET } from '../constants.js';
|
||||
|
||||
const PROFILE_TYPES = ['support', 'innerShell', 'outerShell', 'innerInfill', 'outerInfill', 'brim'];
|
||||
|
Loading…
Reference in New Issue
Block a user