Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-5656

WhatColor app: Bug in NtGDIGetPixel, returning 000000

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Fix Version/s: 0.4.4
    • Component/s: Win32SS
    • Labels:
      None
    • Environment:

      Operating System: ReactOS
      Platform: x86 Hardware

      Description

      r51583 Vbox
      WhatColor is a small app that shows in a Tooltip the RGB color of any pixel of the screen.
      In ReactOS it is always showing 000000
      The app can be downloaded from here:
      http://www.donationcoder.com/Software/Skrommel/WhatColor/WhatColor.exe

      I have tracked down the Bug to NtGDIGetPixel with the following findings:
      The COLORREF returned by NtGDIGetPixel is always 000000.
      Inside NtGdiPixel it goes into:
      if ((dc->rosdc.CombinedClip == NULL) ||
      (RECTL_bPointInRect(&dc->rosdc.CombinedClip->rclBounds, XPos, YPos)))
      Then it falls into: if (psurf)
      Now it calls EXLATEOBJ_vInitialize(&exlo, psurf->ppal, &gpalRGB, 0, 0xffffff, 0)
      Afterwards it calls XLATEOBJ_iXlate and assigns its ULONG return(always 000000) to a COLORREF variable(should it be casted?).
      One of these 2 functions is bugged.

        Attachments

          Activity

            People

            • Assignee:
              bug zilla Bug Zilla
              Reporter:
              vicmarcal vicmarcal
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: