update manifold. fix selection to sketch

This commit is contained in:
Stewart Allen 2025-06-14 11:49:20 -04:00
commit 3b24ebe0d9
9 changed files with 10 additions and 58 deletions

View file

@ -48,7 +48,7 @@
"earcut": "^2.2.3",
"express-useragent": "^1.0.13",
"jszip": "^3.7.1",
"manifold-3d": "^2.5.1",
"manifold-3d": "^3.1.1",
"moment": "^2.29.4",
"serve-static": "^1.14.1",
"three": "^0.174.0",

View file

@ -2,12 +2,9 @@
"use strict";
import { base } from './base.js';
import { THREE } from '../ext/three.js';
import manifold from '../ext/manifold.js';
const { Mesh, BufferGeometry, Vector3 } = THREE;
const debug = true;
const precision = 0.001;
const factor = 1/precision;

View file

@ -6,6 +6,7 @@ import '../add/array.js';
import '../add/class.js';
import '../add/three.js';
import '../mesh/build.js';
import { client as motoClient } from '../moto/client.js';
import { broker as motoBroker } from '../moto/broker.js';
import { space as motoSpace } from '../moto/space.js';
@ -18,12 +19,13 @@ import { load as fileLoad } from '../load/file.js';
import { $, $d, h, estop } from '../moto/webui.js';
import { THREE } from '../ext/three.js';
const { Quaternion } = THREE;
const version = '1.5.6';
const version = '1.5.7';
const api = meshApi;
const call = motoBroker.send;
const dbindex = [ "admin", "space" ];
const { Quaternion } = THREE;
function log() {
return meshApi.log.emit(...arguments);
}

View file

@ -1115,7 +1115,7 @@ const tool = {
},
toSketch() {
for (let m of selection.models()) {
for (let m of api.model.list()) {
m.selectionToSketch();
}
},

View file

@ -1,7 +1,7 @@
/** Copyright Stewart Allen <sa@grid.space> -- All Rights Reserved */
import { broker } from '../moto/broker.js';
import { $, h } from '../moto/webui.js';
import { $, h, estop } from '../moto/webui.js';
import { api } from './api.js';
import { util } from './util.js';
import { space } from '../moto/space.js';

View file

@ -1,7 +1,7 @@
/** Copyright Stewart Allen <sa@grid.space> -- All Rights Reserved */
/**
* facet edge selecetor. allows for creating new facets
* facet edge selector. allows for creating new facets
* when two connected edges share a single point.
*/

View file

@ -4,6 +4,7 @@ import "../ext/earcut.js";
import '../add/array.js';
import '../add/class.js';
import '../add/three.js';
import { version } from '../moto/license.js';
import { client as motoClient } from '../moto/client.js';
import { worker } from '../moto/worker.js';
@ -26,7 +27,7 @@ const work = { cache };
motoClient.start(`/v2/lib/mesh/pool.js?${version}`, motoClient.max() * 0);
function log(msg) {
return motoWorker.publish("mesh.log", msg);
return worker.publish("mesh.log", msg);
}
function cacheUpdate(id, data) {

View file

@ -1,31 +0,0 @@
# Mesh:Tool Development Server
This is the development server setup for Mesh:Tool, a browser-based 3D mesh editor.
## Running the Development Server
1. Make sure you have Node.js installed
2. Install serve globally (optional):
```bash
npm install -g serve
```
3. Run the development server:
```bash
npx serve -l 5432
```
4. Open your browser to http://localhost:5432/mesh
## Development Notes
- The server is configured to handle symlinks and path mappings through `serve.json`
- CORS headers are set to allow WebAssembly modules to load properly
- Static assets are served from the `lib` directory
- Source code is served from the `src2` directory
- Fonts are served from `/font` and `/fon2` directories
## Troubleshooting
If you encounter CORS or WebAssembly loading issues:
1. Make sure you're using a modern browser that supports SharedArrayBuffer
2. Check that the CORS headers are being applied correctly
3. Verify that all paths in index.html are correct for your setup

View file

@ -1,17 +0,0 @@
{
"headers": [
{
"source": "**/*",
"headers": [
{
"key": "Cross-Origin-Embedder-Policy",
"value": "require-corp"
},
{
"key": "Cross-Origin-Opener-Policy",
"value": "same-origin"
}
]
}
]
}