[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Public WebGL] The miserable state of affairs of floating point support

On Mar 23, 2017, at 18:08, Florian Bösch <pyalot@gmail.com> wrote:

readPixels of floats may or may not work

Some platforms do not implement readPixels from a floating point texture. Some do. Because of that, you can't directly test some of the more interesting properties of floating point textures (such as blending, filtering, clamping, etc.) but you have to do it trough a proxy unsigned byte FBO because you can't rely on readPixels.

This should again be much clarified in WebGL 2.0 and there should be strong guarantees about readPixels' behavior there.

The specification of color-buffer-float clearly specifies that area, it states that: "The format and type combination RGBA and FLOAT becomes valid for reading from a floating-point rendering buffer.”

As Florian points out, the WebGL 1.0 extensions specs do make strong guarantees. The issue is that some UAs, most notably Chrome, do not support those extensions, for reasons that I can’t recall and am not sure I ever understood fully. As a result they have completely unspecified behavior when it comes to floating-point rendering, leaving developers like Florian grasping for ways to figure out what those UAs are doing. With unspecified behavior there can be no conformance tests, so it is not surprising if things like failure to support RGBA, FLOAT readPixels fall through the cracks.



Attachment: signature.asc
Description: Message signed with OpenPGP