Bug 91817 - SRGB dark rendering
Summary: SRGB dark rendering
Status: RESOLVED DUPLICATE of bug 92759
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/i965 (show other bugs)
Version: 10.6
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Ian Romanick
QA Contact: Intel 3D Bugs Mailing List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-08-30 19:52 UTC by CapsAdmin
Modified: 2015-12-11 14:49 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
attachment-1672-0.html (1.41 KB, text/html)
2015-11-03 12:57 UTC, CapsAdmin
Details

Description CapsAdmin 2015-08-30 19:52:41 UTC
I request a 3.3 core context and call glEnable(GL_FRAMEBUFFER_SRGB), create textures using GL_SRGB8 or GL_SRGB8_ALPHA8 as internal format and pow 2.2 on colors sent to gpu with the uniform functions.

This looks fine on the intel drivers for windows and on nvidia drivers on windows and linux.

If I record with apitrace it looks correct when replaying the trace.
Comment 1 Tapani Pälli 2015-08-31 06:37:05 UTC
Please attach a test case and/or screenshots.
Comment 2 CapsAdmin 2015-08-31 10:29:54 UTC
Sorry I forgot.

This is what I believe it's supposed to look like (nvidia gtx 970 on windows 10):
https://dl.dropboxusercontent.com/u/244444/mesa%20srgb/srgb%20nvidia%20windows.png

This is what it looks like on mesa:
https://dl.dropboxusercontent.com/u/244444/mesa%20srgb/with%20srgb.png

This is what it looks like if I call glDisable(GL_FRAMEBUFFER_SRGB) (it looks even darker)
https://dl.dropboxusercontent.com/u/244444/mesa%20srgb/disable%20gl_framebuffer_srgb.png

This is without any of the steps described in the OP:
https://dl.dropboxusercontent.com/u/244444/mesa%20srgb/no%20%20srgb.png

This is the apitrace recorded on linux:
https://dl.dropboxusercontent.com/u/244444/mesa%20srgb/luajit.trace

There are some other issues that I haven't looked into yet such as there being a black border around the text and the snow being very dark so ignore those as they might be a user error.
Comment 3 Deve 2015-11-03 12:16:54 UTC
@CapsAdmin is this related to this bug?
https://bugs.freedesktop.org/show_bug.cgi?id=92759
Comment 4 CapsAdmin 2015-11-03 12:57:41 UTC
Created attachment 119375 [details]
attachment-1672-0.html

Possibly. I don't have a setup to test the latest intel drivers with
patches.

On Tue, Nov 3, 2015 at 1:16 PM, <bugzilla-daemon@freedesktop.org> wrote:

> *Comment # 3 <https://bugs.freedesktop.org/show_bug.cgi?id=91817#c3> on
> bug 91817 <https://bugs.freedesktop.org/show_bug.cgi?id=91817> from Deve
> <deveee@gmail.com> *
>
> @CapsAdmin is this related to this bug?https://bugs.freedesktop.org/show_bug.cgi?id=92759
>
> ------------------------------
> You are receiving this mail because:
>
>    - You reported the bug.
>
>
Comment 5 Neil Roberts 2015-12-11 14:49:06 UTC
It seems very likely that this bug is the same as bug 92759. Although the original description says that it's rendering to GL_SRGB8 textures which wouldn't have the bug, the trace enables GL_FRAMEBUFFER_SRGB throughout the entire the trace so presumably it would be enabled for the final writes to the framebuffer as well. The calls to glXChooseVisual don't include the GLX_ALPHA_SIZE parameter so it seems quite likely that it's picking up an RGB format without sRGB capabilities.

I haven't been able to test it with the trace because glretrace seems to ignore the visual from glXChooseVisual and always requests an RGBA visual which means it would end up with an sRGB-capable visual regardless.

Thanks for the bug report.

*** This bug has been marked as a duplicate of bug 92759 ***


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.