attribute USVString WebGLObject.label, application-provided.#3637
attribute USVString WebGLObject.label, application-provided.#3637kdashg merged 1 commit intoKhronosGroup:mainfrom
Conversation
|
https://www.w3.org/TR/webgpu/#gpuobjectbase interface mixin GPUObjectBase {
attribute USVString label;
}; |
|
The difference between WebGPU's label and WebGL is that, AFAIK, WebGPU always returns an object. WebGL does not WebGPU doesn't have this issue More in the spirit of WebGL would be Sure, the user can check for null though. |
|
I strongly prefer the ergonomics of .label, and would rather champion infallible allocations instead of reduced ergonomics. |
|
In the spirit of the fact that WebGL is supposed to make porting OpenGLES code easier, isn't Of course it's doesn't have to be either/or but still. |
|
I believe my proposal is the best way forward for the most users. |
kkinnunen-apple
left a comment
There was a problem hiding this comment.
Looks good, thanks.
kenrussell
left a comment
There was a problem hiding this comment.
This direction sounds good. While it's a different API style than other WebGL extensions, it's expected that this would be implementable/supportable at the native level pretty much ubiquitously.
This is similar to WebGPU's
GPUObjectBase.label.