Draw Sine Waves in Blender Python

sine.py


import bpy
import math

for n in xrange(360):
    x = n
    y = math.sin(n * 20 * math.pi / 180.0) * 10
    bpy.ops.mesh.primitive_cube_add(location=(x * 10, y * 10, 1))

You can express a sine wave with a cube in 3D space. Please use it to make a 3D stage.

Recommended Posts

Draw Sine Waves in Blender Python
Draw graph in python
Draw mp3 waveform in Python
Draw Poincare's disk in Python
Draw "Draw Ferns Programmatically" in Python
Draw implicit function in python
Blender Python API in Houdini (Python 3)
Draw a heart in Python
Generate 8 * 8 (64) cubes in Blender Python
Draw knots interactively in Plotly (Python)
Draw a scatterplot matrix in python
Draw a CNN diagram in Python
Get started with Python in Blender
Draw Nozomi Sasaki in Excel with python
Draw a heart in Python Part 2 (SymPy)
To reference environment variables in Python in Blender
Python interpreter in Maya, Houdini, blender, Nuke
Draw a tree in Python 3 using graphviz
Quadtree in Python --2
Python in optimization
CURL in python
Metaprogramming in Python
Python 3.3 in Anaconda
Geocoding in python
SendKeys in Python
Meta-analysis in Python
Unittest in python
Epoch in Python
Discord in Python
Blender 2.9 Python Extrude extrude
Sudoku in Python
DCI in Python
quicksort in python
nCr in python
N-Gram in Python
Programming in python
Plink in Python
Constant in python
Lifegame in Python.
FizzBuzz in Python
Sqlite in python
StepAIC in Python
N-gram in python
LINE-Bot [0] in Python
Csv in python
Disassemble in Python
Reflection in Python
Constant in python
nCr in Python.
format in python
Scons in Python3
Puyo Puyo in python
python in virtualenv
PPAP in Python
Quad-tree in Python
Reflection in Python
Chemistry in Python
Hashable in python
DirectLiNGAM in Python
LiNGAM in Python
Flatten in python