-
-
Notifications
You must be signed in to change notification settings - Fork 47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[TODO] WebGPU example #118
Comments
I will look into this, WebGPU seem the rigth fit for this as there is currently no "real" online USDZ viewer. |
🙏 Yes, use WASM through Emscripten. Something TinyUSDZ version of this effort: https://github.com/Twinklebear/webgpu-cpp-gltf i'm not sure how much inconsistencies will be happen for Safari. Probably we need to keep wasm(C++) part small(e.g, just for loading USD asset) and write more stuff in Javascript layer(e.g, setup shaders) to improve compatibilities across browsers. |
I'm not sure I fully know what you're both referring to about the Safari inconsistencies here, but my WebGPU/glTF/C++ demo does run in Safari Tech Preview (and uses tinygltf 😁 ). I think it should be fine to write the whole renderer in C++ using tinyUSDZ and compile to Wasm like the glTF demo. I have a little template repo that the glTF renderer used: https://github.com/Twinklebear/webgpu-cpp-wasm which might be helpful. If you want to have the demo app in JavaScript/TypeScript and call into the tinyUSDZ Wasm library to load files, then render w/ WebGPU in TypeScript, that should also be doable. What are the Safari-inconsistency issues? |
👍 |
I started playing around with this a bit: https://github.com/Twinklebear/webgpu-cpp-usdz , https://www.willusher.io/webgpu-cpp-usdz/ |
Awesome! I'm working on Tydra https://github.com/syoyo/tinyusdz/tree/dev/src/tydra RenderScene API to convert USD scene graph to renderer-friendly data structure, including material/texturing/skinning and some basic animation support. Probably some working Tydra RenderScene is available from the beginning of Feb next month. |
You are fast, I am also working on my side on a native version with either webgpu-native.h or dawn. |
It took time than expected, but now Tydra RenderScene should work for some USDZ models( See API usage examples in https://github.com/syoyo/tinyusdz/blob/dev/examples/tydra_to_renderscene/to-renderscene-main.cc |
WebGPU is getting popular.
https://webkit.org/blog/14879/webgpu-now-available-for-testing-in-safari-technology-preview/
https://developer.mozilla.org/ja/docs/Web/API/WebGPU_API
Although currently WebGPU is not widely avaiable, it'd be nice to think about writing TinyUSDZ + WebGPU example at some point(Late 2024 ~ 2025?)
The text was updated successfully, but these errors were encountered: