[PATCH v2 3/8] d2d1: Implement ID2D1EffectContext_GetDpi().

Nikolay Sivov nsivov at codeweavers.com
Fri Apr 29 02:39:45 CDT 2022



On 4/28/22 13:40, Ziqing Hui wrote:
>   static void STDMETHODCALLTYPE d2d_effect_context_GetDpi(ID2D1EffectContext *iface, float *dpi_x, float *dpi_y)
>   {
> -    FIXME("iface %p, dpi_x %p, dpi_y %p stub!\n", iface, dpi_x, dpi_y);
> +    struct d2d_effect_context *effect_context = impl_from_ID2D1EffectContext(iface);
> +
> +    TRACE("iface %p, dpi_x %p, dpi_y %p.\n", iface, dpi_x, dpi_y);
> +
> +    return ID2D1DeviceContext_GetDpi(effect_context->device_context, dpi_x, dpi_y);
>   }
>   
>   static HRESULT STDMETHODCALLTYPE d2d_effect_context_CreateEffect(ID2D1EffectContext *iface,
Were you able to test this? I realize it requires a minimal custom 
effect to access context object. It makes sense I guess to forward it 
like you did, as opposed to returning dpi at the time of CreateEffect() 
call, but it not obvious just from this patch.

Note that you don't need "return" here.



More information about the wine-devel mailing list