-
simon.fraser@apple.com authored
https://bugs.webkit.org/show_bug.cgi?id=75662 Reviewed by Dan Bernstein. The pixel results generated by DumpRenderTree and WebKitTestRunner differed because of color profile issues. Fix by keeping everything in device RGB and ensuring that the test window uses the main display's color space, so that the pixel values in the bitmap that gets checksummed are identical to the CSS colors. Removed the code that switches the display profile in DRT, since that is no longer required. * DumpRenderTree/PixelDumpSupport.h: Remove unused function declarations. * DumpRenderTree/mac/DumpRenderTree.mm: (crashHandler): Remove code that switches display profiles. (prepareConsistentTestingEnvironment): Ditto. (dumpRenderTree): Ditto. * DumpRenderTree/mac/PixelDumpSupportMac.mm: Ditto. (createBitmapContext): Use DeviceRGB for the bitmap colorspace. (createBitmapContextFromWebView): Add comment about the colorspace handling. * WebKitTestRunner/cg/TestInvocationCG.cpp: (WTR::createCGContextFromImage): Use a RetainPtr, add comment. (WTR::computeMD5HashStringForContext): Simplify the #ifdefs around the braces. * WebKitTestRunner/mac/PlatformWebViewMac.mm: (WTR::PlatformWebView::PlatformWebView): Set the window's colorspace to that of the main display. (WTR::PlatformWebView::windowSnapshotImage): Add comment about colorspaces. git-svn-id: http://svn.webkit.org/repository/webkit/trunk@104351 268f45cc-cd09-0410-ab3c-d52691b4dbfc
e87b8372