From: Nikolay Sivov nsivov@codeweavers.com
--- dlls/d2d1/d2d1_private.h | 4 +- dlls/d2d1/factory.c | 162 ++++++++++++++++++++++++--------------- 2 files changed, 104 insertions(+), 62 deletions(-)
diff --git a/dlls/d2d1/d2d1_private.h b/dlls/d2d1/d2d1_private.h index 705f2182edd..680ec1bd277 100644 --- a/dlls/d2d1/d2d1_private.h +++ b/dlls/d2d1/d2d1_private.h @@ -680,7 +680,7 @@ struct d2d_effect_registration
struct d2d_factory { - ID2D1Factory3 ID2D1Factory3_iface; + ID2D1Factory7 ID2D1Factory7_iface; ID2D1Multithread ID2D1Multithread_iface; LONG refcount;
@@ -698,7 +698,7 @@ struct d2d_factory
static inline struct d2d_factory *unsafe_impl_from_ID2D1Factory(ID2D1Factory *iface) { - return CONTAINING_RECORD(iface, struct d2d_factory, ID2D1Factory3_iface); + return CONTAINING_RECORD(iface, struct d2d_factory, ID2D1Factory7_iface); }
void d2d_effects_init_builtins(struct d2d_factory *factory); diff --git a/dlls/d2d1/factory.c b/dlls/d2d1/factory.c index e5350d7100f..1b12670bd1c 100644 --- a/dlls/d2d1/factory.c +++ b/dlls/d2d1/factory.c @@ -36,9 +36,9 @@ static void d2d_effect_registration_cleanup(struct d2d_effect_registration *reg) free(reg); }
-static inline struct d2d_factory *impl_from_ID2D1Factory3(ID2D1Factory3 *iface) +static inline struct d2d_factory *impl_from_ID2D1Factory7(ID2D1Factory7 *iface) { - return CONTAINING_RECORD(iface, struct d2d_factory, ID2D1Factory3_iface); + return CONTAINING_RECORD(iface, struct d2d_factory, ID2D1Factory7_iface); }
static inline struct d2d_factory *impl_from_ID2D1Multithread(ID2D1Multithread *iface) @@ -97,25 +97,29 @@ static HRESULT d2d_factory_reload_sysmetrics(struct d2d_factory *factory) return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_QueryInterface(ID2D1Factory3 *iface, REFIID iid, void **out) +static HRESULT STDMETHODCALLTYPE d2d_factory_QueryInterface(ID2D1Factory7 *iface, REFIID iid, void **out) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface);
TRACE("iface %p, iid %s, out %p.\n", iface, debugstr_guid(iid), out);
- if ((IsEqualGUID(iid, &IID_ID2D1Factory3) && d2d_settings.max_version_factory >= 3) + if ((IsEqualGUID(iid, &IID_ID2D1Factory7) && d2d_settings.max_version_factory >= 7) + || (IsEqualGUID(iid, &IID_ID2D1Factory6) && d2d_settings.max_version_factory >= 6) + || (IsEqualGUID(iid, &IID_ID2D1Factory5) && d2d_settings.max_version_factory >= 5) + || (IsEqualGUID(iid, &IID_ID2D1Factory4) && d2d_settings.max_version_factory >= 4) + || (IsEqualGUID(iid, &IID_ID2D1Factory3) && d2d_settings.max_version_factory >= 3) || (IsEqualGUID(iid, &IID_ID2D1Factory2) && d2d_settings.max_version_factory >= 2) || (IsEqualGUID(iid, &IID_ID2D1Factory1) && d2d_settings.max_version_factory >= 1) || IsEqualGUID(iid, &IID_ID2D1Factory) || IsEqualGUID(iid, &IID_IUnknown)) { - ID2D1Factory3_AddRef(iface); + ID2D1Factory7_AddRef(iface); *out = iface; return S_OK; } else if (IsEqualGUID(iid, &IID_ID2D1Multithread)) { - ID2D1Factory3_AddRef(iface); + ID2D1Factory7_AddRef(iface); *out = &factory->ID2D1Multithread_iface; return S_OK; } @@ -126,9 +130,9 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_QueryInterface(ID2D1Factory3 *iface return E_NOINTERFACE; }
-static ULONG STDMETHODCALLTYPE d2d_factory_AddRef(ID2D1Factory3 *iface) +static ULONG STDMETHODCALLTYPE d2d_factory_AddRef(ID2D1Factory7 *iface) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface); ULONG refcount = InterlockedIncrement(&factory->refcount);
TRACE("%p increasing refcount to %lu.\n", iface, refcount); @@ -136,9 +140,9 @@ static ULONG STDMETHODCALLTYPE d2d_factory_AddRef(ID2D1Factory3 *iface) return refcount; }
-static ULONG STDMETHODCALLTYPE d2d_factory_Release(ID2D1Factory3 *iface) +static ULONG STDMETHODCALLTYPE d2d_factory_Release(ID2D1Factory7 *iface) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface); ULONG refcount = InterlockedDecrement(&factory->refcount); struct d2d_effect_registration *reg, *reg2;
@@ -159,18 +163,18 @@ static ULONG STDMETHODCALLTYPE d2d_factory_Release(ID2D1Factory3 *iface) return refcount; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_ReloadSystemMetrics(ID2D1Factory3 *iface) +static HRESULT STDMETHODCALLTYPE d2d_factory_ReloadSystemMetrics(ID2D1Factory7 *iface) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface);
TRACE("iface %p.\n", iface);
return d2d_factory_reload_sysmetrics(factory); }
-static void STDMETHODCALLTYPE d2d_factory_GetDesktopDpi(ID2D1Factory3 *iface, float *dpi_x, float *dpi_y) +static void STDMETHODCALLTYPE d2d_factory_GetDesktopDpi(ID2D1Factory7 *iface, float *dpi_x, float *dpi_y) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface);
TRACE("iface %p, dpi_x %p, dpi_y %p.\n", iface, dpi_x, dpi_y);
@@ -178,7 +182,7 @@ static void STDMETHODCALLTYPE d2d_factory_GetDesktopDpi(ID2D1Factory3 *iface, fl *dpi_y = factory->dpi_y; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateRectangleGeometry(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateRectangleGeometry(ID2D1Factory7 *iface, const D2D1_RECT_F *rect, ID2D1RectangleGeometry **geometry) { struct d2d_geometry *object; @@ -202,7 +206,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateRectangleGeometry(ID2D1Factor return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateRoundedRectangleGeometry(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateRoundedRectangleGeometry(ID2D1Factory7 *iface, const D2D1_ROUNDED_RECT *rounded_rect, ID2D1RoundedRectangleGeometry **geometry) { struct d2d_geometry *object; @@ -226,7 +230,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateRoundedRectangleGeometry(ID2D return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateEllipseGeometry(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateEllipseGeometry(ID2D1Factory7 *iface, const D2D1_ELLIPSE *ellipse, ID2D1EllipseGeometry **geometry) { struct d2d_geometry *object; @@ -250,7 +254,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateEllipseGeometry(ID2D1Factory3 return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateGeometryGroup(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateGeometryGroup(ID2D1Factory7 *iface, D2D1_FILL_MODE fill_mode, ID2D1Geometry **geometries, UINT32 geometry_count, ID2D1GeometryGroup **group) { struct d2d_geometry *object; @@ -275,7 +279,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateGeometryGroup(ID2D1Factory3 * return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateTransformedGeometry(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateTransformedGeometry(ID2D1Factory7 *iface, ID2D1Geometry *src_geometry, const D2D1_MATRIX_3X2_F *transform, ID2D1TransformedGeometry **transformed_geometry) { @@ -295,7 +299,8 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateTransformedGeometry(ID2D1Fact return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreatePathGeometry(ID2D1Factory3 *iface, ID2D1PathGeometry **geometry) +static HRESULT STDMETHODCALLTYPE d2d_factory_CreatePathGeometry(ID2D1Factory7 *iface, + ID2D1PathGeometry **geometry) { struct d2d_geometry *object;
@@ -312,7 +317,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreatePathGeometry(ID2D1Factory3 *i return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateStrokeStyle(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateStrokeStyle(ID2D1Factory7 *iface, const D2D1_STROKE_STYLE_PROPERTIES *desc, const float *dashes, UINT32 dash_count, ID2D1StrokeStyle **stroke_style) { @@ -348,7 +353,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateStrokeStyle(ID2D1Factory3 *if return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDrawingStateBlock(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDrawingStateBlock(ID2D1Factory7 *iface, const D2D1_DRAWING_STATE_DESCRIPTION *desc, IDWriteRenderingParams *text_rendering_params, ID2D1DrawingStateBlock **state_block) { @@ -388,10 +393,10 @@ static HRESULT d2d_factory_get_device(struct d2d_factory *factory, ID3D10Device1 return hr; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateWicBitmapRenderTarget(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateWicBitmapRenderTarget(ID2D1Factory7 *iface, IWICBitmap *target, const D2D1_RENDER_TARGET_PROPERTIES *desc, ID2D1RenderTarget **render_target) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface); struct d2d_wic_render_target *object; ID3D10Device1 *device; HRESULT hr; @@ -420,11 +425,11 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateWicBitmapRenderTarget(ID2D1Fa return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateHwndRenderTarget(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateHwndRenderTarget(ID2D1Factory7 *iface, const D2D1_RENDER_TARGET_PROPERTIES *desc, const D2D1_HWND_RENDER_TARGET_PROPERTIES *hwnd_rt_desc, ID2D1HwndRenderTarget **render_target) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface); struct d2d_hwnd_render_target *object; ID3D10Device1 *device; HRESULT hr; @@ -450,7 +455,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateHwndRenderTarget(ID2D1Factory return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDxgiSurfaceRenderTarget(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDxgiSurfaceRenderTarget(ID2D1Factory7 *iface, IDXGISurface *surface, const D2D1_RENDER_TARGET_PROPERTIES *desc, ID2D1RenderTarget **render_target) { IDXGIDevice *dxgi_device; @@ -479,10 +484,10 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDxgiSurfaceRenderTarget(ID2D1 return hr; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDCRenderTarget(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDCRenderTarget(ID2D1Factory7 *iface, const D2D1_RENDER_TARGET_PROPERTIES *desc, ID2D1DCRenderTarget **render_target) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface); struct d2d_dc_render_target *object; ID3D10Device1 *device; HRESULT hr; @@ -508,14 +513,14 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDCRenderTarget(ID2D1Factory3 return S_OK; }
-static HRESULT d2d_factory_create_device(ID2D1Factory3 *iface, IDXGIDevice *dxgi_device, +static HRESULT d2d_factory_create_device(ID2D1Factory1 *iface, IDXGIDevice *dxgi_device, ID2D1Device1 **device) { struct d2d_device *object;
if (!(object = calloc(1, sizeof(*object)))) return E_OUTOFMEMORY;
- d2d_device_init(object, (ID2D1Factory1 *)iface, dxgi_device); + d2d_device_init(object, iface, dxgi_device);
TRACE("Create device %p.\n", object); *device = &object->ID2D1Device1_iface; @@ -523,15 +528,15 @@ static HRESULT d2d_factory_create_device(ID2D1Factory3 *iface, IDXGIDevice *dxgi return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDevice(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDevice(ID2D1Factory7 *iface, IDXGIDevice *dxgi_device, ID2D1Device **device) { TRACE("iface %p, dxgi_device %p, device %p.\n", iface, dxgi_device, device);
- return d2d_factory_create_device(iface, dxgi_device, (ID2D1Device1 **)device); + return d2d_factory_create_device((ID2D1Factory1 *)iface, dxgi_device, (ID2D1Device1 **)device); }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateStrokeStyle1(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateStrokeStyle1(ID2D1Factory7 *iface, const D2D1_STROKE_STYLE_PROPERTIES1 *desc, const float *dashes, UINT32 dash_count, ID2D1StrokeStyle1 **stroke_style) { @@ -558,7 +563,8 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateStrokeStyle1(ID2D1Factory3 *i return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreatePathGeometry1(ID2D1Factory3 *iface, ID2D1PathGeometry1 **geometry) +static HRESULT STDMETHODCALLTYPE d2d_factory_CreatePathGeometry1(ID2D1Factory7 *iface, + ID2D1PathGeometry1 **geometry) { struct d2d_geometry *object;
@@ -575,7 +581,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreatePathGeometry1(ID2D1Factory3 * return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDrawingStateBlock1(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDrawingStateBlock1(ID2D1Factory7 *iface, const D2D1_DRAWING_STATE_DESCRIPTION1 *desc, IDWriteRenderingParams *text_rendering_params, ID2D1DrawingStateBlock1 **state_block) { @@ -595,7 +601,7 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_CreateDrawingStateBlock1(ID2D1Facto return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_CreateGdiMetafile(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_CreateGdiMetafile(ID2D1Factory7 *iface, IStream *stream, ID2D1GdiMetafile **metafile) { FIXME("iface %p, stream %p, metafile %p stub!\n", iface, stream, metafile); @@ -1029,11 +1035,11 @@ static HRESULT d2d_factory_register_effect_from_stream(struct d2d_factory *facto return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_RegisterEffectFromStream(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_RegisterEffectFromStream(ID2D1Factory7 *iface, REFCLSID effect_id, IStream *property_xml, const D2D1_PROPERTY_BINDING *bindings, UINT32 binding_count, PD2D1_EFFECT_FACTORY effect_factory) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface);
TRACE("iface %p, effect_id %s, property_xml %p, bindings %p, binding_count %u, effect_factory %p.\n", iface, debugstr_guid(effect_id), property_xml, bindings, binding_count, effect_factory); @@ -1076,11 +1082,11 @@ HRESULT d2d_factory_register_builtin_effect(struct d2d_factory *factory, REFCLSI binding_count, effect_factory, TRUE); }
-static HRESULT STDMETHODCALLTYPE d2d_factory_RegisterEffectFromString(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_RegisterEffectFromString(ID2D1Factory7 *iface, REFCLSID effect_id, const WCHAR *property_xml, const D2D1_PROPERTY_BINDING *bindings, UINT32 binding_count, PD2D1_EFFECT_FACTORY effect_factory) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface);
TRACE("iface %p, effect_id %s, property_xml %s, bindings %p, binding_count %u, effect_factory %p.\n", iface, debugstr_guid(effect_id), debugstr_w(property_xml), bindings, binding_count, effect_factory); @@ -1091,9 +1097,9 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_RegisterEffectFromString(ID2D1Facto binding_count, effect_factory, FALSE); }
-static HRESULT STDMETHODCALLTYPE d2d_factory_UnregisterEffect(ID2D1Factory3 *iface, REFCLSID effect_id) +static HRESULT STDMETHODCALLTYPE d2d_factory_UnregisterEffect(ID2D1Factory7 *iface, REFCLSID effect_id) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface); struct d2d_effect_registration *effect;
TRACE("iface %p, effect_id %s.\n", iface, debugstr_guid(effect_id)); @@ -1117,10 +1123,10 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_UnregisterEffect(ID2D1Factory3 *ifa return D2DERR_EFFECT_IS_NOT_REGISTERED; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_GetRegisteredEffects(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_GetRegisteredEffects(ID2D1Factory7 *iface, CLSID *effects, UINT32 effect_count, UINT32 *returned, UINT32 *registered) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface); struct d2d_effect_registration *effect; UINT32 ret, reg;
@@ -1152,10 +1158,10 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_GetRegisteredEffects(ID2D1Factory3 return *returned == *registered ? S_OK : D2DERR_INSUFFICIENT_BUFFER; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_GetEffectProperties(ID2D1Factory3 *iface, +static HRESULT STDMETHODCALLTYPE d2d_factory_GetEffectProperties(ID2D1Factory7 *iface, REFCLSID effect_id, ID2D1Properties **props) { - struct d2d_factory *factory = impl_from_ID2D1Factory3(iface); + struct d2d_factory *factory = impl_from_ID2D1Factory7(iface); const struct d2d_effect_registration *reg;
TRACE("iface %p, effect_id %s, props %p.\n", iface, debugstr_guid(effect_id), props); @@ -1174,23 +1180,55 @@ static HRESULT STDMETHODCALLTYPE d2d_factory_GetEffectProperties(ID2D1Factory3 * return S_OK; }
-static HRESULT STDMETHODCALLTYPE d2d_factory_ID2D1Factory2_CreateDevice(ID2D1Factory3 *iface, IDXGIDevice *dxgi_device, - ID2D1Device1 **device) +static HRESULT STDMETHODCALLTYPE d2d_factory_ID2D1Factory2_CreateDevice(ID2D1Factory7 *iface, + IDXGIDevice *dxgi_device, ID2D1Device1 **device) { TRACE("iface %p, dxgi_device %p, device %p.\n", iface, dxgi_device, device);
- return d2d_factory_create_device(iface, dxgi_device, device); + return d2d_factory_create_device((ID2D1Factory1 *)iface, dxgi_device, device); }
-static HRESULT STDMETHODCALLTYPE d2d_factory_ID2D1Factory3_CreateDevice(ID2D1Factory3 *iface, IDXGIDevice *dxgi_device, - ID2D1Device2 **device) +static HRESULT STDMETHODCALLTYPE d2d_factory_ID2D1Factory3_CreateDevice(ID2D1Factory7 *iface, + IDXGIDevice *dxgi_device, ID2D1Device2 **device) { FIXME("iface %p, dxgi_device %p, device %p stub!\n", iface, dxgi_device, device);
return E_NOTIMPL; }
-static const struct ID2D1Factory3Vtbl d2d_factory_vtbl = +static HRESULT STDMETHODCALLTYPE d2d_factory_ID2D1Factory4_CreateDevice(ID2D1Factory7 *iface, + IDXGIDevice *dxgi_device, ID2D1Device3 **device) +{ + FIXME("iface %p, dxgi_device %p, device %p stub!\n", iface, dxgi_device, device); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_factory_ID2D1Factory5_CreateDevice(ID2D1Factory7 *iface, + IDXGIDevice *dxgi_device, ID2D1Device4 **device) +{ + FIXME("iface %p, dxgi_device %p, device %p stub!\n", iface, dxgi_device, device); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_factory_ID2D1Factory6_CreateDevice(ID2D1Factory7 *iface, + IDXGIDevice *dxgi_device, ID2D1Device5 **device) +{ + FIXME("iface %p, dxgi_device %p, device %p stub!\n", iface, dxgi_device, device); + + return E_NOTIMPL; +} + +static HRESULT STDMETHODCALLTYPE d2d_factory_ID2D1Factory7_CreateDevice(ID2D1Factory7 *iface, + IDXGIDevice *dxgi_device, ID2D1Device6 **device) +{ + FIXME("iface %p, dxgi_device %p, device %p stub!\n", iface, dxgi_device, device); + + return E_NOTIMPL; +} + +static const struct ID2D1Factory7Vtbl d2d_factory_vtbl = { d2d_factory_QueryInterface, d2d_factory_AddRef, @@ -1221,24 +1259,28 @@ static const struct ID2D1Factory3Vtbl d2d_factory_vtbl = d2d_factory_GetEffectProperties, d2d_factory_ID2D1Factory2_CreateDevice, d2d_factory_ID2D1Factory3_CreateDevice, + d2d_factory_ID2D1Factory4_CreateDevice, + d2d_factory_ID2D1Factory5_CreateDevice, + d2d_factory_ID2D1Factory6_CreateDevice, + d2d_factory_ID2D1Factory7_CreateDevice, };
static HRESULT STDMETHODCALLTYPE d2d_factory_mt_QueryInterface(ID2D1Multithread *iface, REFIID iid, void **out) { struct d2d_factory *factory = impl_from_ID2D1Multithread(iface); - return d2d_factory_QueryInterface(&factory->ID2D1Factory3_iface, iid, out); + return d2d_factory_QueryInterface(&factory->ID2D1Factory7_iface, iid, out); }
static ULONG STDMETHODCALLTYPE d2d_factory_mt_AddRef(ID2D1Multithread *iface) { struct d2d_factory *factory = impl_from_ID2D1Multithread(iface); - return d2d_factory_AddRef(&factory->ID2D1Factory3_iface); + return d2d_factory_AddRef(&factory->ID2D1Factory7_iface); }
static ULONG STDMETHODCALLTYPE d2d_factory_mt_Release(ID2D1Multithread *iface) { struct d2d_factory *factory = impl_from_ID2D1Multithread(iface); - return d2d_factory_Release(&factory->ID2D1Factory3_iface); + return d2d_factory_Release(&factory->ID2D1Factory7_iface); }
static BOOL STDMETHODCALLTYPE d2d_factory_mt_GetMultithreadProtected(ID2D1Multithread *iface) @@ -1303,7 +1345,7 @@ static void d2d_factory_init(struct d2d_factory *factory, D2D1_FACTORY_TYPE fact if (factory_options && factory_options->debugLevel != D2D1_DEBUG_LEVEL_NONE) WARN("Ignoring debug level %#x.\n", factory_options->debugLevel);
- factory->ID2D1Factory3_iface.lpVtbl = &d2d_factory_vtbl; + factory->ID2D1Factory7_iface.lpVtbl = &d2d_factory_vtbl; factory->ID2D1Multithread_iface.lpVtbl = factory_type == D2D1_FACTORY_TYPE_SINGLE_THREADED ? &d2d_factory_multithread_noop_vtbl : &d2d_factory_multithread_vtbl; factory->factory_type = factory_type; @@ -1336,8 +1378,8 @@ HRESULT WINAPI D2D1CreateFactory(D2D1_FACTORY_TYPE factory_type, REFIID iid,
TRACE("Created factory %p.\n", object);
- hr = ID2D1Factory3_QueryInterface(&object->ID2D1Factory3_iface, iid, factory); - ID2D1Factory3_Release(&object->ID2D1Factory3_iface); + hr = ID2D1Factory7_QueryInterface(&object->ID2D1Factory7_iface, iid, factory); + ID2D1Factory7_Release(&object->ID2D1Factory7_iface);
return hr; }