diff --git a/dll/directx/wine/ddraw/ddraw.c b/dll/directx/wine/ddraw/ddraw.c index 9a6d527cd0c43..38848f207a563 100644 --- a/dll/directx/wine/ddraw/ddraw.c +++ b/dll/directx/wine/ddraw/ddraw.c @@ -1149,6 +1149,7 @@ static HRESULT WINAPI ddraw7_SetDisplayMode(IDirectDraw7 *iface, DWORD width, DW /* TODO: The possible return values from msdn suggest that the screen mode * can't be changed if a surface is locked or some drawing is in progress. */ + if (SUCCEEDED(hr = wined3d_set_adapter_display_mode(ddraw->wined3d, WINED3DADAPTER_DEFAULT, &mode))) { if (ddraw->primary) @@ -1162,6 +1163,10 @@ static HRESULT WINAPI ddraw7_SetDisplayMode(IDirectDraw7 *iface, DWORD width, DW ddrawformat_from_wined3dformat(&ddraw->primary->surface_desc.u4.ddpfPixelFormat, mode.format_id); } ddraw->flags |= DDRAW_RESTORE_MODE; + + if (ddraw->cooperative_level & DDSCL_EXCLUSIVE) + SetWindowPos(ddraw->dest_window, HWND_TOP, 0, 0, width, height, SWP_SHOWWINDOW | SWP_NOACTIVATE); + TRACE("DirectDraw window has been resized\n"); } InterlockedCompareExchange(&ddraw->device_state, DDRAW_DEVICE_STATE_NOT_RESTORED, DDRAW_DEVICE_STATE_OK); diff --git a/dll/directx/wine/wined3d/context.c b/dll/directx/wine/wined3d/context.c index 525711e353bdd..a93ff7bcfb4f2 100644 --- a/dll/directx/wine/wined3d/context.c +++ b/dll/directx/wine/wined3d/context.c @@ -5657,11 +5657,18 @@ void wined3d_context_gl_draw_shaded_quad(struct wined3d_context_gl *context_gl, wined3d_context_gl_unload_vertex_data(context_gl); wined3d_context_gl_unload_numbered_arrays(context_gl); +#ifdef __REACTOS__ GL_EXTCALL(glBufferData(GL_ARRAY_BUFFER, sizeof(quad), quad, GL_STREAM_DRAW)); GL_EXTCALL(glVertexAttribPointer(0, 2, GL_FLOAT, FALSE, sizeof(*quad), NULL)); GL_EXTCALL(glVertexAttribPointer(1, 3, GL_FLOAT, FALSE, sizeof(*quad), - (void *)FIELD_OFFSET(struct blit_vertex, texcoord))); + (void *)(ULONG_PTR)FIELD_OFFSET(struct blit_vertex, texcoord))); +#else + GL_EXTCALL(glBufferData(GL_ARRAY_BUFFER, sizeof(quad), quad, GL_STREAM_DRAW)); + GL_EXTCALL(glVertexAttribPointer(0, 2, GL_FLOAT, FALSE, sizeof(*quad), NULL)); + GL_EXTCALL(glVertexAttribPointer(1, 3, GL_FLOAT, FALSE, sizeof(*quad), + (void *)FIELD_OFFSET(struct blit_vertex, texcoord))); +#endif GL_EXTCALL(glEnableVertexAttribArray(0)); GL_EXTCALL(glEnableVertexAttribArray(1)); diff --git a/dll/directx/wine/wined3d/glsl_shader.c b/dll/directx/wine/wined3d/glsl_shader.c index 4131a207ea07b..7785ea9d50ff8 100644 --- a/dll/directx/wine/wined3d/glsl_shader.c +++ b/dll/directx/wine/wined3d/glsl_shader.c @@ -1370,7 +1370,7 @@ static void shader_glsl_load_np2fixup_constants(const struct glsl_ps_program *ps GL_EXTCALL(glUniform4fv(ps->np2_fixup_location, ps->np2_fixup_info->num_consts, &np2fixup_constants[0].sx)); } -static void transpose_matrix(struct wined3d_matrix *out, const struct wined3d_matrix *m) +void transpose_matrix(struct wined3d_matrix *out, const struct wined3d_matrix *m) { struct wined3d_matrix temp; unsigned int i, j; diff --git a/dll/directx/wine/wined3d/query.c b/dll/directx/wine/wined3d/query.c index 20641de82fc25..e6d3b34ebdb09 100644 --- a/dll/directx/wine/wined3d/query.c +++ b/dll/directx/wine/wined3d/query.c @@ -1360,6 +1360,8 @@ static const struct wined3d_query_ops statistics_query_ops = wined3d_statistics_query_ops_destroy, }; +#ifdef __REACTOS__ +#else static HRESULT wined3d_statistics_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query) @@ -1380,6 +1382,7 @@ static HRESULT wined3d_statistics_query_create(struct wined3d_device *device, return WINED3D_OK; } +#endif static void wined3d_overflow_query_ops_destroy(struct wined3d_query *query) { diff --git a/dll/directx/wine/wined3d/shader_sm4.c b/dll/directx/wine/wined3d/shader_sm4.c index 800414161f1b1..5e59b2ae3246f 100644 --- a/dll/directx/wine/wined3d/shader_sm4.c +++ b/dll/directx/wine/wined3d/shader_sm4.c @@ -1894,7 +1894,7 @@ static HRESULT parse_dxbc(const char *data, SIZE_T data_size, return hr; } -static const char *shader_get_string(const char *data, size_t data_size, DWORD offset) +const char *shader_get_string(const char *data, size_t data_size, DWORD offset) { size_t len, max_len; @@ -1908,7 +1908,7 @@ static const char *shader_get_string(const char *data, size_t data_size, DWORD o #ifdef __REACTOS__ len = strlen(data + offset); -#else` +#else len = strnlen(data + offset, max_len); #endif diff --git a/dll/directx/wine/wined3d/state.c b/dll/directx/wine/wined3d/state.c index 55965a58f7203..8c9be567e1c86 100644 --- a/dll/directx/wine/wined3d/state.c +++ b/dll/directx/wine/wined3d/state.c @@ -1594,6 +1594,8 @@ static void state_colorwrite_i(struct wined3d_context *context, const struct win set_color_mask(gl_info, index, state->render_states[state_id]); } +#ifdef __REACTOS__ +#else static void state_colorwrite1(struct wined3d_context *context, const struct wined3d_state *state, DWORD state_id) { set_color_mask(wined3d_context_gl(context)->gl_info, 1, state->render_states[WINED3D_RS_COLORWRITEENABLE1]); @@ -1608,6 +1610,7 @@ static void state_colorwrite3(struct wined3d_context *context, const struct wine { set_color_mask(wined3d_context_gl(context)->gl_info, 3, state->render_states[WINED3D_RS_COLORWRITEENABLE3]); } +#endif static void state_localviewer(struct wined3d_context *context, const struct wined3d_state *state, DWORD state_id) { diff --git a/dll/directx/wine/wined3d/surface.c b/dll/directx/wine/wined3d/surface.c index 3ccd3318a3d0f..fc372a0e88221 100644 --- a/dll/directx/wine/wined3d/surface.c +++ b/dll/directx/wine/wined3d/surface.c @@ -681,7 +681,8 @@ static void convert_x8r8g8b8_dxt5(const BYTE *src, BYTE *dst, { wined3d_dxt5_encode(src, dst, pitch_in, pitch_out, WINED3DFMT_B8G8R8X8_UNORM, w, h); } - +#ifdef __REACTOS__ +#else static void convert_x8r8g8b8_l8(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h) { @@ -700,6 +701,7 @@ static void convert_x8r8g8b8_l8(const BYTE *src, BYTE *dst, } } } +#endif struct d3dfmt_converter_desc { diff --git a/dll/directx/wine/wined3d/swapchain.c b/dll/directx/wine/wined3d/swapchain.c index 4eb5d290a8247..4d598780fe926 100644 --- a/dll/directx/wine/wined3d/swapchain.c +++ b/dll/directx/wine/wined3d/swapchain.c @@ -177,7 +177,10 @@ HRESULT CDECL wined3d_swapchain_present(struct wined3d_swapchain *swapchain, const RECT *src_rect, const RECT *dst_rect, HWND dst_window_override, unsigned int swap_interval, DWORD flags) { +#ifdef __REACTOS__ +#else static DWORD notified_flags = 0; +#endif RECT s, d; TRACE("swapchain %p, src_rect %s, dst_rect %s, dst_window_override %p, swap_interval %u, flags %#x.\n", diff --git a/dll/directx/wine/wined3d/utils.c b/dll/directx/wine/wined3d/utils.c index 5b7408dc74282..dc0823197cec6 100644 --- a/dll/directx/wine/wined3d/utils.c +++ b/dll/directx/wine/wined3d/utils.c @@ -6962,7 +6962,7 @@ BOOL invert_matrix(struct wined3d_matrix *out, const struct wined3d_matrix *m) } /* Taken and adapted from Mesa. */ -static BOOL invert_matrix_3d(struct wined3d_matrix *out, const struct wined3d_matrix *in) +BOOL invert_matrix_3d(struct wined3d_matrix *out, const struct wined3d_matrix *in) { float pos, neg, t, det; struct wined3d_matrix temp; diff --git a/sdk/include/psdk/winuser.h b/sdk/include/psdk/winuser.h index c3978697e3f51..c51983c70d146 100644 --- a/sdk/include/psdk/winuser.h +++ b/sdk/include/psdk/winuser.h @@ -2112,6 +2112,8 @@ extern "C" { #define DCX_INTERSECTRGN 128 #define DCX_VALIDATE 0x200000 #define DCX_EXCLUDEUPDATE 0x100 +#define DCX_USESTYLE 0x00010000 +#define DCX_NORECOMPUTE 0x00100000 #define GMDI_GOINTOPOPUPS 2 #define GMDI_USEDISABLED 1 #define FKF_AVAILABLE 2