[PATCH 1/5] wined3d: Get rid of some leftover references to IWineD3D.

Henri Verbeet hverbeet at codeweavers.com
Tue Sep 3 02:47:21 CDT 2013


---
 dlls/wined3d/surface.c         | 10 +++++-----
 dlls/wined3d/wined3d_private.h | 12 ++++--------
 2 files changed, 9 insertions(+), 13 deletions(-)

diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c
index 2bf5521..e36f61d 100644
--- a/dlls/wined3d/surface.c
+++ b/dlls/wined3d/surface.c
@@ -4163,7 +4163,7 @@ void d3dfmt_p8_init_palette(const struct wined3d_surface *surface, BYTE table[25
 
             /* When index_in_alpha is set the palette index is stored in the
              * alpha component. In case of a readback we can then read
-             * GL_ALPHA. Color keying is handled in BltOverride using a
+             * GL_ALPHA. Color keying is handled in surface_blt_special() using a
              * GL_ALPHA_TEST using GL_NOT_EQUAL. In case of index_in_alpha the
              * color key itself is passed to glAlphaFunc in other cases the
              * alpha component of pixels that should be masked away is set to 0. */
@@ -4916,7 +4916,7 @@ HRESULT surface_color_fill(struct wined3d_surface *s, const RECT *rect, const st
     return blitter->color_fill(device, s, rect, color);
 }
 
-static HRESULT IWineD3DSurfaceImpl_BltOverride(struct wined3d_surface *dst_surface, const RECT *dst_rect,
+static HRESULT surface_blt_special(struct wined3d_surface *dst_surface, const RECT *dst_rect,
         struct wined3d_surface *src_surface, const RECT *src_rect, DWORD flags, const WINEDDBLTFX *DDBltFx,
         enum wined3d_texture_filter_type filter)
 {
@@ -6864,7 +6864,7 @@ fallback:
     if ((dst_surface->resource.usage & WINED3DUSAGE_RENDERTARGET)
             || (src_surface && (src_surface->resource.usage & WINED3DUSAGE_RENDERTARGET)))
     {
-        if (SUCCEEDED(IWineD3DSurfaceImpl_BltOverride(dst_surface, &dst_rect,
+        if (SUCCEEDED(surface_blt_special(dst_surface, &dst_rect,
                 src_surface, &src_rect, flags, fx, filter)))
             return WINED3D_OK;
     }
@@ -6872,8 +6872,8 @@ fallback:
 cpu:
 
     /* For the rest call the X11 surface implementation. For render targets
-     * this should be implemented OpenGL accelerated in BltOverride, other
-     * blits are rather rare. */
+     * this should be implemented OpenGL accelerated in surface_blt_special(),
+     * other blits are rather rare. */
     return surface_cpu_blt(dst_surface, &dst_rect, src_surface, &src_rect, flags, fx, filter);
 }
 
diff --git a/dlls/wined3d/wined3d_private.h b/dlls/wined3d/wined3d_private.h
index 688671d..1a341b7 100644
--- a/dlls/wined3d/wined3d_private.h
+++ b/dlls/wined3d/wined3d_private.h
@@ -1836,12 +1836,10 @@ struct wined3d_state
     DWORD render_states[WINEHIGHEST_RENDER_STATE + 1];
 };
 
-/*****************************************************************************
- * IWineD3DDevice implementation structure
- */
 #define WINED3D_UNMAPPED_STAGE ~0U
 
-/* Multithreaded flag. Removed from the public header to signal that IWineD3D::CreateDevice ignores it */
+/* Multithreaded flag. Removed from the public header to signal that
+ * wined3d_device_create() ignores it. */
 #define WINED3DCREATE_MULTITHREADED 0x00000004
 
 struct wined3d_device
@@ -2969,10 +2967,8 @@ DWORD wined3d_format_convert_from_float(const struct wined3d_surface *surface,
 
 static inline BOOL use_vs(const struct wined3d_state *state)
 {
-    /* Check stateblock->vertexDecl to allow this to be used from
-     * IWineD3DDeviceImpl_FindTexUnitMap(). This is safe because
-     * stateblock->vertexShader implies a vertex declaration instead of ddraw
-     * style strided data. */
+    /* Check state->vertex_declaration to allow this to be used before the
+     * stream info is validated, for example in device_update_tex_unit_map(). */
     return state->vertex_shader && !state->vertex_declaration->position_transformed;
 }
 
-- 
1.8.1.5




More information about the wine-patches mailing list