How to create a USDZ file?

匿名 (未验证) 提交于 2019-12-03 08:57:35

问题:

I tried to look at the main documentation at http://graphics.pixar.com/usd/docs/index.html and http://graphics.pixar.com/usd/docs/Usdz-File-Format-Specification.html but could not find the details to create a usdz file.

I can get some sample USD files from http://graphics.pixar.com/usd/downloads.html

How can we create one?

回答1:

A gallery of usdz files are provided by Apple at the url below

https://developer.apple.com/arkit/gallery/

You need a device with iOS12 beta installed for the models to be viewable on your mobile device. Basically Apple uses Mime-types model/usd usdz and model/und.pixar.usd .usdz to identify them as AR viewable. You also need to do this via the safari browser... Chrome does not support the file format.

the html to list a thumbnail usdz file would be the following.

<a rel="ar" href="model.usdz">   <img src="model-preview.jpg"> </a>

to create your own usdz files, Apple has bundled usdz_converter as part of Xcode 10. Its a command line tool for creating the usdz file from OBJ files, Single-frame Alembic (ABC) files, USD file (either .usda or usd.c)

the basic command line is

xcrun usdz_converter Wineglass.obj Wineglass.usdz  

usdz supports physically based renders, to achieve this you add images for each component of the PBR like so,

xcrun usdz_converter Wineglass.obj Wineglass.usdz  - g WineGlassMesh -color_map WineGlass_Albedo.png -metallic_map WineGlass_Metallic.png -roughness_map WineGlass_Roughness.png -normal_map .  WineGlass_Normal.png -emissive_map  WineGlass_Emissive.png

A good video to get you started on how to create usdz files, host on a webpage & create a quicklook in your own app

https://developer.apple.com/videos/play/wwdc2018/603/



回答2:

@Ash, you have to activate the command line tools in Xcode preferences, in case they're not actived yet (that was my case). See image below.



转载请标明出处:How to create a USDZ file?
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!