autodesk-forge - 通过单击对象插入标签
解决方案
要获得准确的 x、y、z 值,请使用此“ALT 键枢轴点”技术来获得模型的表面点,而不是其质心:
https://github.com/wallabyway/markupExt/issues/2
第二部分:
获得 x、y、z 值后,您可以在这篇文章中替换“质心”位置计算:
https://forge.autodesk.com/blog/placing-custom-markup-dbid
// get the center of the dbId (based on its fragIds bounding boxes)
const pos = this.viewer.worldToClient(this.getModifiedWorldBoundingBox(id).center());
这有帮助吗?
推荐阅读
- wso2 - 无法修改共享应用程序 WSO2 APIM 2.6.0
- system - 如何验证我的硬件预取器是否已禁用
- javascript - 如何添加边框以使元素看起来像一棵树并在调整大小时保持正确定位?
- sql - 创建数据透视表的“参数太多”错误?
- javascript - 如何将滚动条置于垂直位置以及如何使用向上和向下箭头移动图像?
- r - 将两个动画情节组合成一个 GIF/MP4
- javascript - 有没有办法搜索对象中的特定键,然后记录结果?
- c# - C#乐观并发无响应
- vagrant - Vagrant:从客户端连接到本地 https 站点
- javascript - 扩展类在子方法和父方法之间移动