wined3d: Get rid of the "target" parameter to context_create().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
74ba0fb156
commit
186ae1ad78
|
@ -1966,9 +1966,9 @@ static BOOL wined3d_context_init(struct wined3d_context *context, struct wined3d
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
struct wined3d_context *context_create(struct wined3d_swapchain *swapchain,
|
||||
struct wined3d_texture *target, const struct wined3d_format *ds_format)
|
||||
struct wined3d_context *context_create(struct wined3d_swapchain *swapchain, const struct wined3d_format *ds_format)
|
||||
{
|
||||
struct wined3d_texture *target = swapchain->front_buffer;
|
||||
struct wined3d_device *device = swapchain->device;
|
||||
struct wined3d_context_gl *context_gl;
|
||||
struct wined3d_context *context;
|
||||
|
|
|
@ -739,7 +739,7 @@ static void wined3d_swapchain_cs_init(void *object)
|
|||
for (i = 0; i < ARRAY_SIZE(formats); ++i)
|
||||
{
|
||||
swapchain->ds_format = wined3d_get_format(adapter, formats[i], WINED3D_BIND_DEPTH_STENCIL);
|
||||
if ((swapchain->context[0] = context_create(swapchain, swapchain->front_buffer, swapchain->ds_format)))
|
||||
if ((swapchain->context[0] = context_create(swapchain, swapchain->ds_format)))
|
||||
break;
|
||||
TRACE("Depth stencil format %s is not supported, trying next format.\n", debug_d3dformat(formats[i]));
|
||||
}
|
||||
|
@ -1085,7 +1085,7 @@ static struct wined3d_context *swapchain_create_context(struct wined3d_swapchain
|
|||
|
||||
TRACE("Creating a new context for swapchain %p, thread %u.\n", swapchain, GetCurrentThreadId());
|
||||
|
||||
if (!(ctx = context_create(swapchain, swapchain->front_buffer, swapchain->ds_format)))
|
||||
if (!(ctx = context_create(swapchain, swapchain->ds_format)))
|
||||
{
|
||||
ERR("Failed to create a new context for the swapchain\n");
|
||||
return NULL;
|
||||
|
|
|
@ -2196,7 +2196,7 @@ void context_check_fbo_status(const struct wined3d_context *context, GLenum targ
|
|||
void context_copy_bo_address(struct wined3d_context *context,
|
||||
const struct wined3d_bo_address *dst, GLenum dst_binding,
|
||||
const struct wined3d_bo_address *src, GLenum src_binding, size_t size) DECLSPEC_HIDDEN;
|
||||
struct wined3d_context *context_create(struct wined3d_swapchain *swapchain, struct wined3d_texture *target,
|
||||
struct wined3d_context *context_create(struct wined3d_swapchain *swapchain,
|
||||
const struct wined3d_format *ds_format) DECLSPEC_HIDDEN;
|
||||
HGLRC context_create_wgl_attribs(const struct wined3d_gl_info *gl_info, HDC hdc, HGLRC share_ctx) DECLSPEC_HIDDEN;
|
||||
void wined3d_context_destroy(struct wined3d_context *context) DECLSPEC_HIDDEN;
|
||||
|
|
Loading…
Reference in New Issue