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 viewer

I tried in the v7 but it's the same result.

Thanks


回答1:


When you're unable to access the object tree of a model on a mobile device, you're likely hitting memory limits of the Forge viewer, and you can try to bypass those by explicitly setting the memory.limit config property to zero:

viewer = new Autodesk.Viewing.Private.GuiViewer3D(
    document.getElementById('viewer'),
    { memory: { limit: 0 } }
);


来源:https://stackoverflow.com/questions/58236652/instancetree-unavailable-in-the-mobile-version-of-the-viewer

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!