New Browser-based CAD System Is Best Friends With Triangle Meshes

Who’s interested in a brand new, from-scratch boundary representation (BREP) kernel? How about one that has no topological naming problem, a web-native parametric CAD front end to play with, and has CAD-type operations making friends with triangle meshes? If you’re intrigued, check out [mmiscool]’s BREP project.

Functioning (let alone feature-filled, or efficient) CAD systems are not a software project we see a whole lot of. Ones that represent models as genuine BREP structures but cleverly use mesh-based operations where it makes sense? Even less so.

In theory, CAD programs are simple: allow a user to define features, keep track of what they are and how they relate to one another, and perform operations on them as requested. In practice, it’s significant work. Chains of operations and dependencies easily become complex, volatile things and there is really no room for error.

Read [Arya Voronova]’s best practices for using FreeCAD to get a few hints as to what goes on behind the scenes in a modern CAD program, and the kinds of challenges the back end has to deal with, like the topological naming problem (TNP). A problem [mmiscool]’s implementation completely avoids, by the way.

There is a live demo at BREP.io which acts as a playground for the state of the project. You can get started by clicking the + button towards the top on the left panel to add features and operations to the history (like add a cube, then add chamfers or fillets, or extrude a face, and so on).

[mmiscool] points out that all computation is done client-side; even complex operations like fillets, lofts, and multi-body booleans execute directly in the browser with no need to be offloaded to a back end. BREP’s development is being documented on Hackaday.io and there is a video embedded below that gives an overview. Why don’t you give it a spin?

11 thoughts on “New Browser-based CAD System Is Best Friends With Triangle Meshes

  1. “What would truly be a novelty is if CAD programs could, through AI, propose the next ‘logical’ step during the construction of a part, in the same way they currently indicate midpoint/intersection or endpoint.

  2. I’m not familiar with the inner workings of CAD programs so can anyone explain why TNP is an issue on freecad while this small web based tool is free from it.

    Seems like the only limiting factor to an otherwise perfectly usable piece of software

    1. Take an simple construction, a cube where you want to subtract another cube from. Make the 2nd cube position and size parametric, so user can change it when he want. The next operation is to add a fillet to the edge on the difference of the 2 cubes. You now have a TNP issue.

      If the 2nd cube is larger than the first one and only intersecting with the first one, the fillet will apply to a single edge that’s the same size as the first cube side length.
      If the 2nd cube is smaller than the first one, thus the subtraction would make a “U” shape on one side of the inner edge of the “hole” in the first cube and as such doesn’t link anymore with the first cube’s own edge. So the fillet can’t apply in that case, and it’s broken.

      What should the software do? Apply the fillet to all 4 edges of the hole ? Only select one edge of this hole ?

      The software can’t choose for you, the part is now broken, you need to fix the change by hand.

      The number of possible geometries with simple basic shape explodes completely (its more than an exponential growth). So it’s not possible to solve the problem, whatever the software. At best, the software can have some heuristics to make some decision for you and it’ll bother you less or more. Previous version of FreeCAD (before 1.0 version line) was particularly bad at this and it’s now way better. This software tries to reuse the same logical ideas as FreeCAD in its topology naming to avoid the obvious case.

    2. FreeCAD names the faces and edges in numeric order, e.g. “Face1”, “Face2”. This software names them by object they originate from, such as “CU6_NX” (cube 6, negative x).

      By itself this is more robust against TNP, and is that natively unlike FreeCAD where the recent TNP fixes just patch the numbers when things change.

      However brep.io’s data model seems to have some limitations. It appears that even if another object in boolean union goes fully edge-to-edge over a face, it doesn’t split into two faces. This seems to cause e.g. chamfers act weird: https://i.imgur.com/NvfMbGb.png . But I expect that to eventually get fixed.

      1. Now that is a really silly response.
        I use a web browser for browsing the web, and for that it’s adequate.

        I have no intention of stuffing the rest of my life (or pc usage) into a web browser.

Leave a Reply to ImanCancel reply

Please be kind and respectful to help make the comments section excellent. (Comment Policy)

This site uses Akismet to reduce spam. Learn how your comment data is processed.