Blender 3D – sin mesh object with python.

This is a simple example of creating one object from vertices and edges using sin function.
First, you need to create the mesh with bpy.data.meshes.new.
The number is random, you can use any number for vertices and edges.
This number is points for drawing the sin function.
The spaces variable is the range from these points.
Using for statements we can draw the sin function.
The last step is to add all of this into one object named sin.
This object will be linked to the scene.
See the source code of this tutorial:

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.