Comments (2)
Hi again!
I've been working with your library and I know there are different ways to categorize polygons, but basically my problem is kind of simple, yet I can't figure it out:
The far left side of the image is a union operation, and the far right is an intersect operation.
The idea is that I'm looking to leave with only the original silhouette, the cube shape, but the materials changed where they share vertices. So I need to combine operations, or trim away the non-intersecting part of the union operation on the far left side, but keep the non intersecting part of the union operation for the cube.
Is there a way to only trim away one geometry but keep the material change?
Thank you
from three-csgmesh.
I don't think so. But if you don't care about efficiency.. you can merge the results of 2 operations and get something that looks identical to what you describe.
Do the intersect like you have on the right.. then swap the order and do it again to get the outer cube part.. and merge the 2 results into a single mesh using geometry.merge.
The final mesh will have multiple materials in its .material field (as an array [ material1,material2,material3]) and you can re-order/replace them as you see fit.
from three-csgmesh.
Related Issues (20)
- intersecting a box with a cone results in a slice of the surface of the cone instead of a solid object HOT 4
- TypeError: cannot read property array of undefined in fromGeometry of a custom geometry HOT 1
- Subtract from mesh, without closing the mesh? HOT 1
- Problem with Rotation HOT 4
- How check if 2 Objects have a intersection result HOT 5
- Does CSG support planes? HOT 5
- Do multiple substract on 1 Mesh HOT 1
- Not working with imported STL files. HOT 1
- Stuck on Any Operation between two STL files HOT 1
- Cleaning up EdgesGeometry HOT 2
- Improving Performance HOT 28
- Material Groups HOT 1
- ConeGeometry / LatheGeometry incorrect result HOT 1
- ExtrudeGeometry can't be correctlly processed by csg HOT 1
- Face of mesh missing after subtraction HOT 2
- subtract() and intersect() are swapped in some operations HOT 1
- Remaining face after subtract operation HOT 1
- The issue doesn't work to make a hole in a plane HOT 1
- npm HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from three-csgmesh.