ents = Sketchup.active_model.entities
sel = mod.selection
matrix = Array.new
matrix += [10,0,0,0]
matrix += [0,10,0,0]
matrix += [0,0,10,0]
matrix += [0,0,0,1]
trans = Geom::Transformation.new(matrix)
sel.each { |ent|
ents.transform_entities(trans, [ent])
}
Sketchup 通过矩阵变换选择集 ruby
SketchUp矩阵变换
本文介绍了一种使用Ruby脚本在SketchUp中实现选择集的矩阵变换方法。通过定义变换矩阵并应用到选定实体上,实现了模型尺寸的统一放大。此过程涉及阵列构造及几何变换的应用。
1225

被折叠的 条评论
为什么被折叠?



