Programmatically determining how two parts can interact - Printable Version +- LDraw.org Discussion Forums (https://forums.ldraw.org) +-- Forum: LDraw Programs (https://forums.ldraw.org/forum-7.html) +--- Forum: LDraw Editors and Viewers (https://forums.ldraw.org/forum-11.html) +--- Thread: Programmatically determining how two parts can interact (/thread-27862.html) |
Programmatically determining how two parts can interact - Mark Elwin - 2023-12-06 Hello, I have a software friend who would like to process pairs of LDraw files and determine how they may interact. This is clearly part of the LDraw program, as the user interface allows users to do this; and so I am wondering whether that software is open source or a more experienced administrator could help us understand how to read and interpret the code. Would love any and all help in this direction. We are very excited. RE: Programmatically determining how two parts can interact - Travis Cobbs - 2023-12-06 (2023-12-06, 13:46)Mark Elwin Wrote: Hello, I have a software friend who would like to process pairs of LDraw files and determine how they may interact. This is clearly part of the LDraw program, as the user interface allows users to do this; and so I am wondering whether that software is open source or a more experienced administrator could help us understand how to read and interpret the code. Would love any and all help in this direction. We are very excited. This is not part of LDraw, but instead a separate snapping database that LDCad maintains. It's worth mentioning that since this database is manually created and maintained, it won't necessarily be exhaustive. In any event, Roland Melkert, the author of LDCad, can hopefully help you. (I know about the existence of LDCad's snapping database, but don't know anything about its details.) RE: Programmatically determining how two parts can interact - Roland Melkert - 2023-12-07 (2023-12-06, 17:13)Travis Cobbs Wrote: This is not part of LDraw, but instead a separate snapping database that LDCad maintains. It's worth mentioning that since this database is manually created and maintained, it won't necessarily be exhaustive. In any event, Roland Melkert, the author of LDCad, can hopefully help you. (I know about the existence of LDCad's snapping database, but don't know anything about its details.) I released the LDCad snapping information on GitHub awhile ago, it's free to use as long you share any derived data for free too (CC-BY-SA-4.0 license). https://github.com/RolandMelkert/LDCadShadowLibrary documentation (slightly out dated) https://www.melkert.net/LDCad/tech/meta A (compressed) version of it is included in the latest LDCad too. But please note this information was always only intended as a placement helper during editing, it isn't suited for full-blown physics etc. RE: Programmatically determining how two parts can interact - Mark Elwin - 2023-12-26 (2023-12-07, 20:09)Roland Melkert Wrote: I released the LDCad snapping information on GitHub awhile ago, it's free to use as long you share any derived data for free too (CC-BY-SA-4.0 license). Roland and Travis: first, thank you so much for your responses. My delay was due to a notifications issue, not disinterest. I will spend the afternoon reading the GitHub repository, and revisiting LDraw, and I suspect I have a fairly good intuition for how this works on the basis of the LDraw format. I am somewhat surprised that you describe this as being used only for "auto part snapping," as I had presumed LDraw only allowed auto-snapping into narrowly defined legal LEGO moves. What am I missing about my intuition here? I will make any derived data open source either through a separate repository or pull request, whichever is preferred or easier to maintain. If you are interested in Blender, here is what I have started. I am eagerly looking for a network to help peer-review, expand, and use this project. :) Please also feel free to share with whomever may be interested in using or contacting me, and demonstration videos will go up soon enough. https://github.com/markelwin/LEGO.Emulation.Environment RE: Programmatically determining how two parts can interact - Mark Elwin - 2023-12-30 Editing. |