-
Notifications
You must be signed in to change notification settings - Fork 512
Request: Solvespace as a headless/guiless library for programmatic modelling #375
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
No. SolveSpace's internal modeling functions assume that they are always called with correct arguments. If this is not the case, the entire application (or anything that embeds SolveSpace) will abort. This does not apply to the constraint library because it is carefully designed to avoid this problem--although error reporting is almost entirely missing, the amount of invariants is far smaller and this is a tractable problem. Doing what you want such that it is actually usable would require a complete restructure of the entire application. |
Can it be possible in the future version? I see mixed manual and programmed modelling |
This is an obvious improvement, but there are two issues.
As there is no one at the moment who can invest several person-years of work into refactoring SolveSpace, you should not expect this to happen any time soon. |
I did NOT request a Python API. It was just an example. |
Besides, if anything which plays nice with outside c++ code exist, |
A Python or Lua API is something that has long been planned. |
I'd appreciate it. However, I'd personally avoid an additional After that, providing python, Lua, whatever... layer becomes trivial. |
Unfortunately, converting a standalone C++ application into an usable embeddable library is a task far more complex than the already extremely complex task of adding error handling to external APIs. As such I do not see it as a priority. |
That's understandable. But I'd love to see this issue as "Open" |
As I currently see it, there's essentially no chance this will happen. There's no point in making the issue tracker a wishlist of items that will not happen. |
Can solvespace expose its internal modelling functions as an
API so that it makes programmatic CAD model generation possible?
For example https://docs.blender.org/api/current/ enables
headless usage. It is a large api and uses python.
(There is also Openscad.)
I do not think it is a good idea to embed python in solvespace.
But just stripping solvespace's GUI functions and exposing (and
documenting) modeling functions as a c++ library will enable many
interesting options.
Infact, exposing constraints library is already a similar move.
Is it also possible for modelling functions?
The text was updated successfully, but these errors were encountered: