简体   繁体   English

Forge Viewer Markups 最新版本

[英]Forge Viewer Markups latest version

I created Forge viewer version 7 in my own website.我在自己的网站上创建了 Forge 查看器版本 7。 I'm trying to add markups like the one shown in Autodesk website (see picture below);我正在尝试添加像 Autodesk 网站中所示的标记(见下图);

标记示例

Are there any tutorial for creating markups tool like this?有没有创建这样的标记工具的教程? I found some but they are either outdated version or incomplete.我找到了一些,但它们要么是过时的版本,要么是不完整的。 Please suggest, thank you.请建议,谢谢。

The easiest approach would be to use the built-in MarkupsGui extension which provides UI to create markups:最简单的方法是使用内置的MarkupsGui扩展,它提供 UI 来创建标记:

NOP_VIEWER.loadExtension("Autodesk.Viewing.MarkupsGui")
//or turn on the extension during initialization
new Autodesk.Viewing.GuiViewer3D(container,{extensions:['Autodesk.Viewing.MarkupsGui']})

Then a button will appear in the toolbar to trigger the extension:然后工具栏中会出现一个按钮来触发扩展:

在此处输入图像描述

Alternatively you can come up with your own UI and leverage the MarkupsCore extension which is also built-in to programmatically switch between markup tools and even create markups programmatically, see documentation here或者,您可以提出自己的 UI 并利用MarkupsCore扩展,该扩展也是内置的,以编程方式在标记工具之间切换,甚至以编程方式创建标记,请参阅此处的文档

You can either call or extend these to create your own custom extension.您可以调用或扩展这些以创建您自己的自定义扩展。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM