3 ms·
This is great! I have been meaning to get more into WebGPU! One question: Does anyone know more details about the Firefox WebGPU story? Even on this site's ho
by TachyonicBytes 3y ago
This is great! I have been meaning to get more into WebGPU!
One question: Does anyone know more details about the Firefox WebGPU story? Even on this site's homepage, if you access it from Chromium with WebGPU enabled, you get nice floating rotating triangles, if you access it from Firefox stable, you get, understandably, static triangles. But if you access from Firefox nightly, with WebGPU enabled, you get a dark background and the error:
TypeError: navigator.gpu.getPreferredCanvasFormat is not a function
- jeroenhd 3y agoFirefox doesn't implement that method yet: https://developer.mozilla.org/en-US/docs/Web/API/GPU/getPreferredCanvasFormat#browser_compatibility https://developer.mozilla.org/en-US/docs/Web/API/GPU/getPref... You can probably use "bgra8unorm" where getPreferredCanvasFormat isn't available, that seems to be the preference for at least Blink and WebKit. Chrome doesn't support rgba8unorm on Mac, probably because Apple seems to have chosen bgra8unorm as their format for their Metal API for some reason, so you'll have to use BRG rather than RGB if you want to support Apple hardware at the moment.