0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

windows11で、sketchup6 その80

Posted at

概要

windows11に、sketchup6を入れてみた。
rubyで、3Dを書く。
練習問題、やってみた。

練習問題

丸い穴を開ける、rubyスクリプトを書け。

写真

image.png

サンプルコード

def create_donut2
	entities = Sketchup.active_model.entities
	tube = entities.add_group
	tube_inner = tube.entities.add_circle Geom::Point3d.new(0, 0, 0), Geom::Vector3d.new(0, 0, 1), 4, 24
	tube_outer = tube.entities.add_circle Geom::Point3d.new(0, 0, 0), Geom::Vector3d.new(0, 0, 1), 8, 24
	cross_section_face = tube.entities.add_face tube_outer
	inner_face = tube.entities.add_face tube_inner
	tube.entities.erase_entities inner_face
end

以上。

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

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?