[PATCH 5/5] wined3d: Pass the state and private data to shader_select

Henri Verbeet hverbeet at gmail.com
Mon May 13 10:44:59 CDT 2013


On 13 May 2013 16:39, Stefan Dösinger <stefan at codeweavers.com> wrote:
>
> Am 13.05.2013 um 15:28 schrieb Henri Verbeet <hverbeet at gmail.com>:
>
>> On 12 May 2013 15:30, Stefan Dösinger <stefan at codeweavers.com> wrote:
>>>     /* Disable shaders */
>>> -    device->shader_backend->shader_select(context, WINED3D_SHADER_MODE_NONE, WINED3D_SHADER_MODE_NONE);
>>> +    device->shader_backend->shader_select(context, WINED3D_SHADER_MODE_NONE, WINED3D_SHADER_MODE_NONE,
>>> +            NULL, device->shader_priv);
>> I think that's a bit questionable. Passing NULL state happens to work
>> for this set of arguments, but I don't think we want that to be part
>> of the interface.
> I think it's the best solution. SetupForBlit does not have any state information, which makes sense because it has no relation with d3d draws. Even if we grab some state information from somewhere (e.g. the stateblock, or the command stream) there's no guarantee that it is set up in a useful way. It could e.g. have a NULL vdecl or mismatched vertex/pixel shaders etc.
>
Maybe. Perhaps we could also just get rid of WINED3D_SHADER_MODE_NONE
and add a separate call instead.



More information about the wine-devel mailing list