本文介绍了forceDoubleSided 设置的问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要激活配置文件设置 forceDoubleSided 才能正确显示从具有镜像外部参考的 Revit 项目派生的模型.

I need to activate the profile setting forceDoubleSided in order to display properly a model derivated from a Revit project that has mirrored external references.

使用最新版本的 Forge Viewer,当我调用 new GuiViewer3D(container, config) 时,我在 config 参数中设置了配置文件设置,并且在加载模型时,材料属性 "边"= 2 (THREE.DoubleSide) 看起来不错.

Using the latest version of the Forge Viewer, I set the profile settings in the config parameter when I call new GuiViewer3D(container, config) and, while the model is loading, the materials property "side" = 2 (THREE.DoubleSide) and it looks good.

问题在于模型加载后或使用切割平面扩展后,因为材料侧"然后将其重置为 0 (THREE.FrontSide),因此模型不再正确显示.

The problem is when the model has loaded, or after have used the cutting plane extension, because the materials "side" is then reset to 0 (THREE.FrontSide) so the model stops looking correctly.

作为一种解决方法,在 GEOMETRY_LOADED_EVENT 和 CUTPLANES_CHANGE_EVENT 事件中,我每次都执行 _viewer.impl.setDoubleSided(true, _viewer.model).

As a workaround, in the GEOMETRY_LOADED_EVENT and CUTPLANES_CHANGE_EVENT events I am executing _viewer.impl.setDoubleSided(true, _viewer.model) every time.

这似乎是查看器中的一个错误......有没有更好的方法来处理这个问题?

It seems like a bug in the viewer... is there a better approach to handle this problem?

推荐答案

这听起来像是一个错误.让我通知工程团队,感谢您的报告!现在,请继续手动覆盖边性"根据需要.

That does sound like a bug. Let me notify the engineering team, and thanks for reporting it! For now, please continue manually overriding the "sidedness" as needed.

这篇关于forceDoubleSided 设置的问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-05 03:29