Giter Club home page Giter Club logo

Comments (11)

spiroyster avatar spiroyster commented on August 26, 2024 2

I have a working one. https://github.com/spiroyster/qdcsg, which is a quick and dirty header only implementation using the same white paper... It works fine in 99% of cases although has issues around coplanar triangles from each solid and can sometimes lead to infinite looping (FP precision issues with exrtemely small triangles). I have done some research on this for work and have much better implementations which at some point I may be able to open source. A better approach is to check for intersections and carve (no punn inteneded) up the triangles based around just the intersections. Only problem with this approach is that you need a decent tessellator. qdcsg doesn't require retessellation which means it is easy to implement but results in nasty tessellations some times (many triangles, and long thin ones at that). ymmv.

from cork.

maximecb avatar maximecb commented on August 26, 2024

@reduz Came here looking for a Python CSG library. Seems they are all abandoned/unmaintained. I think it would be worthwhile to produce a new one. I'm particularly interested in using this for procedural mesh generation. If you're doing this and looking for a beta tester, ping me.

from cork.

Raki avatar Raki commented on August 26, 2024

Hi @reduz , I'm looking for a cpp CSG library, seems your own CSG for Godot is a fit. Can you share me code to make standalone lib ?

from cork.

spiroyster avatar spiroyster commented on August 26, 2024

@reduz , yep another vote here for something else. Happy to contribute if there is an upto date MIT CSG lib for c++. Carve has errors, Cork has errors, csgjs-cpp infinitely loops which leaves OpenCascade OCE (LGPL) and a few vague others. Don't want a whoel framework, just a simple lib that can perform the standard boolean operations would be nice... a working one seems to be somewhat elusive. o.0

from cork.

nyholku avatar nyholku commented on August 26, 2024

just a simple lib that can perform the standard boolean operations would be nice.

There is no such thing. Simple to use, maybe, simple to implement, don't think so, thus very unlikely to materialise ... OCE is everyone's best bet if you can live with LGPL... and why not.

from cork.

yetigit avatar yetigit commented on August 26, 2024

@reduz +1 , any csg stuff is welcome at this point

from cork.

gsohler avatar gsohler commented on August 26, 2024

Hi Group,
Is such a library available yet ?

best regards Günther

from cork.

yetigit avatar yetigit commented on August 26, 2024

@spiroyster you are precious , will try it

from cork.

baldhumanity avatar baldhumanity commented on August 26, 2024

I have a working one. https://github.com/spiroyster/qdcsg, which is a quick and dirty header only implementation using the same white paper... It works fine in 99% of cases although has issues around coplanar triangles from each solid and can sometimes lead to infinite looping (FP precision issues with exrtemely small triangles). I have done some research on this for work and have much better implementations which at some point I may be able to open source. A better approach is to check for intersections and carve (no punn inteneded) up the triangles based around just the intersections. Only problem with this approach is that you need a decent tessellator. qdcsg doesn't require retessellation which means it is easy to implement but results in nasty tessellations some times (many triangles, and long thin ones at that). ymmv.

Tried it, too slow compared to cork, uses too much memory. Ty anyway

from cork.

loic-jourdan avatar loic-jourdan commented on August 26, 2024

I have a working one. https://github.com/spiroyster/qdcsg, which is a quick and dirty header only implementation using the same white paper... It works fine in 99% of cases although has issues around coplanar triangles from each solid and can sometimes lead to infinite looping (FP precision issues with exrtemely small triangles). I have done some research on this for work and have much better implementations which at some point I may be able to open source. A better approach is to check for intersections and carve (no punn inteneded) up the triangles based around just the intersections. Only problem with this approach is that you need a decent tessellator. qdcsg doesn't require retessellation which means it is easy to implement but results in nasty tessellations some times (many triangles, and long thin ones at that). ymmv.

I've had a look at it, it's very clean, modern-styled, clear, simple (as simple as possible), efficient, easy-to-use, easy-to-build and quite robust. It's really worth a try. Congrats @spiroyster, it's an amazing job.

from cork.

bluelightning32 avatar bluelightning32 commented on August 26, 2024

I found this thread too late, and I ended up writing my own boolean operation library too: https://github.com/bluelightning32/walnut

The algorithm is different than Cork's, but there is a design doc explaining it.

from cork.

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.