在revitAPI中有pipe类,位于Autodesk.Revit.DB.Plumbing下面,pipe类中创建管道有以下几种方法:
今天我们主要介绍第3种,利用起始点创建管道。因为该方法与dynamo结合使用较方便,该方法需要输入以下参数:
document--Type:Autodesk.Revit.DB.Document 文档
systemTypeId--Type:Autodesk.Reivt.DB.ElementId 管道系统的ID
pipeTypeId--Type:Autodesk.Reivt.DB.ElementId 管道类型的ID
levelId--Type:Autodesk.Reivt.DB.ElementId 管道所在标高的ID
startPoint--Type:Autodesk.Reivt.DB.XYZ 管道的起始点
endPoint----Type:Autodesk.Reivt.DB.XYZ 管道的终点
systemTypeId、pipeTypeId、levelId的数组我们可以通过dynamo自带的过滤器得到
节点连接和运行结果见下图:
python节点内容如下:
import clr
clr.AddReference('ProtoGeometry')
from Autodesk.DesignScript.Geometry import *
clr.AddReference("RevitAPI")
import Autodesk
clr.AddReference("RevitServices")
import Re