andykswong / mugl Goto Github PK
View Code? Open in Web Editor NEWWebGPU and WebGL Micro 3D Graphics Library for JavaScript and WebAssembly
Home Page: https://andykswong.github.io/mugl/examples
License: MIT License
WebGPU and WebGL Micro 3D Graphics Library for JavaScript and WebAssembly
Home Page: https://andykswong.github.io/mugl/examples
License: MIT License
These webgl2 draft extensions let you start instanced drawing from an arbitrary base instance, very much like firstInstance
in WebGPU:
It'd be nice to use them if they're available
Optimize the size of the model viewer / glTF module, targeting <10 KB (with no/minimal extensions support).
Uncaught ReferenceError: process is not defined
Add more comprehensive input parameter assertions, and make them tree-shakeable for minimal runtime overhead.
Currently, some checks still exist on production build, while others rely on the following pattern for tree-shaking:
if (process.env.DEBUG) {
console.warn(...);
}
It'd be nice to be able to do some compute stuff with this library, and to reuse the compute output buffers in render pipelines
Ensure support for desktop and native mobile with examples:
Features:
Optimize the size of the model viewer / glTF module, targeting <20 KB (with no/minimal extensions support):
Add UBO support in WebGL2 backend
Add readPixels method to device to support GPU mouse picking. This may require WebGL2 to avoid blocking: https://developer.mozilla.org/en-US/docs/Web/API/WebGL_API/WebGL_best_practices#use_non_blocking_async_data_readback
This should be an extension instead of core device feature
Chrome webgpu support is around the corner, should be finally enable by default in chrome 113 in like ~3 weeks.
Is mugl will remains purely webgl2, or is there any plan to also handle webgpu (maybe providing some webgl2 fallback).
The syntax is really similar and having the combo webgpu + assemblyscript binding sounds really promising.
Add support for WebXR and multiview (OVR_multiview2 / OCULUS_multiview).
This should be an extension instead of core device feature
Consider handling context lost:
Reference: https://www.khronos.org/webgl/wiki/HandlingContextLost
Nano Backend Improvements:
Add sRGB texture support, which is available in WebGL2 or in WebGL1 via EXT_sRGB: https://developer.mozilla.org/en-US/docs/Web/API/EXT_sRGB
Expose API to check WebGPU and WebGL limits.
Ref:
Currently I simply check the URI suffix for GLB, which may not be good enough. We can instead always load the content as binary and check for the GLB header magic.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.