quartz: Implement IAMFilterData for IFilterMapper

Robert Shearman rob at codeweavers.com
Tue Apr 10 04:41:49 CDT 2007


Chris Robinson wrote:
> +static HRESULT WINAPI AMFilterData_CreateFilterData(IAMFilterData* iface,
> +                          REGFILTER2 *prf2, BYTE **pRegFilterData, ULONG *pcb)
> +{
> +    FilterMapper2Impl *This = impl_from_IAMFilterData(iface);
> +    int size = sizeof(struct REG_RF);
> +    unsigned int i;
> +    struct Vector mainStore = {NULL, 0, 0};
> +    struct Vector clsidStore = {NULL, 0, 0};
> +    struct REG_RF rrf;
> +
> +    TRACE("(%p/%p)->(%p, %p, %p)\n", This, iface, prf2, pRegFilterData, pcb);
> +
> +    if (prf2->dwVersion != 2)
> +    {
> +        FIXME("Filter registry version %d not supported\n", prf2->dwVersion);
> +        ZeroMemory(prf2, sizeof(*prf2));
> +        return E_FAIL;
> +    }
> +
> +    rrf.dwVersion = prf2->dwVersion;
> +    rrf.dwMerit = prf2->dwMerit;
> +    rrf.dwPins = prf2->u.s1.cPins2;
> +    rrf.dwUnused = 0;
> +
>   

You change FM2_WriteFilterData to be more suitable and then you should 
re-implement AMFilterData_CreateFilterData on top of this, not duplicate 
all of this code.

-- 
Rob Shearman




More information about the wine-devel mailing list