LoginSignup
0
0

More than 3 years have passed since last update.

open3dで円筒を作る+STLファイル出力

Last updated at Posted at 2019-12-10

open3dのインストール
pip install open3d

o3d_cylinder.py
import open3d as o3d
# 1つめ
mesh1 = o3d.geometry.TriangleMesh.create_cylinder()
mesh1.compute_vertex_normals()
# 2つめ
mesh2 = o3d.geometry.TriangleMesh.create_cylinder()
mesh2.compute_vertex_normals()
# (相対)移動
mesh2.translate([0,10,10]) 
# STLで出力
o3d.io.write_triangle_mesh("sample.stl", mesh1+mesh2)

参考
http://www.open3d.org/docs/release/tutorial/Basic/visualization.html

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0