Tyre Tread Tiler

Scripting in Blender with Python, and working on the API

Moderators: jesterKing, stiv

Post Reply
ldo
Posts: 0
Joined: Sun Nov 07, 2010 11:30 pm
Location: Hamilton, New Zealand

Tyre Tread Tiler

Post by ldo » Mon Nov 08, 2010 7:02 am

As an exercise in learning the new Python scripting API in Blender 2.5x, I have been developing a script to generate a tyre from a tread pattern. You make up one copy of the pattern, and it will automatically replicate that around a circle and properly join the copies together.

Is this of interest to anybody else? If so, I’ll stick it on GitHub.

ldo
Posts: 0
Joined: Sun Nov 07, 2010 11:30 pm
Location: Hamilton, New Zealand

Post by ldo » Wed Nov 17, 2010 9:12 am

It is now on GitHub https://github.com/ldo/treadtiler.

The script still has a couple of limitations:
  • * The lines of selected vertices for joining cannot form loops. This is because I need to know where they begin and end, so I can match up the ends for joining.
  • * The beginning and ending points on each line cannot even coincide; there must be a small separation between them. This is because I compute the respective slopes between them to figure out whether I’ve got the vertices of one line reversed with respect to the other or not.
These limitations mean that if you want to generate a closed toroidal shape, you have to create it with a gap all round, say, the inside, and go around stitching it up afterwards.

Suggestions for getting around these limitations are welcome. :wink:

ldo
Posts: 0
Joined: Sun Nov 07, 2010 11:30 pm
Location: Hamilton, New Zealand

Post by ldo » Wed Dec 01, 2010 9:13 am

I found a way round the limitations: leave the ring open, but TreadTiler itself has a new option to close it for you. Simple!

Post Reply