Нерешенные задачи

Подписаться на эту рубрику по RSS

Вызов новому исследователю. «Великие идеи предпочитают посещать подготовленные умы» (Луи Пастер)

Push/pull for the poor

One of the topics I'm spinning around for years is this "direct editing" business. We have even devoted a couple of work sessions with students at our seminars to prototype push/pull operation. The approach was a real mess, and it was not going to work anyway. [Because] This is how we did it:

  1. We used prisms to represent the volumes swept by pushed/pulled faces (we'd better use offset faces, at least in simple cases).
  2. The prisms were fused or subtracted from the entire body (none of Booleans is a local operation).
  3. No feature recognition was applied, so the "design intent" thing was completely screwed up.

Why I think direct editing worth the efforts is that it truly unlocks shape modification. There are so many opinions on the subject and so many "direct vs history-based" holy wars that I'm lost trying to pick up a good motto to justify this article. It's too apparent, and it has been discussed so many times. One thing which might challenge us as the CAD developers (i.e., programmers) is creating a powerful "geometric kernel" (this term has become so popular that I tend to avoid using it). The "kernel" has to be intelligent enough to drive B-rep modification in a meaningful way, i.e., not shock the user with "mathematically correct" BS. As Matt Lombard says, the cutting-edge CAD software should not ground itself on the intelligence in the data (features and sketches). It should rather be intelligent in its algorithms (feature recognition).

I'm ready to give all sorts of credits to the software like FreeCAD or the recently released CAD Builder package, but the paradigm behind both is a way too old to amaze. Although these packages are open-sourced, and that very fact already puts them aside from the walled gardens of big commercial players, they all employ the same old paradigm: feature-based design. It is all old news, even if it gets published tomorrow. What would really rock is an open-source geometric library that's intelligent enough to allow for direct modeling. That should be a library bringing the following vital ingredients together (we have briefly summarized some of them here):

  • Efficient direct modeling armed with feature recognition.
  • Several representations interacting (like mesh, NURBS, T-splines, subdivision surfaces all in a single framework).
  • Constraint solver to build up a model from intermediate sketches.
  • You may think of something else, but it has to be of a geometric nature (hence, please, do not mention clouds or this misty "inherent parallelism" mantra).

Such a kernel does not exist yet. There's little an individual can do about this, as developing a geometric core is a team sport. Even worse, it's a long shot. For people aimed at earning big bucks, it's definitely more profitable to invest in the engineering use cases rather than in the backbone technology. A business following the MVP concept ("Minimal Viable Product" if you're not familiar with these start-up buzzwords) would start from making a product that solves a real problem. It's too expensive and uncertain to spend years developing something like OpenCascade just to give it clean architecture, efficiency, and new features readily available in the commercial libraries. Nobody's gonna start from this. Then, if the MVP hits the market demands, it's more likely that the limited open-sourced solution will be dropped from the product to substitute it with some proven commercial libs (that's what happened to Shapr3D). There are many reasons for such a turn. The most obvious is probably the intention to focus on the core business, leaving all the geometry stuff to its maintainers.

Well, all these speculations bring us too far from the subject. Developing our CAD simplification toolbox, we learned many lessons about software design and geometry editing. A careful reader may find a lot on this blog's pages, but to confess, we have not touched the realm of direct modeling so far. For us, this is predominantly terra incognita, although we already have a bunch of powerful defeaturing tools implemented in a truly scientific yet practical way. Defeaturing itself is a part of direct editing (unless we talk about rolling back a feature tree), though DE is more about dragging and turning faces.

Long story short, after playing a lot with a sample part to simplify it in a "direct" manner, I noticed how useful push/pull might be. Even such a ridiculous prototype mentioned in the beginning might be of some help as the following animation proves:

The magic of OpenCascade's prisms and Booleans.

Back in 2008, there was an intriguing article by Dmitry Ushakov covering a few aspects of a direct modeler. Looking at many available videos on Siemens' Synchronous Technology (ST), one could easily match these two sources of information and deduce the ingredients of a DE-capable kernel: constraint solver and modeling engine. The solver interplays with the boundary representation of a model to preserve the design intent specified as a bunch of constraints (parallelism, coaxiality, angles, etc.). After many years passed, we see that the direct editing "philosophy" was definitely ignored by the open-source CAD community. And it is not really obvious, why?

On Medium.com