AutodeskForgeViewer-ErrorwhileprocessingSVF
创始人
2024-11-12 10:30:33
0

在处理SVF格式时出现错误,解决方法是对模型进行3D格式转换,例如转换为OBJ格式,然后再使用Forge API将其转换为SVF格式。参考代码如下:

const express = require('express');
const bodyParser = require('body-parser');

const app = express();
app.use(bodyParser.urlencoded({ extended: false }));
app.use(bodyParser.json());

const { DerivativeApi } = require('forge-apis');

const CLIENT_ID = 'your_client_id';
const CLIENT_SECRET = 'your_client_secret';
const BUCKET_KEY = 'your_bucket_key';
const OBJECT_NAME = 'your_object_name';
const FILE_URN = 'your_file_urn';

const apiInstance = new DerivativeApi();
apiInstance.authManager.authenticate();

const job = {
  input: {
    urn: FILE_URN,
  },
  output: {
    formats: [
      {
        type: 'obj',
        advanced: {
          modelGuid: '',
        },
      },
    ],
  },
};

apiInstance.translate(job, {}, (err, data) => {
  if (err) { console.log(err); return; }
  console.log(data);
});

此代码将输入模型转换为OBJ格式,然后再使用Forge API将其转换为SVF格式,以避免在处理SVF格式时出现错误。

相关内容

热门资讯

于此同时!wepokerplu... 于此同时!wepokerplus万能挂(透视)好像是有辅助工具(详细教程)-哔哩哔哩小薇(辅助器软件...
事发当天!wepoker透视脚... 事发当天!wepoker透视脚本视频(透视)果然有辅助安装(有挂助手)-哔哩哔哩1、该软件可以轻松地...
透视实锤!wpk模拟器是什么(... 透视实锤!wpk模拟器是什么(透视)都是存在有辅助软件(真是有挂)-哔哩哔哩一、wpk模拟器是什么可...
长期以来!约局吧开挂(透视)其... 长期以来!约局吧开挂(透视)其实是有辅助下载(有挂教程)-哔哩哔哩约局吧开挂辅助器是一种具有地方特色...
透视玄学!拱趴大菠萝开挂方法(... 透视玄学!拱趴大菠萝开挂方法(透视)总是是有辅助安装(果真有挂)-哔哩哔哩1、用户打开应用后不用登录...
记者获悉!newpoker脚本... 记者获悉!newpoker脚本(透视)竟然真的是有辅助下载(发现有挂)-哔哩哔哩1、实时newpok...
透视苹果版!wepoker透视... 透视苹果版!wepoker透视脚本下载(透视)原来有辅助插件(讲解有挂)-哔哩哔哩1)wepoker...
透视辅助!hhpoker视频巡... 透视辅助!hhpoker视频巡查真的假的(透视)都是是有辅助软件(有挂工具)-哔哩哔哩1、透视辅助!...
随着!pokermaster脚... 随着!pokermaster脚本(透视)一直有辅助软件(有挂实锤)-哔哩哔哩1、进入游戏-大厅左侧-...
透视了解!pokemmo修改器... 透视了解!pokemmo修改器手机版(透视)竟然是有辅助app(真的有挂)-哔哩哔哩1、首先打开po...