Hi, I´m quite new to Rhino and happy to have it on the Mac Platform. I´m in the need of creating some simple gears and wonder if the Script gearGen from Thomas Anagnostou in the link below will also work on Rhino for Mac ?
thanks for your reply, really just simple gears for a 3D print of a motorised trolley. Right now my workaround is to get the gears in 2D from gear generator.com and use them as template to recreate the gears.
That plugin was done in vb if I recall correctly, and some months back I posted on it asking if anybody was willing to port it to python, as I don’t have any python chops whatsoever. Never heard anything after that.
I think the main problem here is that the original script is over 700 lines, and a little hard to decipher. A lot of it was written back when Rhinoscript did not have a lot of UI possibilities, so much of the script deals with the UI choices… The actual math part is not all that big. It could probably be reduced to a couple of hundred lines or so in Python, but I think it would take at least a full day to go through and try to convert it/clean it up. (for me at least)… It is reasonably well commented inside the script, so that will help.
Can the Mac version of Rhino load compiled python scripts, looking at the the wip version there’s something about it having support for plugins.
If it does allow loading compiled scripts here’s a wip gear generator, it’s not based on Thomas’s version and works a little differently.
After loading the plugin you get a new command DrawGear, when you run the command first you are prompted to choose Module or Diametric pitch.
Then you get a dialog to enter the gear spec’s.
If all goes well when you click OK you should get a gear drawn at the origin of the current cplane.
I’ve only tested working in millimetres I guess if you work in inches it’ll need scaling by 25.4, I’m not sure how to deal with working with different unit.
Hi Manuel
save the script in this directory replacing Angela with your username:
C:\Users\Angela\AppData\Roaming\McNeel\Rhinoceros\5.0\scripts
creates a new button where write -__RunPythonScript (IngranaggioDentiDritti_Mac)
Clicking on the button run the script
Ciao Vittorio
Yeah, looks like Mac Rhino doesn’t support the rhinoscriptsyntax rs.PropertyListBox() method yet. There are a few rhinoscriptsyntax methods that are not yet implemented on Mac Rhino, basically stuff concerning the UI. So in order for this script to run on Mac Rhino currently, the user input collection now performed with rs.PropertyListBox() would need to be transformed into something that could be entered on the command line, either as a successive set of numbers or a string of command line options…