3 ms·
This I definitely agree with. The standard should focus on a safe byte code representation, similar to SPIRV. The actual shader language should be an offline to
by flohofwoe 8y ago
This I definitely agree with. The standard should focus on a safe byte code representation, similar to SPIRV. The actual shader language should be an offline tool or JS/WASM module and shouldn't matter much as long as it can compile to the standardized byte code format.
- astrange 8y agoA bytecode is more difficult to specify safely, harder to parse securely (partially because it looks like an easy problem), and View Source doesn't work. The various text formats in the history of browsers have better security stories than binary formats like PNG, SWF, fonts. That said the binary formats usually have more features, and if you invent a byte code it's not hard to assemble/disassemble or allow delivering it in text form. What I find unfortunate is that GLSL should be usable here, but every OpenGL variant really does have an wildly incompatible GLSL for no reason.