如何在Autodesk Forge中为背景添加自定义环境贴图? [英] How to add custom environment map for background in autodesk forge?

查看:327
本文介绍了如何在Autodesk Forge中为背景添加自定义环境贴图?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想为背景添加环境贴图,我尝试过使用viewer.setLightPreset(value),但是我不喜欢默认贴图.我需要为背景添加自定义环境贴图.我了解了

I want to add environment map for background,I have tried viewer.setLightPreset(value) ,but I don't like the default map.I need to add custom environment map for background.I learned about Add Custom Light for the View and Data API Viewer,and added this code in my viewer

 Autodesk.Viewing.Private.LightPresets.push({
      name: "selfEvn",
      path:"selfEvn",
      type:"logluv",
      tonemap:1,
      E_bias: -2.0,
      directLightColor: [0, 0.84, 0.67],
      ambientColor: [0.8, 0.9, 1],
      lightMultiplier: 0.1,
      bgColorGradient: [230, 230, 230, 150, 150, 150],
      darkerFade: !1
 });

 viewer3D.setLightPreset(Autodesk.Viewing.Private.LightPresets.length - 1);

Forge的文件与dds后缀文件一起使用.我为dds后缀文件制作了宽度为Adobe Photoshop的NVIDIA Texture Tools,并将其放在以下路径下:res \ environments.但是查看器无法使用我的文件.路径下的defaulet文件:res \ environments,它们就像这样默认文件我不知道我的方法是否错误或文件是否错误我的文件就像图像一样,但是后缀是DDS. 我的模型是由Revit创建的

Forge's file is used with the dds suffix file.I made the dds suffix file width NVIDIA Texture Tools for Adobe Photoshop,and put it under this path: res\environments.But viewer can't use my file.I opened the defaulet files under the path: res\environments,they are just look like this Default files.I don't know if my method is wrong or my files are wrong My files are just like images,but their suffix is DDS. And my model was created by Revit

推荐答案

与开发团队联系后,没有API可用于为Revit和Model Derivative中的模型转换和设置用户拥有的背景图像(环境图)当前翻译.自定义背景图像功能仅适用于Autodesk Fusion 360的模型,但是从Fusion模型转换图像存在一个已知问题,目前由开发团队进行了调查.对于给您带来的不便,我们深表歉意.

After checking with the dev team, there is no API available for converting and setting user owned background image (Environment map) for models from the Revit and the Model Derivative translation currently. Custom background image feature is only available for models of the Autodesk Fusion 360, but there is a known issue for image translating from the Fusion model which is investigated by the dev team now. We apologize for any inconvenience caused.

此外,我们无法确保这些私有API的确定性和稳定性.专用API仅用于Froge Viewer的内部使用.因此,不建议在Autodesk.Viewing.Private命名空间下使用这些API来像您一样与开发人员合作.

In addition, we cannot ensure the certainties and the stabilities of those private APIs. Private APIs are only for the internal usage of the Froge Viewer. Therefore, it's not recommended to use those APIs under the Autodesk.Viewing.Private namespace to partner developers like you.

但是,我们可以将此请求记录在内部系统中,以供开发团队分配时间进行调查.也许有一天它会成真,但是我们不知道什么时候会成真.因此,对此没有任何承诺.希望你能理解.

However, we can log this request in our internal system for the dev team to allocate time to investigate. Maybe it will come true someday, but we have no idea when it will be. So, there is no any promise for it. Hope you will understand.

这篇关于如何在Autodesk Forge中为背景添加自定义环境贴图?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆