获取文件名在Auto Desk Forge中打开

发布于 01-22 05:27 字数 330 浏览 4 评论 0原文

在问题中: 如何从Forge Viewer中检索文件名?

我使用了此:

nop_viewer。 model.getData()。loadOptions.bubblenode.getRootnode()。儿童[0] .name(),

但是此名称仅返回第一个文件rvt i Open。我打开2个文件,仅返回第一个文件名,因此如何返回第二文件的名称?

In the question :
How to retrieve filename from Forge Viewer?

I used this :

NOP_VIEWER.model.getData().loadOptions.bubbleNode.getRootNode().children[0].name()

but this name only return first file rvt i open . I open 2 file , only return first file name open So how to return the name of the 2nd file ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

对岸观火2025-01-29 05:27:55

加载的型号由NOP_Viewer.getAllModels()管理。因此,您可以找到诸如

  model = NOP_VIEWER.getAllModels()[1]  //the second model

并调用的

   model.getData().loadOptions.bubbleNode.getRootNode().children[0].name()

特定模型,还有另一个模型集合仅告诉可见模型。

   NOP_VIEWER.getVisibleModels()
   

the loaded models are managed by NOP_VIEWER.getAllModels(). So you can find specific model such as

  model = NOP_VIEWER.getAllModels()[1]  //the second model

and call

   model.getData().loadOptions.bubbleNode.getRootNode().children[0].name()

There is also another model collection which tells the visible models only.

   NOP_VIEWER.getVisibleModels()
   
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文