[PATCH 3/3] d3drm: Implement CreateMesh method and stubbed IDirect3DRMMesh interface.

Michael Stefaniuc mstefani at redhat.com
Thu Mar 29 17:28:57 CDT 2012


Hello Christian,

On 03/29/2012 11:57 PM, Christian Costa wrote:
> +HRESULT Direct3DRMMesh_create(REFIID riid, IUnknown** ppObj)
> +{
> +    IDirect3DRMMeshImpl* object;
> +
> +    TRACE("(%p)\n", ppObj);
> +
> +    object = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(IDirect3DRMMeshImpl));
> +    if (!object)
> +    {
> +        ERR("Out of memory\n");
> +        return E_OUTOFMEMORY;
> +    }
> +
> +    object->IDirect3DRMMesh_iface.lpVtbl = &Direct3DRMMesh_Vtbl;
> +    object->ref = 1;
> +
> +    if (IsEqualGUID(riid, &IID_IDirect3DRMMesh))
> +        *ppObj = (IUnknown*)&object->IDirect3DRMMesh_iface;
> +    else
> +        *ppObj = (IUnknown*)&object->IDirect3DRMMesh_iface;
both if and else code path are the same.

> +
> +    return S_OK;
> +}
> +

bye
	michael



More information about the wine-devel mailing list