【发布时间】:2020-10-19 11:28:47
【问题描述】:
第一个问题:缺少房间模型
我使用 Forge 的模型衍生 api 和 generateMasterViews 参数从云 Revit 模型 (BIM360Team) 中提取房间节点,它对于某些模型工作得很好,但我遇到了其他模型缺少房间的问题。
一些翻译模型的房间节点丢失了,这很奇怪,因为它们的高度和相位相同,并且显示了 2d 视图中的房间。
2D views has no problem at all
3D room nodes in the same floor were missing
所以我的问题是,它们在提取房间几何图形并转换为 .svf 文件方面是否存在一些限制?例如发布视图设置/视图范围/裁剪视图/裁剪区域?还是我的请求中缺少的东西?我尝试对齐所有参数或删除某些组件(例如家具),但结果仍然相同。如果你们之前注意到这个问题,请帮助,我们将不胜感激。
第二个问题:房间网格和材料
我已经编写了一个函数来突出显示选定的元素,并且它几乎适用于除房间元素之外的所有节点。
const highLightElement = (dbId, hexColor) => {
const myMaterial = createMaterial(hexColor)
const instanceTree = viewerApp.model.getInstanceTree()
const fragList = viewerApp.model.getFragmentList()
instanceTree.enumNodeFragments(dbId, function(fragId) {
fragList.setMaterial(fragId, myMaterial)
const fragProxy = viewerApp.impl.getFragmentProxy(viewerApp.model, fragId)
fragProxy.scale = new window.THREE.Vector3(scaleRatio, scaleRatio, scaleRatio)
fragProxy.updateAnimTransform()
}, true)
viewerApp.impl.invalidate(true)
}
房间的材料是阴暗的白色,但如果在上面使用剖面工具,剖面颜色已经变成了我选择的颜色(0xAB00EE - 洋红色)。不知道是房间网和其他的不一样吗?或者可能需要一些特殊程序才能这样做?
【问题讨论】:
标签: autodesk-forge autodesk-model-derivative