[PATCH v2 1/2] wined3d: Support AMD alpha to coverage state.

Henri Verbeet hverbeet at gmail.com
Tue Feb 11 15:02:50 CST 2020


On Tue, 11 Feb 2020 at 20:48, Paul Gofman <gofmanp at gmail.com> wrote:
> On 2/11/20 19:32, Henri Verbeet wrote:
> > On Mon, 10 Feb 2020 at 20:41, Paul Gofman <gofmanp at gmail.com> wrote:
> >> -static void state_blend_object(struct wined3d_context *context, const struct wined3d_state *state, DWORD state_id)
> >> +void state_atoc(struct wined3d_context *context, const struct wined3d_state *state, DWORD state_id)
> >>  {
> > Why the rename? This is still the handler for blend state objects.
> I thought the handler is already dealing just with ATOC state, other
> parts of blend state are handled elsewhere. And now this is extended to
> different ways of setting ATOC. Should I get the name back?

The wined3d_blend_state_desc structure currently only contains the
alpha to coverage state, but the idea is for it to become more similar
to the d3d11 blend state object.

> Otherwise I can maybe handle those states changes in
> wined3d_cs_exec_set_render_state() and put a flag to wined3d_state which
> will indicate if ATOC needs to be set or reset.
>
That won't work; see the way e.g. d3d9_device_SetRenderState() works
after Zebediah's recent changes.

I.e., if the application does something like the following:

    SetRenderState(..., D3DRS_POINTSIZE, ...);
    SetRenderState(..., D3DRS_POINTSIZE, ...);
    SetRenderState(..., D3DRS_POINTSIZE, ...);
    DrawPrimitive(...);

wined3d will never see the first two D3DRS_POINTSIZE values, and will
only see the third one once the DrawPrimitive() call is made.



More information about the wine-devel mailing list