You've already forked wine-staging
mirror of
https://gitlab.winehq.org/wine/wine-staging.git
synced 2025-09-12 18:50:20 -07:00
Rebase against 6bb8ca1e25a9cfc66f396b2ae6bc423a8057929c.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
From dc12ee16f10892c34b7132b062d7c47f76691c8f Mon Sep 17 00:00:00 2001
|
||||
From b3515e5f92033c1a785e656eddcba4ffa711f0fc Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Stefan=20D=C3=B6singer?= <stefan@codeweavers.com>
|
||||
Date: Tue, 1 Oct 2013 14:31:56 +0200
|
||||
Subject: wined3d: Hackily introduce a multithreaded command stream
|
||||
@@ -27,10 +27,10 @@ index c1dbe9e835f..5ca4a14fa6a 100644
|
||||
memset(&data, 0xff, sizeof(data));
|
||||
hr = ID3D10Asynchronous_GetData(query, &data, sizeof(DWORD), 0);
|
||||
diff --git a/dlls/d3d11/tests/d3d11.c b/dlls/d3d11/tests/d3d11.c
|
||||
index a63a4ea507b..40e0241a463 100644
|
||||
index da2edc5d2d6..61617d147bb 100644
|
||||
--- a/dlls/d3d11/tests/d3d11.c
|
||||
+++ b/dlls/d3d11/tests/d3d11.c
|
||||
@@ -5245,7 +5245,7 @@ static void test_occlusion_query(void)
|
||||
@@ -4767,7 +4767,7 @@ static void test_occlusion_query(void)
|
||||
memset(&data, 0xff, sizeof(data));
|
||||
hr = ID3D11DeviceContext_GetData(context, query, &data, sizeof(data), 0);
|
||||
ok(hr == S_OK, "Got unexpected hr %#x.\n", hr);
|
||||
@@ -39,7 +39,7 @@ index a63a4ea507b..40e0241a463 100644
|
||||
|
||||
memset(&data, 0xff, sizeof(data));
|
||||
hr = ID3D11DeviceContext_GetData(context, query, &data, sizeof(DWORD), 0);
|
||||
@@ -9533,7 +9533,7 @@ static void test_draw_uav_only(void)
|
||||
@@ -8893,7 +8893,7 @@ static void test_draw_uav_only(void)
|
||||
draw_quad(&test_context);
|
||||
draw_quad(&test_context);
|
||||
draw_quad(&test_context);
|
||||
@@ -49,7 +49,7 @@ index a63a4ea507b..40e0241a463 100644
|
||||
ID3D11PixelShader_Release(ps);
|
||||
ID3D11Texture2D_Release(texture);
|
||||
diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c
|
||||
index 40e514cec7b..9bef6188f68 100644
|
||||
index f2168d66a33..3a728162eb4 100644
|
||||
--- a/dlls/wined3d/context.c
|
||||
+++ b/dlls/wined3d/context.c
|
||||
@@ -1353,6 +1353,9 @@ void context_release(struct wined3d_context *context)
|
||||
@@ -62,7 +62,7 @@ index 40e514cec7b..9bef6188f68 100644
|
||||
if (!--context->level)
|
||||
{
|
||||
if (context_restore_pixel_format(context))
|
||||
@@ -3658,6 +3661,13 @@ struct wined3d_context *context_acquire(const struct wined3d_device *device, str
|
||||
@@ -3694,6 +3697,13 @@ struct wined3d_context *context_acquire(const struct wined3d_device *device, str
|
||||
|
||||
TRACE("device %p, target %p.\n", device, target);
|
||||
|
||||
@@ -77,7 +77,7 @@ index 40e514cec7b..9bef6188f68 100644
|
||||
current_context = NULL;
|
||||
|
||||
diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c
|
||||
index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
index 422f3f1e5df..518db143421 100644
|
||||
--- a/dlls/wined3d/cs.c
|
||||
+++ b/dlls/wined3d/cs.c
|
||||
@@ -18,14 +18,26 @@
|
||||
@@ -529,7 +529,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_texture(struct wined3d_cs *cs, UINT stage, struct wined3d_texture *texture)
|
||||
@@ -1015,12 +1179,14 @@ void wined3d_cs_emit_set_texture(struct wined3d_cs *cs, UINT stage, struct wined
|
||||
@@ -1015,13 +1179,15 @@ void wined3d_cs_emit_set_texture(struct wined3d_cs *cs, UINT stage, struct wined
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -539,13 +539,14 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
const struct wined3d_cs_set_shader_resource_view *op = data;
|
||||
|
||||
cs->state.shader_resource_view[op->type][op->view_idx] = op->view;
|
||||
device_invalidate_state(cs->device, STATE_SHADER_RESOURCE_BINDING);
|
||||
if (op->type != WINED3D_SHADER_TYPE_COMPUTE)
|
||||
device_invalidate_state(cs->device, STATE_SHADER_RESOURCE_BINDING);
|
||||
+
|
||||
+ return sizeof(*op);
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_unordered_access_view(struct wined3d_cs *cs, unsigned int view_idx,
|
||||
@@ -1036,7 +1202,7 @@ void wined3d_cs_emit_set_unordered_access_view(struct wined3d_cs *cs, unsigned i
|
||||
@@ -1037,7 +1203,7 @@ void wined3d_cs_emit_set_unordered_access_view(struct wined3d_cs *cs, unsigned i
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -554,7 +555,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
{
|
||||
const struct wined3d_cs_set_unordered_access_view *op = data;
|
||||
struct wined3d_unordered_access_view *prev;
|
||||
@@ -1050,6 +1216,8 @@ static void wined3d_cs_exec_set_unordered_access_view(struct wined3d_cs *cs, con
|
||||
@@ -1051,6 +1217,8 @@ static void wined3d_cs_exec_set_unordered_access_view(struct wined3d_cs *cs, con
|
||||
InterlockedDecrement(&prev->resource->bind_count);
|
||||
|
||||
device_invalidate_state(cs->device, STATE_UNORDERED_ACCESS_VIEW_BINDING);
|
||||
@@ -563,7 +564,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_shader_resource_view(struct wined3d_cs *cs, enum wined3d_shader_type type,
|
||||
@@ -1066,12 +1234,14 @@ void wined3d_cs_emit_set_shader_resource_view(struct wined3d_cs *cs, enum wined3
|
||||
@@ -1067,12 +1235,14 @@ void wined3d_cs_emit_set_shader_resource_view(struct wined3d_cs *cs, enum wined3
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -579,7 +580,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_sampler(struct wined3d_cs *cs, enum wined3d_shader_type type,
|
||||
@@ -1088,13 +1258,15 @@ void wined3d_cs_emit_set_sampler(struct wined3d_cs *cs, enum wined3d_shader_type
|
||||
@@ -1089,7 +1259,7 @@ void wined3d_cs_emit_set_sampler(struct wined3d_cs *cs, enum wined3d_shader_type
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -588,15 +589,16 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
{
|
||||
const struct wined3d_cs_set_shader *op = data;
|
||||
|
||||
cs->state.shader[op->type] = op->shader;
|
||||
@@ -1097,6 +1267,8 @@ static void wined3d_cs_exec_set_shader(struct wined3d_cs *cs, const void *data)
|
||||
device_invalidate_state(cs->device, STATE_SHADER(op->type));
|
||||
device_invalidate_state(cs->device, STATE_SHADER_RESOURCE_BINDING);
|
||||
if (op->type != WINED3D_SHADER_TYPE_COMPUTE)
|
||||
device_invalidate_state(cs->device, STATE_SHADER_RESOURCE_BINDING);
|
||||
+
|
||||
+ return sizeof(*op);
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_shader(struct wined3d_cs *cs, enum wined3d_shader_type type, struct wined3d_shader *shader)
|
||||
@@ -1109,12 +1281,14 @@ void wined3d_cs_emit_set_shader(struct wined3d_cs *cs, enum wined3d_shader_type
|
||||
@@ -1111,12 +1283,14 @@ void wined3d_cs_emit_set_shader(struct wined3d_cs *cs, enum wined3d_shader_type
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -612,7 +614,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_rasterizer_state(struct wined3d_cs *cs,
|
||||
@@ -1129,12 +1303,14 @@ void wined3d_cs_emit_set_rasterizer_state(struct wined3d_cs *cs,
|
||||
@@ -1131,12 +1305,14 @@ void wined3d_cs_emit_set_rasterizer_state(struct wined3d_cs *cs,
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -628,7 +630,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_render_state(struct wined3d_cs *cs, enum wined3d_render_state state, DWORD value)
|
||||
@@ -1149,12 +1325,14 @@ void wined3d_cs_emit_set_render_state(struct wined3d_cs *cs, enum wined3d_render
|
||||
@@ -1151,12 +1327,14 @@ void wined3d_cs_emit_set_render_state(struct wined3d_cs *cs, enum wined3d_render
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -644,7 +646,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_texture_state(struct wined3d_cs *cs, UINT stage,
|
||||
@@ -1171,12 +1349,14 @@ void wined3d_cs_emit_set_texture_state(struct wined3d_cs *cs, UINT stage,
|
||||
@@ -1173,12 +1351,14 @@ void wined3d_cs_emit_set_texture_state(struct wined3d_cs *cs, UINT stage,
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -660,7 +662,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_sampler_state(struct wined3d_cs *cs, UINT sampler_idx,
|
||||
@@ -1193,13 +1373,15 @@ void wined3d_cs_emit_set_sampler_state(struct wined3d_cs *cs, UINT sampler_idx,
|
||||
@@ -1195,13 +1375,15 @@ void wined3d_cs_emit_set_sampler_state(struct wined3d_cs *cs, UINT sampler_idx,
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -677,7 +679,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_transform(struct wined3d_cs *cs, enum wined3d_transform_state state,
|
||||
@@ -1215,12 +1397,14 @@ void wined3d_cs_emit_set_transform(struct wined3d_cs *cs, enum wined3d_transform
|
||||
@@ -1217,12 +1399,14 @@ void wined3d_cs_emit_set_transform(struct wined3d_cs *cs, enum wined3d_transform
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -693,7 +695,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_clip_plane(struct wined3d_cs *cs, UINT plane_idx, const struct wined3d_vec4 *plane)
|
||||
@@ -1235,7 +1419,7 @@ void wined3d_cs_emit_set_clip_plane(struct wined3d_cs *cs, UINT plane_idx, const
|
||||
@@ -1237,7 +1421,7 @@ void wined3d_cs_emit_set_clip_plane(struct wined3d_cs *cs, UINT plane_idx, const
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -702,7 +704,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
{
|
||||
const struct wined3d_cs_set_color_key *op = data;
|
||||
struct wined3d_texture *texture = op->texture;
|
||||
@@ -1296,6 +1480,8 @@ static void wined3d_cs_exec_set_color_key(struct wined3d_cs *cs, const void *dat
|
||||
@@ -1298,6 +1482,8 @@ static void wined3d_cs_exec_set_color_key(struct wined3d_cs *cs, const void *dat
|
||||
break;
|
||||
}
|
||||
}
|
||||
@@ -711,7 +713,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_color_key(struct wined3d_cs *cs, struct wined3d_texture *texture,
|
||||
@@ -1318,12 +1504,14 @@ void wined3d_cs_emit_set_color_key(struct wined3d_cs *cs, struct wined3d_texture
|
||||
@@ -1320,12 +1506,14 @@ void wined3d_cs_emit_set_color_key(struct wined3d_cs *cs, struct wined3d_texture
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -727,7 +729,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_set_material(struct wined3d_cs *cs, const struct wined3d_material *material)
|
||||
@@ -1337,7 +1525,7 @@ void wined3d_cs_emit_set_material(struct wined3d_cs *cs, const struct wined3d_ma
|
||||
@@ -1339,7 +1527,7 @@ void wined3d_cs_emit_set_material(struct wined3d_cs *cs, const struct wined3d_ma
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -736,7 +738,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
{
|
||||
struct wined3d_adapter *adapter = cs->device->adapter;
|
||||
|
||||
@@ -1345,6 +1533,8 @@ static void wined3d_cs_exec_reset_state(struct wined3d_cs *cs, const void *data)
|
||||
@@ -1347,6 +1535,8 @@ static void wined3d_cs_exec_reset_state(struct wined3d_cs *cs, const void *data)
|
||||
memset(&cs->state, 0, sizeof(cs->state));
|
||||
state_init(&cs->state, &cs->fb, &adapter->gl_info, &adapter->d3d_info,
|
||||
WINED3D_STATE_NO_REF | WINED3D_STATE_INIT_DEFAULT);
|
||||
@@ -745,7 +747,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_reset_state(struct wined3d_cs *cs)
|
||||
@@ -1357,11 +1547,13 @@ void wined3d_cs_emit_reset_state(struct wined3d_cs *cs)
|
||||
@@ -1359,11 +1549,13 @@ void wined3d_cs_emit_reset_state(struct wined3d_cs *cs)
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -760,7 +762,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_destroy_object(struct wined3d_cs *cs, void (*callback)(void *object), void *object)
|
||||
@@ -1376,12 +1568,14 @@ void wined3d_cs_emit_destroy_object(struct wined3d_cs *cs, void (*callback)(void
|
||||
@@ -1378,12 +1570,14 @@ void wined3d_cs_emit_destroy_object(struct wined3d_cs *cs, void (*callback)(void
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -776,7 +778,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_query_issue(struct wined3d_cs *cs, struct wined3d_query *query, DWORD flags)
|
||||
@@ -1396,13 +1590,41 @@ void wined3d_cs_emit_query_issue(struct wined3d_cs *cs, struct wined3d_query *qu
|
||||
@@ -1398,13 +1592,41 @@ void wined3d_cs_emit_query_issue(struct wined3d_cs *cs, struct wined3d_query *qu
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -819,7 +821,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_preload_resource(struct wined3d_cs *cs, struct wined3d_resource *resource)
|
||||
@@ -1418,13 +1640,15 @@ void wined3d_cs_emit_preload_resource(struct wined3d_cs *cs, struct wined3d_reso
|
||||
@@ -1420,13 +1642,15 @@ void wined3d_cs_emit_preload_resource(struct wined3d_cs *cs, struct wined3d_reso
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -836,7 +838,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
void wined3d_cs_emit_unload_resource(struct wined3d_cs *cs, struct wined3d_resource *resource)
|
||||
@@ -1440,13 +1664,15 @@ void wined3d_cs_emit_unload_resource(struct wined3d_cs *cs, struct wined3d_resou
|
||||
@@ -1442,13 +1666,15 @@ void wined3d_cs_emit_unload_resource(struct wined3d_cs *cs, struct wined3d_resou
|
||||
cs->ops->submit(cs);
|
||||
}
|
||||
|
||||
@@ -853,7 +855,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
HRESULT wined3d_cs_map(struct wined3d_cs *cs, struct wined3d_resource *resource, unsigned int sub_resource_idx,
|
||||
@@ -1464,17 +1690,19 @@ HRESULT wined3d_cs_map(struct wined3d_cs *cs, struct wined3d_resource *resource,
|
||||
@@ -1466,17 +1692,19 @@ HRESULT wined3d_cs_map(struct wined3d_cs *cs, struct wined3d_resource *resource,
|
||||
op->flags = flags;
|
||||
op->hr = &hr;
|
||||
|
||||
@@ -875,7 +877,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
}
|
||||
|
||||
HRESULT wined3d_cs_unmap(struct wined3d_cs *cs, struct wined3d_resource *resource, unsigned int sub_resource_idx)
|
||||
@@ -1488,13 +1716,35 @@ HRESULT wined3d_cs_unmap(struct wined3d_cs *cs, struct wined3d_resource *resourc
|
||||
@@ -1490,13 +1718,35 @@ HRESULT wined3d_cs_unmap(struct wined3d_cs *cs, struct wined3d_resource *resourc
|
||||
op->sub_resource_idx = sub_resource_idx;
|
||||
op->hr = &hr;
|
||||
|
||||
@@ -913,7 +915,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
/* WINED3D_CS_OP_PRESENT */ wined3d_cs_exec_present,
|
||||
/* WINED3D_CS_OP_CLEAR */ wined3d_cs_exec_clear,
|
||||
/* WINED3D_CS_OP_DISPATCH */ wined3d_cs_exec_dispatch,
|
||||
@@ -1526,10 +1776,12 @@ static void (* const wined3d_cs_op_handlers[])(struct wined3d_cs *cs, const void
|
||||
@@ -1528,10 +1778,12 @@ static void (* const wined3d_cs_op_handlers[])(struct wined3d_cs *cs, const void
|
||||
/* WINED3D_CS_OP_RESET_STATE */ wined3d_cs_exec_reset_state,
|
||||
/* WINED3D_CS_OP_DESTROY_OBJECT */ wined3d_cs_exec_destroy_object,
|
||||
/* WINED3D_CS_OP_QUERY_ISSUE */ wined3d_cs_exec_query_issue,
|
||||
@@ -926,7 +928,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
};
|
||||
|
||||
static void *wined3d_cs_st_require_space(struct wined3d_cs *cs, size_t size)
|
||||
@@ -1603,9 +1855,113 @@ static const struct wined3d_cs_ops wined3d_cs_st_ops =
|
||||
@@ -1605,9 +1857,113 @@ static const struct wined3d_cs_ops wined3d_cs_st_ops =
|
||||
{
|
||||
wined3d_cs_st_require_space,
|
||||
wined3d_cs_st_submit,
|
||||
@@ -1040,7 +1042,7 @@ index 220ddeebe98..c0d8a5f2fd5 100644
|
||||
struct wined3d_cs *wined3d_cs_create(struct wined3d_device *device)
|
||||
{
|
||||
const struct wined3d_gl_info *gl_info = &device->adapter->gl_info;
|
||||
@@ -1635,12 +1991,64 @@ struct wined3d_cs *wined3d_cs_create(struct wined3d_device *device)
|
||||
@@ -1637,12 +1993,64 @@ struct wined3d_cs *wined3d_cs_create(struct wined3d_device *device)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -1119,7 +1121,7 @@ index 3bdba105105..abb4a664c1a 100644
|
||||
|
||||
if (data)
|
||||
diff --git a/dlls/wined3d/wined3d_main.c b/dlls/wined3d/wined3d_main.c
|
||||
index e7962465279..a8409cfd4b8 100644
|
||||
index 2085864bc7f..01eb71a89e7 100644
|
||||
--- a/dlls/wined3d/wined3d_main.c
|
||||
+++ b/dlls/wined3d/wined3d_main.c
|
||||
@@ -90,6 +90,7 @@ struct wined3d_settings wined3d_settings =
|
||||
@@ -1149,7 +1151,7 @@ index e7962465279..a8409cfd4b8 100644
|
||||
if (hkey) RegCloseKey( hkey );
|
||||
|
||||
diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h
|
||||
index 00709bdab09..d225e85b909 100644
|
||||
index d93befa13bb..2ab0aca10ab 100644
|
||||
--- a/dlls/wined3d/wined3d_private.h
|
||||
+++ b/dlls/wined3d/wined3d_private.h
|
||||
@@ -306,6 +306,7 @@ struct wined3d_settings
|
||||
@@ -1160,7 +1162,7 @@ index 00709bdab09..d225e85b909 100644
|
||||
};
|
||||
|
||||
extern struct wined3d_settings wined3d_settings DECLSPEC_HIDDEN;
|
||||
@@ -2705,11 +2706,6 @@ static inline void wined3d_resource_release(struct wined3d_resource *resource)
|
||||
@@ -2730,11 +2731,6 @@ static inline void wined3d_resource_release(struct wined3d_resource *resource)
|
||||
InterlockedDecrement(&resource->access_count);
|
||||
}
|
||||
|
||||
@@ -1172,7 +1174,7 @@ index 00709bdab09..d225e85b909 100644
|
||||
void resource_cleanup(struct wined3d_resource *resource) DECLSPEC_HIDDEN;
|
||||
HRESULT resource_init(struct wined3d_resource *resource, struct wined3d_device *device,
|
||||
enum wined3d_resource_type type, const struct wined3d_format *format,
|
||||
@@ -3119,10 +3115,23 @@ enum wined3d_push_constants
|
||||
@@ -3144,10 +3140,23 @@ enum wined3d_push_constants
|
||||
WINED3D_PUSH_CONSTANTS_PS_B,
|
||||
};
|
||||
|
||||
@@ -1196,7 +1198,7 @@ index 00709bdab09..d225e85b909 100644
|
||||
void (*push_constants)(struct wined3d_cs *cs, enum wined3d_push_constants p,
|
||||
unsigned int start_idx, unsigned int count, const void *constants);
|
||||
};
|
||||
@@ -3133,11 +3142,22 @@ struct wined3d_cs
|
||||
@@ -3158,11 +3167,22 @@ struct wined3d_cs
|
||||
struct wined3d_device *device;
|
||||
struct wined3d_fb_state fb;
|
||||
struct wined3d_state state;
|
||||
@@ -1220,7 +1222,7 @@ index 00709bdab09..d225e85b909 100644
|
||||
struct wined3d_cs *wined3d_cs_create(struct wined3d_device *device) DECLSPEC_HIDDEN;
|
||||
void wined3d_cs_destroy(struct wined3d_cs *cs) DECLSPEC_HIDDEN;
|
||||
|
||||
@@ -3149,10 +3169,12 @@ void wined3d_cs_emit_dispatch(struct wined3d_cs *cs,
|
||||
@@ -3174,10 +3194,12 @@ void wined3d_cs_emit_dispatch(struct wined3d_cs *cs,
|
||||
unsigned int group_count_x, unsigned int group_count_y, unsigned int group_count_z) DECLSPEC_HIDDEN;
|
||||
void wined3d_cs_emit_draw(struct wined3d_cs *cs, int base_vertex_idx, unsigned int start_idx, unsigned int index_count,
|
||||
unsigned int start_instance, unsigned int instance_count, BOOL indexed) DECLSPEC_HIDDEN;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
From 184350c6cdfd80d576b8c15fbba5c2edc90eaf0b Mon Sep 17 00:00:00 2001
|
||||
From 905a31e15556a725e6ab9ee0e8e32d46474a820b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Stefan=20D=C3=B6singer?= <stefan@codeweavers.com>
|
||||
Date: Thu, 20 Dec 2012 13:09:17 +0100
|
||||
Subject: wined3d: Move the framebuffer into wined3d_state
|
||||
@@ -19,7 +19,7 @@ Subject: wined3d: Move the framebuffer into wined3d_state
|
||||
12 files changed, 183 insertions(+), 127 deletions(-)
|
||||
|
||||
diff --git a/dlls/wined3d/arb_program_shader.c b/dlls/wined3d/arb_program_shader.c
|
||||
index 7fc97b5d999..8128c099076 100644
|
||||
index 85ed462c78d..1191a6d5873 100644
|
||||
--- a/dlls/wined3d/arb_program_shader.c
|
||||
+++ b/dlls/wined3d/arb_program_shader.c
|
||||
@@ -701,7 +701,7 @@ static void shader_arb_load_constants_internal(struct shader_arb_priv *priv,
|
||||
@@ -41,10 +41,10 @@ index 7fc97b5d999..8128c099076 100644
|
||||
}
|
||||
|
||||
diff --git a/dlls/wined3d/context.c b/dlls/wined3d/context.c
|
||||
index 9bef6188f68..51dfaea4ed4 100644
|
||||
index 3a728162eb4..bc27695c08e 100644
|
||||
--- a/dlls/wined3d/context.c
|
||||
+++ b/dlls/wined3d/context.c
|
||||
@@ -1716,6 +1716,11 @@ struct wined3d_context *context_create(struct wined3d_swapchain *swapchain,
|
||||
@@ -1726,6 +1726,11 @@ struct wined3d_context *context_create(struct wined3d_swapchain *swapchain,
|
||||
goto out;
|
||||
}
|
||||
|
||||
@@ -56,7 +56,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
/* Initialize the texture unit mapping to a 1:1 mapping */
|
||||
for (s = 0; s < MAX_COMBINED_SAMPLERS; ++s)
|
||||
{
|
||||
@@ -2036,6 +2041,7 @@ out:
|
||||
@@ -2047,6 +2052,7 @@ out:
|
||||
if (hdc) wined3d_release_dc(swapchain->win_handle, hdc);
|
||||
device->shader_backend->shader_free_context_data(ret);
|
||||
device->adapter->fragment_pipe->free_context_data(ret);
|
||||
@@ -64,7 +64,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
HeapFree(GetProcessHeap(), 0, ret->free_event_queries);
|
||||
HeapFree(GetProcessHeap(), 0, ret->free_occlusion_queries);
|
||||
HeapFree(GetProcessHeap(), 0, ret->free_timestamp_queries);
|
||||
@@ -2083,6 +2089,7 @@ void context_destroy(struct wined3d_device *device, struct wined3d_context *cont
|
||||
@@ -2094,6 +2100,7 @@ void context_destroy(struct wined3d_device *device, struct wined3d_context *cont
|
||||
device->shader_backend->shader_free_context_data(context);
|
||||
device->adapter->fragment_pipe->free_context_data(context);
|
||||
HeapFree(GetProcessHeap(), 0, context->fbo_key);
|
||||
@@ -72,7 +72,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
HeapFree(GetProcessHeap(), 0, context->draw_buffers);
|
||||
HeapFree(GetProcessHeap(), 0, context->blit_targets);
|
||||
device_context_remove(device, context);
|
||||
@@ -2641,7 +2648,7 @@ BOOL context_apply_clear_state(struct wined3d_context *context, const struct win
|
||||
@@ -2652,7 +2659,7 @@ BOOL context_apply_clear_state(struct wined3d_context *context, const struct win
|
||||
DWORD rt_mask = 0, *cur_mask;
|
||||
UINT i;
|
||||
|
||||
@@ -81,7 +81,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
|| rt_count != gl_info->limits.buffers)
|
||||
{
|
||||
if (!context_validate_rt_config(rt_count, rts, dsv))
|
||||
@@ -2686,6 +2693,8 @@ BOOL context_apply_clear_state(struct wined3d_context *context, const struct win
|
||||
@@ -2697,6 +2704,8 @@ BOOL context_apply_clear_state(struct wined3d_context *context, const struct win
|
||||
rt_mask = context_generate_rt_mask_no_fbo(context,
|
||||
rt_count ? wined3d_rendertarget_view_get_surface(rts[0])->container : NULL);
|
||||
}
|
||||
@@ -90,7 +90,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
}
|
||||
else if (wined3d_settings.offscreen_rendering_mode == ORM_FBO
|
||||
&& (!rt_count || wined3d_resource_is_offscreen(rts[0]->resource)))
|
||||
@@ -2742,7 +2751,7 @@ BOOL context_apply_clear_state(struct wined3d_context *context, const struct win
|
||||
@@ -2753,7 +2762,7 @@ BOOL context_apply_clear_state(struct wined3d_context *context, const struct win
|
||||
|
||||
static DWORD find_draw_buffers_mask(const struct wined3d_context *context, const struct wined3d_state *state)
|
||||
{
|
||||
@@ -99,7 +99,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
struct wined3d_shader *ps = state->shader[WINED3D_SHADER_TYPE_PIXEL];
|
||||
DWORD rt_mask, rt_mask_bits;
|
||||
unsigned int i;
|
||||
@@ -2772,7 +2781,7 @@ static DWORD find_draw_buffers_mask(const struct wined3d_context *context, const
|
||||
@@ -2783,7 +2792,7 @@ static DWORD find_draw_buffers_mask(const struct wined3d_context *context, const
|
||||
void context_state_fb(struct wined3d_context *context, const struct wined3d_state *state, DWORD state_id)
|
||||
{
|
||||
DWORD rt_mask = find_draw_buffers_mask(context, state);
|
||||
@@ -108,7 +108,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
DWORD *cur_mask;
|
||||
|
||||
if (wined3d_settings.offscreen_rendering_mode == ORM_FBO)
|
||||
@@ -3061,6 +3070,8 @@ void context_state_drawbuf(struct wined3d_context *context, const struct wined3d
|
||||
@@ -3072,6 +3081,8 @@ void context_state_drawbuf(struct wined3d_context *context, const struct wined3d
|
||||
context_apply_draw_buffers(context, rt_mask);
|
||||
*cur_mask = rt_mask;
|
||||
}
|
||||
@@ -117,7 +117,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
}
|
||||
|
||||
static BOOL fixed_get_input(BYTE usage, BYTE usage_idx, unsigned int *regnum)
|
||||
@@ -3492,7 +3503,7 @@ BOOL context_apply_draw_state(struct wined3d_context *context,
|
||||
@@ -3507,7 +3518,7 @@ BOOL context_apply_draw_state(struct wined3d_context *context,
|
||||
const struct wined3d_device *device, const struct wined3d_state *state)
|
||||
{
|
||||
const struct StateEntry *state_table = context->state_table;
|
||||
@@ -127,7 +127,7 @@ index 9bef6188f68..51dfaea4ed4 100644
|
||||
WORD map;
|
||||
|
||||
diff --git a/dlls/wined3d/cs.c b/dlls/wined3d/cs.c
|
||||
index 71119320f56..01c81cde95e 100644
|
||||
index 553a58b7219..947ed482eca 100644
|
||||
--- a/dlls/wined3d/cs.c
|
||||
+++ b/dlls/wined3d/cs.c
|
||||
@@ -621,7 +621,7 @@ static UINT wined3d_cs_exec_present(struct wined3d_cs *cs, const void *data)
|
||||
@@ -238,7 +238,7 @@ index 71119320f56..01c81cde95e 100644
|
||||
|
||||
if (!prev != !op->view)
|
||||
{
|
||||
@@ -1697,11 +1697,13 @@ void wined3d_cs_emit_set_material(struct wined3d_cs *cs, const struct wined3d_ma
|
||||
@@ -1699,11 +1699,13 @@ void wined3d_cs_emit_set_material(struct wined3d_cs *cs, const struct wined3d_ma
|
||||
static UINT wined3d_cs_exec_reset_state(struct wined3d_cs *cs, const void *data)
|
||||
{
|
||||
struct wined3d_adapter *adapter = cs->device->adapter;
|
||||
@@ -254,7 +254,7 @@ index 71119320f56..01c81cde95e 100644
|
||||
|
||||
return sizeof(struct wined3d_cs_reset_state);
|
||||
}
|
||||
@@ -2799,15 +2801,13 @@ struct wined3d_cs *wined3d_cs_create(struct wined3d_device *device)
|
||||
@@ -2793,15 +2795,13 @@ struct wined3d_cs *wined3d_cs_create(struct wined3d_device *device)
|
||||
return NULL;
|
||||
cs->tls_idx = TLS_OUT_OF_INDEXES;
|
||||
|
||||
@@ -272,7 +272,7 @@ index 71119320f56..01c81cde95e 100644
|
||||
cs->ops = &wined3d_cs_st_ops;
|
||||
cs->device = device;
|
||||
|
||||
@@ -2840,7 +2840,6 @@ struct wined3d_cs *wined3d_cs_create(struct wined3d_device *device)
|
||||
@@ -2834,7 +2834,6 @@ struct wined3d_cs *wined3d_cs_create(struct wined3d_device *device)
|
||||
err:
|
||||
state_cleanup(&cs->state);
|
||||
if (cs->tls_idx != TLS_OUT_OF_INDEXES) TlsFree(cs->tls_idx);
|
||||
@@ -280,7 +280,7 @@ index 71119320f56..01c81cde95e 100644
|
||||
HeapFree(GetProcessHeap(), 0, cs->data);
|
||||
HeapFree(GetProcessHeap(), 0, cs);
|
||||
return NULL;
|
||||
@@ -2869,7 +2868,6 @@ void wined3d_cs_destroy(struct wined3d_cs *cs)
|
||||
@@ -2863,7 +2862,6 @@ void wined3d_cs_destroy(struct wined3d_cs *cs)
|
||||
}
|
||||
|
||||
TlsFree(cs->tls_idx);
|
||||
@@ -289,7 +289,7 @@ index 71119320f56..01c81cde95e 100644
|
||||
HeapFree(GetProcessHeap(), 0, cs);
|
||||
}
|
||||
diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
|
||||
index 04736737ddd..e840ff67cdb 100644
|
||||
index 4ae48f5de17..7c6b5052ecf 100644
|
||||
--- a/dlls/wined3d/device.c
|
||||
+++ b/dlls/wined3d/device.c
|
||||
@@ -955,7 +955,7 @@ static void device_init_swapchain_state(struct wined3d_device *device, struct wi
|
||||
@@ -389,7 +389,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
return;
|
||||
if (src_view->resource->type == WINED3D_RTYPE_BUFFER)
|
||||
{
|
||||
@@ -3523,6 +3498,8 @@ HRESULT CDECL wined3d_device_end_scene(struct wined3d_device *device)
|
||||
@@ -3447,6 +3422,8 @@ HRESULT CDECL wined3d_device_end_scene(struct wined3d_device *device)
|
||||
HRESULT CDECL wined3d_device_clear(struct wined3d_device *device, DWORD rect_count,
|
||||
const RECT *rects, DWORD flags, const struct wined3d_color *color, float depth, DWORD stencil)
|
||||
{
|
||||
@@ -398,7 +398,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
TRACE("device %p, rect_count %u, rects %p, flags %#x, color %s, depth %.8e, stencil %u.\n",
|
||||
device, rect_count, rects, flags, debug_color(color), depth, stencil);
|
||||
|
||||
@@ -3534,7 +3511,7 @@ HRESULT CDECL wined3d_device_clear(struct wined3d_device *device, DWORD rect_cou
|
||||
@@ -3458,7 +3435,7 @@ HRESULT CDECL wined3d_device_clear(struct wined3d_device *device, DWORD rect_cou
|
||||
|
||||
if (flags & (WINED3DCLEAR_ZBUFFER | WINED3DCLEAR_STENCIL))
|
||||
{
|
||||
@@ -407,7 +407,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
if (!ds)
|
||||
{
|
||||
WARN("Clearing depth and/or stencil without a depth stencil buffer attached, returning WINED3DERR_INVALIDCALL\n");
|
||||
@@ -3543,8 +3520,8 @@ HRESULT CDECL wined3d_device_clear(struct wined3d_device *device, DWORD rect_cou
|
||||
@@ -3467,8 +3444,8 @@ HRESULT CDECL wined3d_device_clear(struct wined3d_device *device, DWORD rect_cou
|
||||
}
|
||||
else if (flags & WINED3DCLEAR_TARGET)
|
||||
{
|
||||
@@ -418,7 +418,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
{
|
||||
WARN("Silently ignoring depth and target clear with mismatching sizes\n");
|
||||
return WINED3D_OK;
|
||||
@@ -3894,8 +3871,8 @@ HRESULT CDECL wined3d_device_validate_device(const struct wined3d_device *device
|
||||
@@ -3818,8 +3795,8 @@ HRESULT CDECL wined3d_device_validate_device(const struct wined3d_device *device
|
||||
if (state->render_states[WINED3D_RS_ZENABLE] || state->render_states[WINED3D_RS_ZWRITEENABLE]
|
||||
|| state->render_states[WINED3D_RS_STENCILENABLE])
|
||||
{
|
||||
@@ -429,7 +429,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
|
||||
if (ds && rt && (ds->width < rt->width || ds->height < rt->height))
|
||||
{
|
||||
@@ -4330,20 +4307,21 @@ struct wined3d_rendertarget_view * CDECL wined3d_device_get_rendertarget_view(co
|
||||
@@ -4254,20 +4231,21 @@ struct wined3d_rendertarget_view * CDECL wined3d_device_get_rendertarget_view(co
|
||||
return NULL;
|
||||
}
|
||||
|
||||
@@ -453,7 +453,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
|
||||
TRACE("device %p, view_idx %u, view %p, set_viewport %#x.\n",
|
||||
device, view_idx, view, set_viewport);
|
||||
@@ -4380,13 +4358,13 @@ HRESULT CDECL wined3d_device_set_rendertarget_view(struct wined3d_device *device
|
||||
@@ -4304,13 +4282,13 @@ HRESULT CDECL wined3d_device_set_rendertarget_view(struct wined3d_device *device
|
||||
}
|
||||
|
||||
|
||||
@@ -469,7 +469,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
wined3d_cs_emit_set_rendertarget_view(device->cs, view_idx, view);
|
||||
/* Release after the assignment, to prevent device_resource_released()
|
||||
* from seeing the surface as still in use. */
|
||||
@@ -4398,18 +4376,19 @@ HRESULT CDECL wined3d_device_set_rendertarget_view(struct wined3d_device *device
|
||||
@@ -4322,18 +4300,19 @@ HRESULT CDECL wined3d_device_set_rendertarget_view(struct wined3d_device *device
|
||||
|
||||
void CDECL wined3d_device_set_depth_stencil_view(struct wined3d_device *device, struct wined3d_rendertarget_view *view)
|
||||
{
|
||||
@@ -491,7 +491,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
wined3d_rendertarget_view_incref(view);
|
||||
wined3d_cs_emit_set_depth_stencil_view(device->cs, view);
|
||||
if (prev)
|
||||
@@ -4756,10 +4735,9 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
|
||||
@@ -4680,10 +4659,9 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
|
||||
wined3d_texture_decref(device->cursor_texture);
|
||||
device->cursor_texture = NULL;
|
||||
}
|
||||
@@ -503,7 +503,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
{
|
||||
for (i = 0; i < device->adapter->gl_info.limits.buffers; ++i)
|
||||
{
|
||||
@@ -4770,6 +4748,11 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
|
||||
@@ -4694,6 +4672,11 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
|
||||
|
||||
if (reset_state)
|
||||
{
|
||||
@@ -515,7 +515,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
LIST_FOR_EACH_ENTRY_SAFE(resource, cursor, &device->resources, struct wined3d_resource, resource_list_entry)
|
||||
{
|
||||
TRACE("Enumerating resource %p.\n", resource);
|
||||
@@ -4934,27 +4917,28 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
|
||||
@@ -4858,27 +4841,28 @@ HRESULT CDECL wined3d_device_reset(struct wined3d_device *device,
|
||||
if (device->d3d_initialized)
|
||||
delete_opengl_contexts(device, swapchain);
|
||||
|
||||
@@ -551,7 +551,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
wined3d_cs_emit_set_scissor_rect(device->cs, &state->scissor_rect);
|
||||
}
|
||||
|
||||
@@ -5046,11 +5030,11 @@ void device_resource_released(struct wined3d_device *device, struct wined3d_reso
|
||||
@@ -4970,11 +4954,11 @@ void device_resource_released(struct wined3d_device *device, struct wined3d_reso
|
||||
{
|
||||
for (i = 0; i < device->adapter->gl_info.limits.buffers; ++i)
|
||||
{
|
||||
@@ -565,7 +565,7 @@ index 04736737ddd..e840ff67cdb 100644
|
||||
ERR("Resource %p is still in use as depth/stencil buffer.\n", resource);
|
||||
}
|
||||
|
||||
@@ -5176,8 +5160,12 @@ HRESULT device_init(struct wined3d_device *device, struct wined3d *wined3d,
|
||||
@@ -5100,8 +5084,12 @@ HRESULT device_init(struct wined3d_device *device, struct wined3d *wined3d,
|
||||
|
||||
device->blitter = adapter->blitter;
|
||||
|
||||
@@ -594,7 +594,7 @@ index 49804131efb..28b4c5a48da 100644
|
||||
struct wined3d_event_query *ib_query = NULL;
|
||||
struct wined3d_rendertarget_view *dsv, *rtv;
|
||||
diff --git a/dlls/wined3d/glsl_shader.c b/dlls/wined3d/glsl_shader.c
|
||||
index ce935a05716..5e8390ae376 100644
|
||||
index bc041179b55..985261b6a73 100644
|
||||
--- a/dlls/wined3d/glsl_shader.c
|
||||
+++ b/dlls/wined3d/glsl_shader.c
|
||||
@@ -1612,7 +1612,7 @@ static void shader_glsl_load_constants(void *shader_priv, struct wined3d_context
|
||||
@@ -607,10 +607,10 @@ index ce935a05716..5e8390ae376 100644
|
||||
0.0f,
|
||||
0.0f,
|
||||
diff --git a/dlls/wined3d/shader.c b/dlls/wined3d/shader.c
|
||||
index 00ed4527f6d..96615cd4222 100644
|
||||
index 490c985acf1..b84e43d6294 100644
|
||||
--- a/dlls/wined3d/shader.c
|
||||
+++ b/dlls/wined3d/shader.c
|
||||
@@ -3218,7 +3218,7 @@ void find_ps_compile_args(const struct wined3d_state *state, const struct wined3
|
||||
@@ -3219,7 +3219,7 @@ void find_ps_compile_args(const struct wined3d_state *state, const struct wined3
|
||||
UINT i;
|
||||
|
||||
memset(args, 0, sizeof(*args)); /* FIXME: Make sure all bits are set. */
|
||||
@@ -620,7 +620,7 @@ index 00ed4527f6d..96615cd4222 100644
|
||||
static unsigned int warned = 0;
|
||||
|
||||
diff --git a/dlls/wined3d/state.c b/dlls/wined3d/state.c
|
||||
index f91c9ffb32b..c0bc5042a16 100644
|
||||
index 2e556c798fd..66e4eb4fd89 100644
|
||||
--- a/dlls/wined3d/state.c
|
||||
+++ b/dlls/wined3d/state.c
|
||||
@@ -152,7 +152,7 @@ static void state_zenable(struct wined3d_context *context, const struct wined3d_
|
||||
@@ -683,7 +683,7 @@ index f91c9ffb32b..c0bc5042a16 100644
|
||||
float scale;
|
||||
|
||||
union
|
||||
@@ -4632,8 +4632,8 @@ static void vertexdeclaration(struct wined3d_context *context, const struct wine
|
||||
@@ -4637,8 +4637,8 @@ static void vertexdeclaration(struct wined3d_context *context, const struct wine
|
||||
|
||||
static void viewport_miscpart(struct wined3d_context *context, const struct wined3d_state *state, DWORD state_id)
|
||||
{
|
||||
@@ -694,7 +694,7 @@ index f91c9ffb32b..c0bc5042a16 100644
|
||||
const struct wined3d_gl_info *gl_info = context->gl_info;
|
||||
struct wined3d_viewport vp = state->viewport;
|
||||
unsigned int width, height;
|
||||
@@ -4672,8 +4672,8 @@ static void viewport_miscpart(struct wined3d_context *context, const struct wine
|
||||
@@ -4677,8 +4677,8 @@ static void viewport_miscpart(struct wined3d_context *context, const struct wine
|
||||
static void viewport_miscpart_cc(struct wined3d_context *context,
|
||||
const struct wined3d_state *state, DWORD state_id)
|
||||
{
|
||||
@@ -705,7 +705,7 @@ index f91c9ffb32b..c0bc5042a16 100644
|
||||
float pixel_center_offset = context->d3d_info->wined3d_creation_flags
|
||||
& WINED3D_PIXEL_CENTER_INTEGER ? 0.5f : 0.0f;
|
||||
const struct wined3d_gl_info *gl_info = context->gl_info;
|
||||
@@ -4868,7 +4868,7 @@ static void scissorrect(struct wined3d_context *context, const struct wined3d_st
|
||||
@@ -4873,7 +4873,7 @@ static void scissorrect(struct wined3d_context *context, const struct wined3d_st
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -714,7 +714,7 @@ index f91c9ffb32b..c0bc5042a16 100644
|
||||
UINT height;
|
||||
UINT width;
|
||||
|
||||
@@ -4944,7 +4944,7 @@ void state_srgbwrite(struct wined3d_context *context, const struct wined3d_state
|
||||
@@ -4949,7 +4949,7 @@ void state_srgbwrite(struct wined3d_context *context, const struct wined3d_state
|
||||
|
||||
TRACE("context %p, state %p, state_id %#x.\n", context, state, state_id);
|
||||
|
||||
@@ -824,10 +824,10 @@ index ed39a15c7be..913d630cf97 100644
|
||||
if (type == WINED3D_SBT_RECORDED)
|
||||
return WINED3D_OK;
|
||||
diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c
|
||||
index 05fb8357126..5ad5e003c20 100644
|
||||
index e65630fafc8..c5ad5bd8475 100644
|
||||
--- a/dlls/wined3d/surface.c
|
||||
+++ b/dlls/wined3d/surface.c
|
||||
@@ -2513,7 +2513,7 @@ static HRESULT surface_blt_special(struct wined3d_surface *dst_surface, const RE
|
||||
@@ -2514,7 +2514,7 @@ static HRESULT surface_blt_special(struct wined3d_surface *dst_surface, const RE
|
||||
{
|
||||
struct wined3d_texture *dst_texture = dst_surface->container;
|
||||
struct wined3d_device *device = dst_texture->resource.device;
|
||||
@@ -837,7 +837,7 @@ index 05fb8357126..5ad5e003c20 100644
|
||||
struct wined3d_texture *src_texture;
|
||||
|
||||
diff --git a/dlls/wined3d/utils.c b/dlls/wined3d/utils.c
|
||||
index 5c928041ead..11270802fa5 100644
|
||||
index d1c5ef51fd5..cffe9f43b42 100644
|
||||
--- a/dlls/wined3d/utils.c
|
||||
+++ b/dlls/wined3d/utils.c
|
||||
@@ -4645,7 +4645,7 @@ void get_projection_matrix(const struct wined3d_context *context, const struct w
|
||||
@@ -859,10 +859,10 @@ index 5c928041ead..11270802fa5 100644
|
||||
|| !state->render_states[WINED3D_RS_CLIPPLANEENABLE])
|
||||
{
|
||||
diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h
|
||||
index 1f0fbf23b18..5991eb95787 100644
|
||||
index f0777c9bd34..811fb28e2c9 100644
|
||||
--- a/dlls/wined3d/wined3d_private.h
|
||||
+++ b/dlls/wined3d/wined3d_private.h
|
||||
@@ -1516,6 +1516,36 @@ struct wined3d_timestamp_query
|
||||
@@ -1540,6 +1540,36 @@ struct wined3d_timestamp_query
|
||||
void context_alloc_timestamp_query(struct wined3d_context *context, struct wined3d_timestamp_query *query) DECLSPEC_HIDDEN;
|
||||
void context_free_timestamp_query(struct wined3d_timestamp_query *query) DECLSPEC_HIDDEN;
|
||||
|
||||
@@ -899,15 +899,15 @@ index 1f0fbf23b18..5991eb95787 100644
|
||||
struct wined3d_context
|
||||
{
|
||||
const struct wined3d_gl_info *gl_info;
|
||||
@@ -1530,6 +1560,7 @@ struct wined3d_context
|
||||
DWORD dirtyArray[STATE_HIGHEST + 1]; /* Won't get bigger than that, a state is never marked dirty 2 times */
|
||||
@@ -1555,6 +1585,7 @@ struct wined3d_context
|
||||
DWORD numDirtyEntries;
|
||||
DWORD isStateDirty[STATE_HIGHEST / (sizeof(DWORD) * CHAR_BIT) + 1]; /* Bitmap to find out quickly if a state is dirty */
|
||||
unsigned int dirty_compute_states[STATE_COMPUTE_COUNT / (sizeof(unsigned int) * CHAR_BIT) + 1];
|
||||
+ struct wined3d_fb_state current_fb;
|
||||
|
||||
struct wined3d_device *device;
|
||||
struct wined3d_swapchain *swapchain;
|
||||
@@ -1642,12 +1673,6 @@ struct wined3d_context
|
||||
@@ -1667,12 +1698,6 @@ struct wined3d_context
|
||||
GLuint dummy_arbfp_prog;
|
||||
};
|
||||
|
||||
@@ -920,7 +920,7 @@ index 1f0fbf23b18..5991eb95787 100644
|
||||
typedef void (*APPLYSTATEFUNC)(struct wined3d_context *ctx, const struct wined3d_state *state, DWORD state_id);
|
||||
|
||||
struct StateEntry
|
||||
@@ -2469,7 +2494,7 @@ struct wined3d_stream_state
|
||||
@@ -2494,7 +2519,7 @@ struct wined3d_stream_state
|
||||
struct wined3d_state
|
||||
{
|
||||
DWORD flags;
|
||||
@@ -929,7 +929,7 @@ index 1f0fbf23b18..5991eb95787 100644
|
||||
|
||||
struct wined3d_vertex_declaration *vertex_declaration;
|
||||
struct wined3d_stream_output stream_output[MAX_STREAM_OUT];
|
||||
@@ -2583,7 +2608,6 @@ struct wined3d_device
|
||||
@@ -2608,7 +2633,6 @@ struct wined3d_device
|
||||
struct wine_rb_tree samplers;
|
||||
|
||||
/* Render Target Support */
|
||||
@@ -937,7 +937,7 @@ index 1f0fbf23b18..5991eb95787 100644
|
||||
struct wined3d_rendertarget_view *auto_depth_stencil_view;
|
||||
|
||||
/* For rendering to a texture using glCopyTexImage */
|
||||
@@ -3125,9 +3149,8 @@ struct wined3d_stateblock
|
||||
@@ -3150,9 +3174,8 @@ struct wined3d_stateblock
|
||||
void stateblock_init_contained_states(struct wined3d_stateblock *stateblock) DECLSPEC_HIDDEN;
|
||||
|
||||
void state_cleanup(struct wined3d_state *state) DECLSPEC_HIDDEN;
|
||||
@@ -949,7 +949,7 @@ index 1f0fbf23b18..5991eb95787 100644
|
||||
void state_unbind_resources(struct wined3d_state *state) DECLSPEC_HIDDEN;
|
||||
|
||||
enum wined3d_push_constants
|
||||
@@ -3163,7 +3186,6 @@ struct wined3d_cs
|
||||
@@ -3188,7 +3211,6 @@ struct wined3d_cs
|
||||
{
|
||||
const struct wined3d_cs_ops *ops;
|
||||
struct wined3d_device *device;
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user