System Environment: -------------------------- Platform: HSW Libdrm: (master)libdrm-2.4.59-6-g28ee135a37e10b9a6cd62d67df0332e38ee0b85c Mesa: (master)6094619c0297180db218e5b4e45fc07aff116413 Xserver: (master)xorg-server-1.16.99.902-4-g697b696e5e24d0679f133183a3bb0852025377c2 Xf86_video_intel:(master)2.99.917-75-g6d2754b1902e8bce37818c854fb890400b27343e Libva: (master)f9741725839ea144e9a6a1827f74503ee39946c3 Libva_intel_driver:(master)bf324e3440246a487997a1624ac862e3e4027f9e Kernel: (drm-intel-nightly)8b4216f91c7bf8d3459cadf9480116220bd6545e Bug detailed description: --------------------------- It fails on SNB+ platforms with mesa master branch, works well on 10.4 branch. Following cases also fail with the same bisect commit ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels_pbo ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels_pixelstore Bisect shows:e638841b87a5d9454739195b49c403ca9a22a59e is the first bad commit commit e638841b87a5d9454739195b49c403ca9a22a59e Author: Kalyan Kondapally <kondapallykalyancontribute@gmail.com> AuthorDate: Wed Jan 7 20:30:27 2015 -0800 Commit: Tapani Pälli <tapani.palli@intel.com> CommitDate: Thu Jan 29 08:22:12 2015 +0200 Mesa: Advertise GL_OES_texture_*float* extensions support with i965. This patch advertises support for GL_OES_texture_*float* extensions when using i965 drivers. Signed-off-by: Kevin Rogovin <kevin.rogovin@intel.com> Signed-off-by: Kalyan Kondapally <kalyan.kondapally@intel.com> Reviewed-by: Tapani Pälli <tapani.palli@intel.com> output: dEQP Core GL-CTS-2.0 (0x0052484b) starting.. target implementation = 'X11' Test case 'ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels'.. ERROR:packed_pixels:DoRead: FBO is complete but expected incomplete with sizedFormat GL_RGBA, attachemnt GL_COLOR_ATTACHMENT0 INFO:packed_pixels:countReadPixels: 8821, countReadPixelsOK: 47 INFO:packed_pixels:countCompare: 47, countCompareOK: 47 Fail (Fail) DONE! Test run totals: Passed: 0/1 (0.00%) Failed: 1/1 (100.00%) Not supported: 0/1 (0.00%) Warnings: 0/1 (0.00%) Reproduce steps: ------------------------- 1. xinit 2. ./glcts --deqp-case=ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels
There seems to be issues with texture upload when type is GL_FLOAT and format is GL_LUMINANCE, GL_ALPHA or GL_LUMINANCE_ALPHA.
(In reply to Tapani Pälli from comment #1) > There seems to be issues with texture upload when type is GL_FLOAT and > format is GL_LUMINANCE, GL_ALPHA or GL_LUMINANCE_ALPHA. urgh unfortunately the problem is bigger than this, plan was to expose this for only ES2 but it seems ES3 also now uses it, this is not taken account in mesa_es3_error_check_format_and_type and perhaps some other places .. will dig deeper.
(In reply to Tapani Pälli from comment #2) > (In reply to Tapani Pälli from comment #1) > > There seems to be issues with texture upload when type is GL_FLOAT and > > format is GL_LUMINANCE, GL_ALPHA or GL_LUMINANCE_ALPHA. > > urgh unfortunately the problem is bigger than this, plan was to expose this > for only ES2 but it seems ES3 also now uses it, this is not taken account in > mesa_es3_error_check_format_and_type and perhaps some other places .. will > dig deeper. To be clear, I mean that some of the added half-float support seems to be enabling/executed also for ES3 which makes test fail.
(In reply to Tapani Pälli from comment #3) > (In reply to Tapani Pälli from comment #2) > > (In reply to Tapani Pälli from comment #1) > > > There seems to be issues with texture upload when type is GL_FLOAT and > > > format is GL_LUMINANCE, GL_ALPHA or GL_LUMINANCE_ALPHA. > > > > urgh unfortunately the problem is bigger than this, plan was to expose this > > for only ES2 but it seems ES3 also now uses it, this is not taken account in > > mesa_es3_error_check_format_and_type and perhaps some other places .. will > > dig deeper. > > To be clear, I mean that some of the added half-float support seems to be > enabling/executed also for ES3 which makes test fail. And unfortunately the added float support too :/ I will investigate how to make this specific for gles2.
Created attachment 113254 [details] [review] workaround Here's a first workaround that makes the test pass. I will need to get more familiar with the texture and renderbuffer validation code to understand why this validation does not already happen.
Created attachment 113258 [details] [review] workaround workaround, real fix will be to correct validation code
(In reply to Tapani Pälli from comment #6) > Created attachment 113258 [details] [review] [review] > workaround > > workaround, real fix will be to correct validation code Fixed by this patch. dEQP Core GL-CTS-2.0 (0x0052484b) starting.. target implementation = 'X11' Test case 'ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels'.. INFO:packed_pixels:countReadPixels: 8821, countReadPixelsOK: 47 INFO:packed_pixels:countCompare: 47, countCompareOK: 47 Pass (Pass) DONE! Test run totals: Passed: 1/1 (100.00%) Failed: 0/1 (0.00%) Not supported: 0/1 (0.00%) Warnings: 0/1 (0.00%)
Now I understand the problem. OES_texture_float does not specify floating point render target support. Our implementation has this because it is 'expected' by the corresponding WebGL extension. Related discussion in the khronos public bugzilla: https://www.khronos.org/bugzilla/show_bug.cgi?id=729 There's also bunch of bugs in the internal bugzilla. WebGL extension specification mentions that new implementation should not implement render target support but implement WEBGL_color_buffer_float which maps with EXT_color_buffer_half_float: https://www.khronos.org/registry/webgl/extensions/OES_texture_float/ So, to put it short our implementation is wrong in allowing render targets to be created with GL_FLOAT and GL_HALF_FLOAT. Unfortunately fixing this means that we will loose some nice deferred rendering webgl demos enabled by current implementation, we could think of having override to allow this later (?) Will investigate a proper fix.
Created attachment 113391 [details] [review] fix set fbo incomplete if GL_FLOAT or GL_HALF_FLOAT is set as internalformat.
Lu Hua, could you run full suite with the patch to see any possible regressions?
fix pushed
(In reply to Tapani Pälli from comment #10) > Lu Hua, could you run full suite with the patch to see any possible > regressions? Test full ogles3conform, this issue is fixed by this patch and no new regression. master master with patch ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels fail pass ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels_pbo fail pass ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels_pixelstore fail pass
(In reply to lu hua from comment #12) > (In reply to Tapani Pälli from comment #10) > > Lu Hua, could you run full suite with the patch to see any possible > > regressions? > > Test full ogles3conform, this issue is fixed by this patch and no new > regression. > master master > with patch > ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels fail > pass > ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels_pbo fail > pass > ES3-CTS.gtf.GL3Tests.packed_pixels.packed_pixels_pixelstore fail > pass Nice, thanks for testing round!
Verified.Fixed.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.