Bug 191093 - [Win][Direct2D] Support building DumpRenderTree for Direct2D
Summary: [Win][Direct2D] Support building DumpRenderTree for Direct2D
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Brent Fulgham
Keywords: InRadar
Depends on:
Blocks: 191411
  Show dependency treegraph
Reported: 2018-10-30 16:47 PDT by Brent Fulgham
Modified: 2018-11-07 19:50 PST (History)
6 users (show)

See Also:

Patch (5.46 KB, patch)
2018-10-30 16:53 PDT, Brent Fulgham
no flags Details | Formatted Diff | Diff
Patch (11.77 KB, patch)
2018-10-30 17:07 PDT, Brent Fulgham
achristensen: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Brent Fulgham 2018-10-30 16:47:02 PDT
Update WebKit's DumpRenderTree project files so that we can build and run layout tests. This initial implementation does not dump pixel data (we are a ways away from pixel-perfect comparisons), but we can begin identifying areas that need work.
Comment 1 Radar WebKit Bug Importer 2018-10-30 16:48:02 PDT
Comment 2 Brent Fulgham 2018-10-30 16:53:23 PDT
Created attachment 353437 [details]
Comment 3 Don Olmstead 2018-10-30 16:58:50 PDT
Comment on attachment 353437 [details]

View in context: https://bugs.webkit.org/attachment.cgi?id=353437&action=review

Minor nit pick on the cmake side other than that everything looks good

Informal r+

> Tools/DumpRenderTree/PlatformWin.cmake:112
> +        list(APPEND DumpRenderTreeLib_LIBRARIES

You could move common libraries out of the if statement
Comment 4 Brent Fulgham 2018-10-30 17:07:43 PDT
Created attachment 353442 [details]
Comment 5 Alex Christensen 2018-10-30 18:43:41 PDT
Comment on attachment 353442 [details]

View in context: https://bugs.webkit.org/attachment.cgi?id=353442&action=review


> Tools/DumpRenderTree/win/PixelDumpSupportDirect2D.cpp:41
> +using namespace std;

Please no.

> Tools/DumpRenderTree/win/PixelDumpSupportDirect2D.h:31
> +#include <vector>

let's not.

> Tools/DumpRenderTree/win/PixelDumpSupportDirect2D.h:52
> +    std::vector<unsigned char> m_data;

Also, this isn't used.
Comment 6 Brent Fulgham 2018-10-30 19:29:22 PDT
Committed r237616: <https://trac.webkit.org/changeset/237616>
Comment 7 Fujii Hironori 2018-10-30 19:59:47 PDT
Windows port BuildBots seem to get broken by this change.


> C:\cygwin\home\buildbot\slave\win-release\build\Tools\DumpRenderTree\PixelDumpSupport.cpp(41): fatal error C1083: Cannot open include file: 'PixelDumpSupportCG.h': No such file or directory [C:\cygwin\home\buildbot\slave\win-release\build\WebKitBuild\Release\Tools\DumpRenderTree\DumpRenderTreeLib.vcxproj]


> FAILED: Tools/DumpRenderTree/CMakeFiles/DumpRenderTreeLib.dir/win/PixelDumpSupportWin.cpp.obj 
> "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\VC\Tools\MSVC\14.14.26428\bin\Hostx64\x64\cl.exe"  (...) -c ..\..\Tools\DumpRenderTree\win\PixelDumpSupportWin.cpp
> ..\..\Tools\DumpRenderTree\win\PixelDumpSupportWin.cpp(114): error C2065: 'renderTarget': undeclared identifier
> ..\..\Tools\DumpRenderTree\win\PixelDumpSupportWin.cpp(114): error C2228: left of '.get' must have class/struct/union
> ..\..\Tools\DumpRenderTree\win\PixelDumpSupportWin.cpp(114): note: type is 'unknown-type'
> ..\..\Tools\DumpRenderTree\win\PixelDumpSupportWin.cpp(114): error C2660: 'BitmapContext::createByAdoptingBitmapAndContext': function does not take 1 arguments
> C:\WebKit-BuildWorker\wincairo-wkl-release\build\Tools\DumpRenderTree\cairo\PixelDumpSupportCairo.h(50): note: see declaration
Comment 8 Brent Fulgham 2018-10-30 20:29:08 PDT
(In reply to Fujii Hironori from comment #7)
> Windows port BuildBots seem to get broken by this change.
Oh, yes. I left the Direct2D flag on. I will land a fix ASAP.
Comment 9 Brent Fulgham 2018-10-30 20:32:12 PDT
Committed build fix:

Committed r237619: <https://trac.webkit.org/changeset/237619>
Comment 10 Fujii Hironori 2018-10-30 21:51:06 PDT
Committed r237622: <https://trac.webkit.org/changeset/237622>