Eureka, washed out intel GM965 tv-out solved

rglowery at exemail.com.au rglowery at exemail.com.au
Wed Nov 14 13:15:38 PST 2007


> On Thursday, November 01, 2007 7:22 pm rglowery at exemail.com.au wrote:
>> > On Sunday, October 28, 2007 4:03 rglowery at exemail.com.au wrote:
>> >> >> Browsing through i810_reg.h I came across
>> >> >>
>> >> >> 1573 /** @defgroup TV_CSC_KNOBS
>> >> >> 1574  * @{
>> >> >> 1575  */
>> >> >> 1576 #define TV_CLR_KNOBS            0x68028
>> >> >> 1577 /** 2s-complement brightness adjustment */
>> >> >> 1578 # define TV_BRIGHTNESS_MASK             0xff000000
>> >> >> 1579 # define TV_BRIGHTNESS_SHIFT            24
>> >> >> 1580 /** Contrast adjustment, as a 2.6 unsigned floating point
>> >> >> number */ 1581 # define TV_CONTRAST_MASK               0x00ff0000
>> >> >> 1582 # define TV_CONTRAST_SHIFT              16
>> >> >> 1583 /** Saturation adjustment, as a 2.6 unsigned floating point
>> >> >> number */
>> >> >> 1584 # define TV_SATURATION_MASK             0x0000ff00
>> >> >> 1585 # define TV_SATURATION_SHIFT            8
>> >> >> 1586 /** Hue adjustment, as an integer phase angle in degrees */
>> >> >> 1587 # define TV_HUE_MASK                    0x000000ff
>> >> >> 1588 # define TV_HUE_SHIFT                   0
>> >> >> 1589 /** @} */
>> >> >>
>> >> >> This led me to the following patch which solves the problem for me
>> >> >> diff --git a/src/i830_tv.c b/src/i830_tv.c
>> >> >> index ee2538a..5f82188 100644
>> >> >> --- a/src/i830_tv.c
>> >> >> +++ b/src/i830_tv.c
>> >> >> @@ -1178,7 +1178,7 @@ i830_tv_mode_set(xf86OutputPtr output,
>> >> >> DisplayModePtr mode,
>> >> >>             (i830_float_to_csc(color_conversion->bv) << 16) |
>> >> >>             (i830_float_to_luma(color_conversion->av)));
>> >> >>
>> >> >> -    OUTREG(TV_CLR_KNOBS, 0x10606000);
>> >> >> +    //OUTREG(TV_CLR_KNOBS, 0x10606000);
>> >> >>      OUTREG(TV_CLR_LEVEL, ((video_levels->black <<
>> >> >> TV_BLACK_LEVEL_SHIFT)
>> >> >>
>> >> >>                 (video_levels->blank << TV_BLANK_LEVEL_SHIFT)));
>> >> >>      {
>> >> >>
>> >> >>
>> >> >> I guess the BIOS defaults these to something more reasonable.
>> >> >
>> >> > ModeDebug shows the TV_CLR_KNOBS registry defaulting to 0x00404000
>> >> >
>> >> > I'll leave it up to the intel people with doco to determine what
>> >> > the appropriate fix is.
>> >>
>> >> Sorry for the multiple posts, but it looks like the TV_CLR_KNOBS
>> >> register is not initialized by the BIOS if a DVI display is also
>> >> connected, so for me, the patch to resolve the washed out colours
>> >> regardless of the connected devices is
>> >>
>> >> diff --git a/src/i830_tv.c b/src/i830_tv.c
>> >> index ee2538a..e6d2ee5 100644
>> >> --- a/src/i830_tv.c
>> >> +++ b/src/i830_tv.c
>> >> @@ -1178,7 +1178,7 @@ i830_tv_mode_set(xf86OutputPtr output,
>> >> DisplayModePtr mode
>> >>             (i830_float_to_csc(color_conversion->bv) << 16) |
>> >>             (i830_float_to_luma(color_conversion->av)));
>> >>
>> >> -    OUTREG(TV_CLR_KNOBS, 0x10606000);
>> >> +    OUTREG(TV_CLR_KNOBS, 0x00404000);
>> >>      OUTREG(TV_CLR_LEVEL, ((video_levels->black <<
>> >> TV_BLACK_LEVEL_SHIFT) | (video_levels->blank <<
>> >> TV_BLANK_LEVEL_SHIFT))); {
>> >
> I was going to change the defaults, but it sounds like the the current
> ones
> work for some people, while other people need other defaults, so I think
> I'll
> leave them alone for the 2.2 release.  If distros or users want, they can
> patch in my TV output properties patch and control them by hand, but
> that'll
> be solved in a better way with Randr 1.3, so I've reassigned the bug to
> Keith.
>
> Thanks,
> Jesse
>

I've not heard anyone state that the current defaults are giving them good
results.  Sure they give a picture, but the result is horrible.  The most
important change is setting the brightness to 0.

If anyone is happy with the current defaults, please try my patch above
and see it if makes things better or worse for them.




More information about the xorg mailing list