Use asset from editor in engine-only app

I’m extremely new to PlayCanvas. I’m using the playcanvas script on a webpage to display an animated 3d model. What I’m wondering about is this, which I’m reproducing from a thread about engine-only use:

“The part where you currently need to use the PlayCanvas site is to convert FBX models (or other 3d file formats) to the model files that the engine expects.”

Someone from the PlayCanvas team wrote this. But for the life of me, I can’t figure out how you get the converted 3d model file out of the project so that you can reference it with a URL. Any help?

That might be from an old thread. PlayCanvas now supports GLBs which can be exported from most 3D model packages.

Engine example here: http://playcanvas.github.io/#graphics/model-asset.html

Thanks so much for the quick reply. So, PlayCanvas does internally convert imported models to glb, but there’s no way to use those converted models in an engine-only scenario?

The editor converts a FBX to GLB (or legacy JSON). It splits the animations and models to separate GLBS and creates material assets. You can download these assets by selecting them in the Editor and clicking on download

It should download a zip containing, materials, the model GLB and textures I think. You have to keep the folder structure and load the GLB as a ‘model’ rather than a ‘container’ type though and that will load all the associated materials too.

The arguably easier method would be to convert the FBX to a GLB with all the textures and materials embedded in the GLB. This can be done via the 3D modelling tool or a command line tool like this: https://github.com/facebookincubator/FBX2glTF

And load the GLB as a ‘container’ type using the engine example I linked before :slight_smile: