Coder Social home page Coder Social logo

Comments (3)

elalish avatar elalish commented on July 3, 2024

@pca006132 After thinking about this for quite a while, I think it's going to be pretty difficult, algorithmically, to make negative objects work intuitively with Boolean operations. After all, they do work now (they're manifold), they're just surprising, as with overlapping manifolds. I think the better approach is to follow what we're already doing in 2D: make all Manifolds non-overlapping.

Of course, I haven't yet made an algorithm to remove overlaps from a Manifold, but I plan to. When that happens, negative volume objects will also be removed, due to the positive fill rule. So I think our best stepping-stone for now is to detect and remove negative-volume meshes as a Manifold is constructed. This leaves the question of how to handle Decompose.

We could remove the vugs from the output, which might be confusing. We could invert them, so they become positive volume objects in their own right. Or we could just ignore all of this and put in the documentation that negative volume meshes are not epsilon-valid, so it's up to you to avoid them, just like self-intersecting meshes.

What do you think?

from manifold.

pca006132 avatar pca006132 commented on July 3, 2024

So I think our best stepping-stone for now is to detect and remove negative-volume meshes as a Manifold is constructed. This leaves the question of how to handle Decompose.

Agreed. I am more inclined towards subtracting the vugs from the output volumes (which is just composing them if they intersect?), this matches my intuition about how the objects are defined (the holes are part of the enclosing object) and how Decompose should work (holes should be kept).

from manifold.

elalish avatar elalish commented on July 3, 2024

That's a good point, and IIRC our 2D decompose already acts that way. Sounds like a good approach.

from manifold.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.