autodesk-viewer

Instance of ModelStructurePanel in div outside the viewer GUI

风流意气都作罢 提交于 2021-02-11 14:46:31
问题 I am building an html page with model query functionality starting from the viewer. I have implemented some methods including viewer.getProperties () and viewer.getBulkProperties (). Working on these themes I realized that it would be very useful to create instances of the panels (modelstructure, properties etc ...) in elements external to the viewer (not in the docking panels), maintaining the functionality and if possible customizing them (for example showing the elements not -collapsed).

Autodesk Forge: I created an app to translate CAD files, but cannot see properties for an assembly

烂漫一生 提交于 2021-02-11 14:19:31
问题 So I created a nodejs app to translate CAD files and to display them in the viewer. For .rvt files and individual Inventor components I can see the properties by going to Model Browser and clicking on each component, however, I cannot see properties for an entire Inventor assembly. How can I go about seeing assembly properties? I am using this sample: https://github.com/Autodesk-Forge/viewer-walkthrough-online.viewer Only change I made was set compressedUrn to true and added a rootFileName to

Default material for model in Forge Viewer

好久不见. 提交于 2021-02-11 13:23:40
问题 I'd need to have the complete model use a default material (e.g. grey color) and then use externally defined materials for each node. So I'm looking for some advice on two points: 1) Setting a default material on all nodes. 2) Setting the material / color for given nodes after they're fetched from an external source. Could this be done at some point before the model is loaded into the viewer? (i.e. server-side)? If not, can it be done in the viewer? 回答1: All geometry coming from Forge will

Forge Viewer - Failed to parse OTG

醉酒当歌 提交于 2021-02-11 13:10:38
问题 I am using the Forge Viewer APIs to visualize OTG models (from our BIM360 account) into our web application. All used to work fine in the last few months but since this morning i started to receive some browser errors related to the OTG geometry Invalid OTG heders Failed to parce OTG geometry Failed to parse geometry ﵌䐮砦溔헜縗ﭤ촧퐤 Error loading mesh ﵌䐮砦溔헜縗ﭤ촧퐤 (some logs are displayed in chinese languange and all of them are repeated multiple times into the browser console) the result reflect an

InstanceTree unavailable in the mobile version of the viewer

眉间皱痕 提交于 2021-02-11 13:09:26
问题 I have a function who require the instanceTree of my model who works in the desktop browser. instanceTree = viewer.model.getData().instanceTree; dbIds = getAllDbIds(instanceTree); But in the mobile version of the viewer, the instanceTree from getData() seems to be missing for some reasons. Do you know a way to access the instanceTree in the mobile viewer ? Or is it possible to specify an option in the viewer to allow the mobile version to have access to it ? I'm in the version v6 of the

How do I display a thumbnail that has been generated after translation

不问归期 提交于 2021-02-11 07:00:09
问题 After translating a file to SVF I can see that there is thumbnails that have been generated. How do I use the URN to display these thumbnails? Thanks! 回答1: You can use the Thumbnail endpoint to download the picture, but it requires the Token. So you can, for instance, download it on your server-side (with the token) and redirect the stream to the client-side (from your server). Here is the thumbnail endpoint: '/modelderivative/' + MD_PROJECT_VERSION + '/designdata/' + urn + '/thumbnail?width

Forge tool handleButtonDown and handleButtonUp functions not getting called

倖福魔咒の 提交于 2021-02-10 19:54:58
问题 I was looking at the sample code for the tutorial at https://forge.autodesk.com/blog/custom-window-selection-forge-viewer-part-iii which is located at https://github.com/Autodesk-Forge/forge-rcdb.nodejs/blob/master/src/client/viewer.components/Viewer.Extensions.Dynamic/Viewing.Extension.SelectionWindow/Viewing.Extension.SelectionWindow.Tool.js as well as the documentation at https://developer.autodesk.com/en/docs/viewer/v2/reference/javascript/toolinterface/ --- Most of these functions are

Forge tool handleButtonDown and handleButtonUp functions not getting called

扶醉桌前 提交于 2021-02-10 19:53:57
问题 I was looking at the sample code for the tutorial at https://forge.autodesk.com/blog/custom-window-selection-forge-viewer-part-iii which is located at https://github.com/Autodesk-Forge/forge-rcdb.nodejs/blob/master/src/client/viewer.components/Viewer.Extensions.Dynamic/Viewing.Extension.SelectionWindow/Viewing.Extension.SelectionWindow.Tool.js as well as the documentation at https://developer.autodesk.com/en/docs/viewer/v2/reference/javascript/toolinterface/ --- Most of these functions are

How to set opacity of each nodes

风格不统一 提交于 2021-02-10 14:21:17
问题 Is there anyway to set opacity of some nodes of the model? For instance, create a override material and use it in renderer for some nodes rather than whole scene. 回答1: When loading a model, the viewer builds its internal spatial indexing structures (BVHs), and one of the factors it takes into account is the transparency of the different fragments. This is in order to ensure that semi-transparent objects are rendered after the opaque ones. However, when changing the material of a fragment on

How to set opacity of each nodes

好久不见. 提交于 2021-02-10 14:21:06
问题 Is there anyway to set opacity of some nodes of the model? For instance, create a override material and use it in renderer for some nodes rather than whole scene. 回答1: When loading a model, the viewer builds its internal spatial indexing structures (BVHs), and one of the factors it takes into account is the transparency of the different fragments. This is in order to ensure that semi-transparent objects are rendered after the opaque ones. However, when changing the material of a fragment on