Use Design Automation API to convert SVF, I was able to get it to the OSS bucket as output.zip.
Continue using the token and documentId, like the attached HTML that can be executed currently. I would like to view the model in a browser. In addition, since the number of trials is large, I would like to do this without using the ModeDerivative API.
function initializeViewer() {
const options = {
env: "AutodeskProduction",
api: "derivativeV2",
accessToken: token,
};
Autodesk.Viewing.Initializer(options, function () {
viewer = new Autodesk.Viewing.GuiViewer3D(
document.getElementById("MyViewerDiv")
);
viewer.start();
Autodesk.Viewing.Document.load(
`urn:${documentId}`,
function (doc) {
const defaultModel = doc.getRoot().getDefaultGeometry();
viewer.loadDocumentNode(doc, defaultModel);
},
function (err) {
console.error(err);
}
);
});
}
As documentId, documentId=base64Encode("urn:adsk.objects:os.object:mybucket/output.zip")
I tried that, but it didn't work. Does anything else need to be done?
We are doing exactly this. We do SVF export using Inventor engine on FDA. That produces zip. Such a zip needs to be moved to the webserver and unarchived there to individual files so they can be server across the http to browser as forge viewer is serving them individually. You can see the setup here https://github.com/autodesk-platform-services/aps-configurator-inventor/blob/master/WebApplication/ClientApp/src/components/forgeView.js
application using it https://inventor-config-demo.autodesk.io/