[prev in list] [next in list] [prev in thread] [next in thread] 

List:       wine-devel
Subject:    Re: [PATCH 1/4] wined3d: Allow specifying a different depth stencil location.
From:       Henri Verbeet <hverbeet () gmail ! com>
Date:       2015-04-30 9:09:03
Message-ID: CAOsNvwz7KxN8HB4pNPsWxfeXgGkJsx8k+bfzVGYBw87yhx96Zg () mail ! gmail ! com
[Download RAW message or body]

On 30 April 2015 at 00:00, Stefan Dösinger <stefan@codeweavers.com> wrote:
> @@ -2342,12 +2352,14 @@ BOOL context_apply_clear_state(struct wined3d_context \
> *context, const struct win ++i;
> }
> context_apply_fbo_state(context, GL_FRAMEBUFFER, context->blit_targets,
> -                        wined3d_rendertarget_view_get_surface(fb->depth_stencil),
> -                        rt_count ? rts[0]->resource->draw_binding : \
> WINED3D_LOCATION_TEXTURE_RGB); +                        \
> wined3d_rendertarget_view_get_surface(dsv), +                        rt_count ? \
> rts[0]->resource->draw_binding : WINED3D_LOCATION_TEXTURE_RGB, +                    \
> dsv ? dsv->resource->draw_binding : WINED3D_LOCATION_TEXTURE_RGB); }
This works because we mostly just care that the color location isn't
WINED3D_LOCATION_DRAWABLE if there's no attachment. (In particular for
the case where the application is doing depth only rendering.)
Strictly speaking though, it's probably more correct to use the color
location if there's no depth/stencil attachment, to avoid silliness
like the color attachment being in WINED3D_LOCATION_DRAWABLE and the
depth/stencil attachment in WINED3D_LOCATION_TEXTURE_RGB. In fact, now
that the color and depth/stencil locations are separate, you can
probably just pass 0.


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic