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

Re: [Public WebGL] Weird alpha issue.

On Fri, Nov 5, 2010 at 3:34 AM, Mark Callow <callow_mark@hicorp.co.jp> wrote:

But the problem isn't alpha issues with images. It is issues with alpha in compositing with the HTML page which would probably also happen with vertex colors having alpha < 1.0.

I understand that.

the only thing I can do in the test is draw the webgl canvas to a 2d canvas with the right globalCompositingOperation and see that the results are as expected. Of course that's not the same path is just compositing layers in HTML but there's no programmatic way I can check that layering results are correct in a cross browser, cross OS way.

So, I will make a test that tests

RGB backbuffer pre-multipled
RGB backbuffer not-pre-multiplied
RGBA backbuffer pre-multiplied
RGBA backbuffer not-pre-multiplied

using vertex alpha sounds fine. My only point in referencing the gl-teximage.html test is it already has non 0 and non 1 alpha drawing in it so adding drawing the result to a 2d canvas would be easy to add.




There is already a test that checks alpha issues with images.

It can be adapted to run with an RGB backbuffer.

That's probably easier than making a new test.

I'll do that asap.