Bug 554967 - UMS:RV350:9600 incorrect colors and gamma in X with 16-bit color depth
Summary: UMS:RV350:9600 incorrect colors and gamma in X with 16-bit color depth
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: xorg-x11-drv-ati
Version: 12
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Jérôme Glisse
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2010-01-13 08:59 UTC by Boyan Anastasov
Modified: 2010-12-04 00:28 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2010-12-04 00:28:40 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Xorg.log with 16-bit color depth (46.24 KB, text/plain)
2010-01-13 09:00 UTC, Boyan Anastasov
no flags Details
Xorg.log with 24-bit color depth (46.28 KB, text/plain)
2010-01-13 09:01 UTC, Boyan Anastasov
no flags Details
xorg.conf (with 16-bit color depth) (1.59 KB, text/plain)
2010-01-13 09:02 UTC, Boyan Anastasov
no flags Details
Crash when selecting GL screensaver from KDE settings (75.61 KB, application/octet-stream)
2010-11-04 09:37 UTC, Boyan Anastasov
no flags Details

Description Boyan Anastasov 2010-01-13 08:59:19 UTC
In fedora 12 with radeon driver when color depth in xorg.conf is set to 16-bit the picture looks with much less contrast and rather green. The picture is ok with 15 or 24 bit, but not with 16 bit.

Version-Release number of selected component (if applicable):
All versions of xorg-x11-drv-ati from fedora 12

How reproducible:
Edit /etc/X/xorg.conf and add in Screen section:

Section "Screen"
        ...
        ...
        DefaultDepth 16
        ...
        ...
EndSection

Comment 1 Boyan Anastasov 2010-01-13 09:00:27 UTC
Created attachment 383432 [details]
Xorg.log with 16-bit color depth

Comment 2 Boyan Anastasov 2010-01-13 09:01:12 UTC
Created attachment 383433 [details]
Xorg.log with 24-bit color depth

Comment 3 Boyan Anastasov 2010-01-13 09:02:09 UTC
Created attachment 383434 [details]
xorg.conf (with 16-bit color depth)

Comment 4 Boyan Anastasov 2010-01-13 09:03:47 UTC
(In reply to comment #0)
> In fedora 12 with radeon driver when color depth in xorg.conf is set to 16-bit
> the picture looks with much less contrast and rather green. The picture is ok
> with 15 or 24 bit, but not with 16 bit.
> 
> Version-Release number of selected component (if applicable):
> All versions of xorg-x11-drv-ati from fedora 12
> 
> How reproducible:
> Edit /etc/X/xorg.conf and add in Screen section:

I mean /etc/X11/xorg.conf ...

> 
> Section "Screen"
>         ...
>         ...
>         DefaultDepth 16
>         ...
>         ...
> EndSection

Comment 5 Boyan Anastasov 2010-01-16 00:28:39 UTC
There is a difference in the driver for 16bit depth when setting gamma.
I've disabled it and now the picture is ok.


xf86-video-ati-20091221/src/radeon_crtc.c, at line 450:

static void
radeon_crtc_gamma_set(xf86CrtcPtr crtc, uint16_t *red, uint16_t *green,
                      uint16_t *blue, int size)
{
    RADEONCrtcPrivatePtr radeon_crtc = crtc->driver_private;
    ScrnInfoPtr         pScrn = crtc->scrn;
    int i, j;

    if (0/*pScrn->depth == 16*/) {
        for (i = 0; i < 64; i++) {
            if (i <= 31) {
                for (j = 0; j < 8; j++) {
                    radeon_crtc->lut_r[i * 8 + j] = red[i] >> 6;
                    radeon_crtc->lut_b[i * 8 + j] = blue[i] >> 6;
                }
            }

            for (j = 0; j < 4; j++) {
                radeon_crtc->lut_g[i * 4 + j] = green[i] >> 6;
            }
        }
    } else {
        for (i = 0; i < 256; i++) {
            radeon_crtc->lut_r[i] = red[i] >> 6;
            radeon_crtc->lut_g[i] = green[i] >> 6;
            radeon_crtc->lut_b[i] = blue[i] >> 6;
        }
    }

    radeon_crtc_load_lut(crtc);
}

Comment 6 Jérôme Glisse 2010-02-22 13:17:37 UTC
Does it works better with KMS ?

Comment 7 Boyan Anastasov 2010-02-22 21:15:34 UTC
I've tested this on two different boxes with two different models ati card - it is not only for RV350:9600. Same thing happens with other box with X1100 card. The first box is with vanilla kernel - logs are from that box, the other one is with fedora kernel and kms is not very stable - after install X started couple of times with black screen, so kms is disabled in grub.conf with nomodeset option.

Comment 8 Boyan Anastasov 2010-08-20 13:10:15 UTC
It seems 7 months later nobody else complains about this problem, but I'm still using this change for my boxes (another hardware with ati card HD4200 integrated, the same driver).
There is one more problem which I can't find how to fix for HD4200 specifically - when start glxgears the gears are bluish - upper one gear is blue, the biggest in down left is purple, the right one is light blue. OpenGL screensavers from KDE System Settings does not work too. With 24 bit the colors are correct and opengl screensavers (I'm testing with Euphoria) are working without problems.

Maybe nobody uses 16 bit depth, because on new installs xorg.conf is automatically generated with 24bit depth by default and nobody noticed any such problems.

I've now tested with KMS, and it looks ok - even on 16 bit colors of glxgears are correct, but randomly crashes X on my HD4200, so I've disabled it with nomodeset. On another box - laptop with X1100 with KMS X locks seconds after loading KDE and there X works with permanently added nomodeset to grub.conf. Thats why KMS is not an option for me.

Comment 9 Boyan Anastasov 2010-08-20 13:11:35 UTC
Forgot to add that this is on Fedora 13 already.

Comment 10 Bug Zapper 2010-11-04 01:06:13 UTC
This message is a reminder that Fedora 12 is nearing its end of life.
Approximately 30 (thirty) days from now Fedora will stop maintaining
and issuing updates for Fedora 12.  It is Fedora's policy to close all
bug reports from releases that are no longer maintained.  At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '12'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 12's end of life.

Bug Reporter: Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 12 is end of life.  If you 
would still like to see this bug fixed and are able to reproduce it 
against a later version of Fedora please change the 'version' of this 
bug to the applicable version.  If you are unable to change the version, 
please add a comment here and someone will do it for you.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events.  Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

The process we are following is described here: 
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 11 Boyan Anastasov 2010-11-04 09:35:17 UTC
I can no longer test it with radeon 9550, but the issue is the same on all ATI cards I've tested - 9550, HD4200, X1100.
The fix from comment 5 is applied upstream in xorg-x11-drv-ati-6.13.2.  This version is not present in Fedora 12 and 13. In Fedora 14 with xorg-x11-drv-ati-6.13.1-0.3.20100705git37b348059.fc14.i686 it looks like this issues with wrong colors are not observed with 16bit colors. Something else in X is fixed. Even glxgears appears with correct colors.
The only issue now is that opengl screen savers from KDE screensaver settings  crash the X when depth is 16bit. Not tested with 24bit.

Comment 12 Boyan Anastasov 2010-11-04 09:37:18 UTC
Created attachment 457742 [details]
Crash when selecting GL screensaver from KDE settings

The screensaver I've tested with is Euphoria(GL). The crash is logged at the end of the log.

Comment 13 Bug Zapper 2010-12-04 00:28:40 UTC
Fedora 12 changed to end-of-life (EOL) status on 2010-12-02. Fedora 12 is 
no longer maintained, which means that it will not receive any further 
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of 
Fedora please feel free to reopen this bug against that version.

Thank you for reporting this bug and we are sorry it could not be fixed.


Note You need to log in before you can comment on or make changes to this bug.