[PATCH 2/5] d3d9/tests: Allow the creation of SWVP devices

Henri Verbeet hverbeet at gmail.com
Tue Jan 15 01:33:21 CST 2013


On 15 January 2013 00:13, Stefan Dösinger <stefan at codeweavers.com> wrote:
> -static IDirect3DDevice9 *create_device(IDirect3D9 *d3d9, HWND device_window, HWND focus_window, BOOL windowed)
> +static IDirect3DDevice9 *create_device(IDirect3D9 *d3d9, HWND device_window, HWND focus_window, BOOL windowed,
> +        DWORD flags)
>  {
>      D3DPRESENT_PARAMETERS present_parameters = {0};
>      IDirect3DDevice9 *device;
> @@ -90,7 +91,7 @@ static IDirect3DDevice9 *create_device(IDirect3D9 *d3d9, HWND device_window, HWN
>      present_parameters.AutoDepthStencilFormat = D3DFMT_D24S8;
>
>      if (SUCCEEDED(IDirect3D9_CreateDevice(d3d9, D3DADAPTER_DEFAULT, D3DDEVTYPE_HAL, focus_window,
> -            D3DCREATE_HARDWARE_VERTEXPROCESSING, &present_parameters, &device))) return device;
> +            flags, &present_parameters, &device))) return device;
>
If this fails, we're going to try hardware vertex processing again,
but I don't think this is something we want to specify for every
single test anyway. If this is just for a single test that needs
software vertex processing, just write it out. If you already know
there are going to be multiple tests like this, you could probably
introduce a function like create_swvp_device().



More information about the wine-devel mailing list