🤑 Indie game store🙌 Free games😂 Fun games😨 Horror games
👷 Game development🎨 Assets📚 Comics
🎉 Sales🎁 Bundles

makeshifted

1
Posts
2
Followers
A member registered Feb 18, 2017 · View creator page →

Project

Recent community posts

(Edited 1 time)

For this robot (Haddington Dynamics' Dexter), I downloaded the Collada/.dxf files from: https://cad.onshape.com/documents/2af8ed0e61a34ebf...

Then, I arranged all the parts into a transform hierarchy in Unity3D (a popular game engine), and rotated the models such that they were all pointed upward when their joints were in the identity rotation.

Then I wrote a simple Constrained CCDIK solver that orients that transform chain to touch the pink sphere. The source for that is available here: https://github.com/zalo/MathUtilities/tree/master/...

The version in the embedded demo simply attempts to find the minimal rotation necessary to make the tooltip match the sphere, but the one in the above source also attempts to match the direction that the sphere's forward vector is pointing (since this is a 5-DoF robot after all). You can disable that functionality if you want by simply deleting ", j < 2" in the CCDIK.cs file (this tells it to treat the last two joints differently than the rest).

The above github repo replaces the Dexter models with scaled cubes because the Dexter models are licensed funnily and they ballooned the file size.

If you decide to stick with Python, hopefully you have a good technique for representing transform hierarchies and ways of constructing rotations from a pair of directions. Here's a good place to get started on implementing that function (since my world-space CCDIK makes extensive use of it: https://web-beta.archive.org/web/20161105145605/http://lolengine.net/blog/2014/02/24/quaternion-from-two-vectors-final ).