Several times I have been confronted with wanting to represent 3d data in a quick program I’ve thrown together in python/tkinter and each time I have leveraged the use of an external viewer (Patran, Autocad, Solidworks, etc) to manipulate and edit data once it’s generated. I’ve finally had enough of this patching and I put together a python/tkinter implementation (buggy at the moment and almost useful). I could have used numpy to handle some of the math, but I was trying to avoid the dependency so I put together a matrix handler (it could use some refactoring and cleaning as well), Coordinate system handler and coded in the basics of a point and a line (i.e. wireframe mode…). I have worked on something similar to this in C++ and Java and borrowed from the way Java3d handled the transforms. I’ll put the packages here and update more once it’s cleaner.
The pictures below are from Spyder and its showing the visual transforms performed on the visible/screen geometry. (actual point data remains unchanged after manipulations)
The code set is here: https://sourceforge.net/projects/derekgportfolio/files/PythonTkCanvas3d/