mirror of
https://github.com/reactos/reactos.git
synced 2025-05-16 15:50:24 +00:00
[D3DRM] Sync with Wine Staging 1.7.47. CORE-9924
[PSDK] Update d3drm.h. svn path=/trunk/; revision=68528
This commit is contained in:
parent
1a0aa3e9fd
commit
bfcbe3d973
11 changed files with 151 additions and 105 deletions
|
@ -1,7 +1,7 @@
|
|||
|
||||
add_definitions(-D__WINESRC__)
|
||||
include_directories(${REACTOS_SOURCE_DIR}/include/reactos/wine)
|
||||
spec2def(d3drm.dll d3drm.spec)
|
||||
spec2def(d3drm.dll d3drm.spec ADD_IMPORTLIB)
|
||||
|
||||
list(APPEND SOURCE
|
||||
d3drm.c
|
||||
|
|
|
@ -44,7 +44,7 @@ struct d3drm
|
|||
IDirect3DRM IDirect3DRM_iface;
|
||||
IDirect3DRM2 IDirect3DRM2_iface;
|
||||
IDirect3DRM3 IDirect3DRM3_iface;
|
||||
LONG ref;
|
||||
LONG ref1, ref2, ref3, iface_count;
|
||||
};
|
||||
|
||||
static inline struct d3drm *impl_from_IDirect3DRM(IDirect3DRM *iface)
|
||||
|
@ -62,6 +62,12 @@ static inline struct d3drm *impl_from_IDirect3DRM3(IDirect3DRM3 *iface)
|
|||
return CONTAINING_RECORD(iface, struct d3drm, IDirect3DRM3_iface);
|
||||
}
|
||||
|
||||
static void d3drm_destroy(struct d3drm *d3drm)
|
||||
{
|
||||
HeapFree(GetProcessHeap(), 0, d3drm);
|
||||
TRACE("d3drm object %p is being destroyed.\n", d3drm);
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3drm1_QueryInterface(IDirect3DRM *iface, REFIID riid, void **out)
|
||||
{
|
||||
struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
|
||||
|
@ -84,8 +90,8 @@ static HRESULT WINAPI d3drm1_QueryInterface(IDirect3DRM *iface, REFIID riid, voi
|
|||
else
|
||||
{
|
||||
*out = NULL;
|
||||
WARN("%s not implemented, returning E_NOINTERFACE.\n", debugstr_guid(riid));
|
||||
return E_NOINTERFACE;
|
||||
WARN("%s not implemented, returning CLASS_E_CLASSNOTAVAILABLE.\n", debugstr_guid(riid));
|
||||
return CLASS_E_CLASSNOTAVAILABLE;
|
||||
}
|
||||
|
||||
IUnknown_AddRef((IUnknown *)*out);
|
||||
|
@ -95,22 +101,25 @@ static HRESULT WINAPI d3drm1_QueryInterface(IDirect3DRM *iface, REFIID riid, voi
|
|||
static ULONG WINAPI d3drm1_AddRef(IDirect3DRM *iface)
|
||||
{
|
||||
struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
|
||||
ULONG refcount = InterlockedIncrement(&d3drm->ref);
|
||||
ULONG refcount = InterlockedIncrement(&d3drm->ref1);
|
||||
|
||||
TRACE("%p increasing refcount to %u.\n", iface, refcount);
|
||||
|
||||
if (refcount == 1)
|
||||
InterlockedIncrement(&d3drm->iface_count);
|
||||
|
||||
return refcount;
|
||||
}
|
||||
|
||||
static ULONG WINAPI d3drm1_Release(IDirect3DRM *iface)
|
||||
{
|
||||
struct d3drm *d3drm = impl_from_IDirect3DRM(iface);
|
||||
ULONG refcount = InterlockedDecrement(&d3drm->ref);
|
||||
ULONG refcount = InterlockedDecrement(&d3drm->ref1);
|
||||
|
||||
TRACE("%p decreasing refcount to %u.\n", iface, refcount);
|
||||
|
||||
if (!refcount)
|
||||
HeapFree(GetProcessHeap(), 0, d3drm);
|
||||
if (!refcount && !InterlockedDecrement(&d3drm->iface_count))
|
||||
d3drm_destroy(d3drm);
|
||||
|
||||
return refcount;
|
||||
}
|
||||
|
@ -444,15 +453,27 @@ static HRESULT WINAPI d3drm2_QueryInterface(IDirect3DRM2 *iface, REFIID riid, vo
|
|||
static ULONG WINAPI d3drm2_AddRef(IDirect3DRM2 *iface)
|
||||
{
|
||||
struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
|
||||
ULONG refcount = InterlockedIncrement(&d3drm->ref2);
|
||||
|
||||
return d3drm1_AddRef(&d3drm->IDirect3DRM_iface);
|
||||
TRACE("%p increasing refcount to %u.\n", iface, refcount);
|
||||
|
||||
if (refcount == 1)
|
||||
InterlockedIncrement(&d3drm->iface_count);
|
||||
|
||||
return refcount;
|
||||
}
|
||||
|
||||
static ULONG WINAPI d3drm2_Release(IDirect3DRM2 *iface)
|
||||
{
|
||||
struct d3drm *d3drm = impl_from_IDirect3DRM2(iface);
|
||||
ULONG refcount = InterlockedDecrement(&d3drm->ref2);
|
||||
|
||||
return d3drm1_Release(&d3drm->IDirect3DRM_iface);
|
||||
TRACE("%p decreasing refcount to %u.\n", iface, refcount);
|
||||
|
||||
if (!refcount && !InterlockedDecrement(&d3drm->iface_count))
|
||||
d3drm_destroy(d3drm);
|
||||
|
||||
return refcount;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3drm2_CreateObject(IDirect3DRM2 *iface,
|
||||
|
@ -793,15 +814,27 @@ static HRESULT WINAPI d3drm3_QueryInterface(IDirect3DRM3 *iface, REFIID riid, vo
|
|||
static ULONG WINAPI d3drm3_AddRef(IDirect3DRM3 *iface)
|
||||
{
|
||||
struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
|
||||
ULONG refcount = InterlockedIncrement(&d3drm->ref3);
|
||||
|
||||
return d3drm1_AddRef(&d3drm->IDirect3DRM_iface);
|
||||
TRACE("%p increasing refcount to %u.\n", iface, refcount);
|
||||
|
||||
if (refcount == 1)
|
||||
InterlockedIncrement(&d3drm->iface_count);
|
||||
|
||||
return refcount;
|
||||
}
|
||||
|
||||
static ULONG WINAPI d3drm3_Release(IDirect3DRM3 *iface)
|
||||
{
|
||||
struct d3drm *d3drm = impl_from_IDirect3DRM3(iface);
|
||||
ULONG refcount = InterlockedDecrement(&d3drm->ref3);
|
||||
|
||||
return d3drm1_Release(&d3drm->IDirect3DRM_iface);
|
||||
TRACE("%p decreasing refcount to %u.\n", iface, refcount);
|
||||
|
||||
if (!refcount && !InterlockedDecrement(&d3drm->iface_count))
|
||||
d3drm_destroy(d3drm);
|
||||
|
||||
return refcount;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3drm3_CreateObject(IDirect3DRM3 *iface,
|
||||
|
@ -919,10 +952,10 @@ static HRESULT WINAPI d3drm3_CreateDevice(IDirect3DRM3 *iface,
|
|||
}
|
||||
|
||||
static HRESULT WINAPI d3drm3_CreateDeviceFromSurface(IDirect3DRM3 *iface, GUID *guid,
|
||||
IDirectDraw *ddraw, IDirectDrawSurface *backbuffer, IDirect3DRMDevice3 **device)
|
||||
IDirectDraw *ddraw, IDirectDrawSurface *backbuffer, DWORD flags, IDirect3DRMDevice3 **device)
|
||||
{
|
||||
FIXME("iface %p, guid %s, ddraw %p, backbuffer %p, device %p partial stub.\n",
|
||||
iface, debugstr_guid(guid), ddraw, backbuffer, device);
|
||||
FIXME("iface %p, guid %s, ddraw %p, backbuffer %p, flags %#x, device %p partial stub.\n",
|
||||
iface, debugstr_guid(guid), ddraw, backbuffer, flags, device);
|
||||
|
||||
return Direct3DRMDevice_create(&IID_IDirect3DRMDevice3, (IUnknown **)device);
|
||||
}
|
||||
|
@ -1162,32 +1195,29 @@ static HRESULT load_data(IDirect3DRM3 *iface, IDirectXFileData *data_object, IID
|
|||
IDirectXFileDataReference *reference;
|
||||
IDirectXFileBinary *binary;
|
||||
|
||||
hr = IDirectXFileObject_QueryInterface(child, &IID_IDirectXFileBinary, (void **)&binary);
|
||||
if (SUCCEEDED(hr))
|
||||
if (SUCCEEDED(IDirectXFileObject_QueryInterface(child,
|
||||
&IID_IDirectXFileBinary, (void **)&binary)))
|
||||
{
|
||||
FIXME("Binary Object not supported yet\n");
|
||||
IDirectXFileBinary_Release(binary);
|
||||
continue;
|
||||
}
|
||||
|
||||
hr = IDirectXFileObject_QueryInterface(child, &IID_IDirectXFileData, (void **)&data);
|
||||
if (SUCCEEDED(hr))
|
||||
else if (SUCCEEDED(IDirectXFileObject_QueryInterface(child,
|
||||
&IID_IDirectXFileData, (void **)&data)))
|
||||
{
|
||||
TRACE("Found Data Object\n");
|
||||
hr = load_data(iface, data, GUIDs, nb_GUIDs, LoadProc, ArgLP, LoadTextureProc, ArgLTP, frame);
|
||||
IDirectXFileData_Release(data);
|
||||
continue;
|
||||
}
|
||||
hr = IDirectXFileObject_QueryInterface(child, &IID_IDirectXFileDataReference, (void **)&reference);
|
||||
if (SUCCEEDED(hr))
|
||||
else if (SUCCEEDED(IDirectXFileObject_QueryInterface(child,
|
||||
&IID_IDirectXFileDataReference, (void **)&reference)))
|
||||
{
|
||||
TRACE("Found Data Object Reference\n");
|
||||
IDirectXFileDataReference_Resolve(reference, &data);
|
||||
hr = load_data(iface, data, GUIDs, nb_GUIDs, LoadProc, ArgLP, LoadTextureProc, ArgLTP, frame);
|
||||
IDirectXFileData_Release(data);
|
||||
IDirectXFileDataReference_Release(reference);
|
||||
continue;
|
||||
}
|
||||
IDirectXFileObject_Release(child);
|
||||
}
|
||||
|
||||
if (hr != DXFILEERR_NOMOREOBJECTS)
|
||||
|
@ -1480,9 +1510,25 @@ HRESULT WINAPI Direct3DRMCreate(IDirect3DRM **d3drm)
|
|||
object->IDirect3DRM_iface.lpVtbl = &d3drm1_vtbl;
|
||||
object->IDirect3DRM2_iface.lpVtbl = &d3drm2_vtbl;
|
||||
object->IDirect3DRM3_iface.lpVtbl = &d3drm3_vtbl;
|
||||
object->ref = 1;
|
||||
object->ref1 = 1;
|
||||
object->iface_count = 1;
|
||||
|
||||
*d3drm = &object->IDirect3DRM_iface;
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
HRESULT WINAPI DllCanUnloadNow(void)
|
||||
{
|
||||
return S_FALSE;
|
||||
}
|
||||
|
||||
HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, void **ppv)
|
||||
{
|
||||
TRACE("(%s, %s, %p): stub\n", debugstr_guid(rclsid), debugstr_guid(riid), ppv);
|
||||
|
||||
if(!ppv)
|
||||
return E_INVALIDARG;
|
||||
|
||||
return CLASS_E_CLASSNOTAVAILABLE;
|
||||
}
|
||||
|
|
|
@ -19,5 +19,5 @@
|
|||
@ stdcall D3DRMVectorScale(ptr ptr float)
|
||||
@ stdcall D3DRMVectorSubtract(ptr ptr ptr)
|
||||
@ stdcall Direct3DRMCreate(ptr)
|
||||
@ stub -private DllCanUnloadNow
|
||||
@ stub -private DllGetClassObject
|
||||
@ stdcall -private DllCanUnloadNow()
|
||||
@ stdcall -private DllGetClassObject(ptr ptr ptr)
|
||||
|
|
|
@ -58,6 +58,6 @@ struct d3drm_file_header
|
|||
DWORD flags;
|
||||
};
|
||||
|
||||
extern char templates[];
|
||||
extern char templates[] DECLSPEC_HIDDEN;
|
||||
|
||||
#endif /* __D3DRM_PRIVATE_INCLUDED__ */
|
||||
|
|
|
@ -3,9 +3,6 @@
|
|||
*
|
||||
* Copyright 2011, 2012 André Hentschel
|
||||
*
|
||||
* This file contains the (internal) driver registration functions,
|
||||
* driver enumeration APIs and DirectDraw creation functions.
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
|
|
|
@ -3,9 +3,6 @@
|
|||
*
|
||||
* Copyright 2013 André Hentschel
|
||||
*
|
||||
* This file contains the (internal) driver registration functions,
|
||||
* driver enumeration APIs and DirectDraw creation functions.
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
|
|
|
@ -462,66 +462,25 @@ static HRESULT WINAPI d3drm_frame2_QueryInterface(IDirect3DRMFrame2 *iface, REFI
|
|||
|
||||
TRACE("iface %p, riid %s, out %p.\n", iface, debugstr_guid(riid), out);
|
||||
|
||||
if (IsEqualGUID(riid, &IID_IDirect3DRMFrame2)
|
||||
|| IsEqualGUID(riid, &IID_IDirect3DRMFrame)
|
||||
|| IsEqualGUID(riid, &IID_IUnknown))
|
||||
{
|
||||
*out = &frame->IDirect3DRMFrame2_iface;
|
||||
}
|
||||
else if (IsEqualGUID(riid, &IID_IDirect3DRMFrame3))
|
||||
{
|
||||
*out = &frame->IDirect3DRMFrame3_iface;
|
||||
}
|
||||
else
|
||||
{
|
||||
*out = NULL;
|
||||
WARN("%s not implemented, returning E_NOINTERFACE.\n", debugstr_guid(riid));
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
IUnknown_AddRef((IUnknown *)*out);
|
||||
return S_OK;
|
||||
return IDirect3DRMFrame3_QueryInterface(&frame->IDirect3DRMFrame3_iface, riid, out);
|
||||
}
|
||||
|
||||
static ULONG WINAPI d3drm_frame2_AddRef(IDirect3DRMFrame2 *iface)
|
||||
{
|
||||
struct d3drm_frame *frame = impl_from_IDirect3DRMFrame2(iface);
|
||||
ULONG refcount = InterlockedIncrement(&frame->ref);
|
||||
|
||||
TRACE("%p increasing refcount to %u.\n", iface, refcount);
|
||||
TRACE("iface %p.\n", iface);
|
||||
|
||||
return refcount;
|
||||
return IDirect3DRMFrame3_AddRef(&frame->IDirect3DRMFrame3_iface);
|
||||
}
|
||||
|
||||
static ULONG WINAPI d3drm_frame2_Release(IDirect3DRMFrame2 *iface)
|
||||
{
|
||||
struct d3drm_frame *frame = impl_from_IDirect3DRMFrame2(iface);
|
||||
ULONG refcount = InterlockedDecrement(&frame->ref);
|
||||
ULONG i;
|
||||
|
||||
TRACE("%p decreasing refcount to %u.\n", iface, refcount);
|
||||
TRACE("iface %p.\n", iface);
|
||||
|
||||
if (!refcount)
|
||||
{
|
||||
for (i = 0; i < frame->nb_children; ++i)
|
||||
{
|
||||
IDirect3DRMFrame3_Release(frame->children[i]);
|
||||
}
|
||||
HeapFree(GetProcessHeap(), 0, frame->children);
|
||||
for (i = 0; i < frame->nb_visuals; ++i)
|
||||
{
|
||||
IDirect3DRMVisual_Release(frame->visuals[i]);
|
||||
}
|
||||
HeapFree(GetProcessHeap(), 0, frame->visuals);
|
||||
for (i = 0; i < frame->nb_lights; ++i)
|
||||
{
|
||||
IDirect3DRMLight_Release(frame->lights[i]);
|
||||
}
|
||||
HeapFree(GetProcessHeap(), 0, frame->lights);
|
||||
HeapFree(GetProcessHeap(), 0, frame);
|
||||
}
|
||||
|
||||
return refcount;
|
||||
return IDirect3DRMFrame3_Release(&frame->IDirect3DRMFrame3_iface);
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3drm_frame2_Clone(IDirect3DRMFrame2 *iface,
|
||||
|
@ -1223,25 +1182,68 @@ static HRESULT WINAPI d3drm_frame3_QueryInterface(IDirect3DRMFrame3 *iface, REFI
|
|||
|
||||
TRACE("iface %p, riid %s, out %p.\n", iface, debugstr_guid(riid), out);
|
||||
|
||||
return d3drm_frame2_QueryInterface(&frame->IDirect3DRMFrame2_iface, riid, out);
|
||||
if (IsEqualGUID(riid, &IID_IDirect3DRMFrame2)
|
||||
|| IsEqualGUID(riid, &IID_IDirect3DRMFrame)
|
||||
|| IsEqualGUID(riid, &IID_IDirect3DRMObject)
|
||||
|| IsEqualGUID(riid, &IID_IDirect3DRMVisual)
|
||||
|| IsEqualGUID(riid, &IID_IUnknown))
|
||||
{
|
||||
*out = &frame->IDirect3DRMFrame2_iface;
|
||||
}
|
||||
else if (IsEqualGUID(riid, &IID_IDirect3DRMFrame3))
|
||||
{
|
||||
*out = &frame->IDirect3DRMFrame3_iface;
|
||||
}
|
||||
else
|
||||
{
|
||||
*out = NULL;
|
||||
WARN("%s not implemented, returning CLASS_E_CLASSNOTAVAILABLE.\n", debugstr_guid(riid));
|
||||
return CLASS_E_CLASSNOTAVAILABLE;
|
||||
}
|
||||
|
||||
IUnknown_AddRef((IUnknown *)*out);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static ULONG WINAPI d3drm_frame3_AddRef(IDirect3DRMFrame3 *iface)
|
||||
{
|
||||
struct d3drm_frame *frame = impl_from_IDirect3DRMFrame3(iface);
|
||||
ULONG refcount = InterlockedIncrement(&frame->ref);
|
||||
|
||||
TRACE("iface %p.\n", iface);
|
||||
TRACE("%p increasing refcount to %u.\n", iface, refcount);
|
||||
|
||||
return d3drm_frame2_AddRef(&frame->IDirect3DRMFrame2_iface);
|
||||
return refcount;
|
||||
}
|
||||
|
||||
static ULONG WINAPI d3drm_frame3_Release(IDirect3DRMFrame3 *iface)
|
||||
{
|
||||
struct d3drm_frame *frame = impl_from_IDirect3DRMFrame3(iface);
|
||||
ULONG refcount = InterlockedDecrement(&frame->ref);
|
||||
ULONG i;
|
||||
|
||||
TRACE("iface %p.\n", iface);
|
||||
TRACE("%p decreasing refcount to %u.\n", iface, refcount);
|
||||
|
||||
return d3drm_frame2_Release(&frame->IDirect3DRMFrame2_iface);
|
||||
if (!refcount)
|
||||
{
|
||||
for (i = 0; i < frame->nb_children; ++i)
|
||||
{
|
||||
IDirect3DRMFrame3_Release(frame->children[i]);
|
||||
}
|
||||
HeapFree(GetProcessHeap(), 0, frame->children);
|
||||
for (i = 0; i < frame->nb_visuals; ++i)
|
||||
{
|
||||
IDirect3DRMVisual_Release(frame->visuals[i]);
|
||||
}
|
||||
HeapFree(GetProcessHeap(), 0, frame->visuals);
|
||||
for (i = 0; i < frame->nb_lights; ++i)
|
||||
{
|
||||
IDirect3DRMLight_Release(frame->lights[i]);
|
||||
}
|
||||
HeapFree(GetProcessHeap(), 0, frame->lights);
|
||||
HeapFree(GetProcessHeap(), 0, frame);
|
||||
}
|
||||
|
||||
return refcount;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3drm_frame3_Clone(IDirect3DRMFrame3 *iface,
|
||||
|
@ -2293,5 +2295,5 @@ HRESULT Direct3DRMFrame_create(REFIID riid, IUnknown *parent, IUnknown **out)
|
|||
|
||||
hr = IDirect3DRMFrame3_QueryInterface(&object->IDirect3DRMFrame3_iface, riid, (void **)out);
|
||||
IDirect3DRMFrame3_Release(&object->IDirect3DRMFrame3_iface);
|
||||
return S_OK;
|
||||
return hr;
|
||||
}
|
||||
|
|
|
@ -343,7 +343,9 @@ static void clean_mesh_builder_data(struct d3drm_mesh_builder *mesh_builder)
|
|||
}
|
||||
mesh_builder->nb_materials = 0;
|
||||
HeapFree(GetProcessHeap(), 0, mesh_builder->materials);
|
||||
mesh_builder->materials = NULL;
|
||||
HeapFree(GetProcessHeap(), 0, mesh_builder->material_indices);
|
||||
mesh_builder->material_indices = NULL;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3drm_mesh_builder2_QueryInterface(IDirect3DRMMeshBuilder2 *iface, REFIID riid, void **out)
|
||||
|
@ -1235,20 +1237,21 @@ HRESULT load_mesh_data(IDirect3DRMMeshBuilder3 *iface, IDirectXFileData *pData,
|
|||
IDirectXFileData *data;
|
||||
char **filename;
|
||||
|
||||
hr = IDirectXFileObject_QueryInterface(material_child, &IID_IDirectXFileData, (void **)&data);
|
||||
if (FAILED(hr))
|
||||
if (FAILED(hr = IDirectXFileObject_QueryInterface(material_child,
|
||||
&IID_IDirectXFileData, (void **)&data)))
|
||||
{
|
||||
IDirectXFileDataReference *reference;
|
||||
|
||||
hr = IDirectXFileObject_QueryInterface(material_child, &IID_IDirectXFileDataReference, (void **)&reference);
|
||||
if (FAILED(hr))
|
||||
goto end;
|
||||
|
||||
hr = IDirectXFileDataReference_Resolve(reference, &data);
|
||||
IDirectXFileDataReference_Release(reference);
|
||||
if (FAILED(hr))
|
||||
goto end;
|
||||
if (SUCCEEDED(IDirectXFileObject_QueryInterface(material_child,
|
||||
&IID_IDirectXFileDataReference, (void **)&reference)))
|
||||
{
|
||||
hr = IDirectXFileDataReference_Resolve(reference, &data);
|
||||
IDirectXFileDataReference_Release(reference);
|
||||
}
|
||||
}
|
||||
IDirectXFileObject_Release(material_child);
|
||||
if (FAILED(hr))
|
||||
goto end;
|
||||
|
||||
hr = IDirectXFileData_GetType(data, &guid);
|
||||
if (hr != DXFILE_OK)
|
||||
|
@ -1293,6 +1296,7 @@ HRESULT load_mesh_data(IDirect3DRMMeshBuilder3 *iface, IDirectXFileData *pData,
|
|||
}
|
||||
}
|
||||
}
|
||||
IDirectXFileData_Release(data);
|
||||
}
|
||||
else if (hr != DXFILEERR_NOMOREOBJECTS)
|
||||
{
|
||||
|
@ -1351,7 +1355,10 @@ HRESULT load_mesh_data(IDirect3DRMMeshBuilder3 *iface, IDirectXFileData *pData,
|
|||
if (!This->nb_normals)
|
||||
{
|
||||
/* Compute face normal */
|
||||
if (nb_face_indexes > 2)
|
||||
if (nb_face_indexes > 2
|
||||
&& faces_vertex_idx_ptr[0] < This->nb_vertices
|
||||
&& faces_vertex_idx_ptr[1] < This->nb_vertices
|
||||
&& faces_vertex_idx_ptr[2] < This->nb_vertices)
|
||||
{
|
||||
D3DVECTOR a, b;
|
||||
|
||||
|
|
|
@ -3,9 +3,6 @@
|
|||
*
|
||||
* Copyright 2012 André Hentschel
|
||||
*
|
||||
* This file contains the (internal) driver registration functions,
|
||||
* driver enumeration APIs and DirectDraw creation functions.
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU Lesser General Public
|
||||
* License as published by the Free Software Foundation; either
|
||||
|
|
|
@ -353,7 +353,7 @@ DECLARE_INTERFACE_(IDirect3DRM3,IUnknown)
|
|||
STDMETHOD(CreateMaterial)(THIS_ D3DVALUE, IDirect3DRMMaterial2 **material) PURE;
|
||||
STDMETHOD(CreateDevice)(THIS_ DWORD width, DWORD height, IDirect3DRMDevice3 **device) PURE;
|
||||
STDMETHOD(CreateDeviceFromSurface)(THIS_ GUID *guid, IDirectDraw *ddraw,
|
||||
IDirectDrawSurface *surface, IDirect3DRMDevice3 **device) PURE;
|
||||
IDirectDrawSurface *surface, DWORD flags, IDirect3DRMDevice3 **device) PURE;
|
||||
STDMETHOD(CreateDeviceFromD3D)(THIS_ IDirect3D2 *d3d, IDirect3DDevice2 *d3d_device,
|
||||
IDirect3DRMDevice3 **device) PURE;
|
||||
STDMETHOD(CreateDeviceFromClipper)(THIS_ IDirectDrawClipper *clipper, GUID *guid,
|
||||
|
@ -411,7 +411,7 @@ DECLARE_INTERFACE_(IDirect3DRM3,IUnknown)
|
|||
#define IDirect3DRM3_CreateLightRGB(p,a,b,c,d,e) (p)->lpVtbl->CreateLightRGB(p,a,b,c,d,e)
|
||||
#define IDirect3DRM3_CreateMaterial(p,a,b) (p)->lpVtbl->CreateMaterial(p,a,b)
|
||||
#define IDirect3DRM3_CreateDevice(p,a,b,c) (p)->lpVtbl->CreateDevice(p,a,b,c)
|
||||
#define IDirect3DRM3_CreateDeviceFromSurface(p,a,b,c,d) (p)->lpVtbl->CreateDeviceFromSurface(p,a,b,c,d)
|
||||
#define IDirect3DRM3_CreateDeviceFromSurface(p,a,b,c,d,e) (p)->lpVtbl->CreateDeviceFromSurface(p,a,b,c,d,e)
|
||||
#define IDirect3DRM3_CreateDeviceFromD3D(p,a,b,c) (p)->lpVtbl->CreateDeviceFromD3D(p,a,b,c)
|
||||
#define IDirect3DRM3_CreateDeviceFromClipper(p,a,b,c,d,e) (p)->lpVtbl->CreateDeviceFromClipper(p,a,b,c,d,e)
|
||||
#define IDirect3DRM3_CreateTextureFromSurface(p,a,b) (p)->lpVtbl->CreateTextureFromSurface(p,a,b)
|
||||
|
@ -455,7 +455,7 @@ DECLARE_INTERFACE_(IDirect3DRM3,IUnknown)
|
|||
#define IDirect3DRM3_CreateLightRGB(p,a,b,c,d,e) (p)->CreateLightRGB(a,b,c,d,e)
|
||||
#define IDirect3DRM3_CreateMaterial(p,a,b) (p)->CreateMaterial(a,b)
|
||||
#define IDirect3DRM3_CreateDevice(p,a,b,c) (p)->CreateDevice(a,b,c)
|
||||
#define IDirect3DRM3_CreateDeviceFromSurface(p,a,b,c,d) (p)->CreateDeviceFromSurface(a,b,c,d)
|
||||
#define IDirect3DRM3_CreateDeviceFromSurface(p,a,b,c,d,e) (p)->CreateDeviceFromSurface(a,b,c,d,e)
|
||||
#define IDirect3DRM3_CreateDeviceFromD3D(p,a,b,c) (p)->CreateDeviceFromD3D(a,b,c)
|
||||
#define IDirect3DRM3_CreateDeviceFromClipper(p,a,b,c,d,e) (p)->CreateDeviceFromClipper(a,b,c,d,e)
|
||||
#define IDirect3DRM3_CreateTextureFromSurface(p,a,b) (p)->CreateTextureFromSurface(a,b)
|
||||
|
|
|
@ -25,7 +25,7 @@ reactos/dll/directx/wine/amstream # Synced to WineStaging-1.7.47
|
|||
reactos/dll/directx/wine/d3d8 # Synced to WineStaging-1.7.37
|
||||
reactos/dll/directx/wine/d3d9 # Synced to WineStaging-1.7.37
|
||||
reactos/dll/directx/wine/d3dcompiler_43 # Synced to WineStaging-1.7.37
|
||||
reactos/dll/directx/wine/d3drm # Synced to WineStaging-1.7.37
|
||||
reactos/dll/directx/wine/d3drm # Synced to WineStaging-1.7.47
|
||||
reactos/dll/directx/wine/d3dx9_24 => 43 # Synced to WineStaging-1.7.37
|
||||
reactos/dll/directx/wine/d3dxof # Synced to WineStaging-1.7.47
|
||||
reactos/dll/directx/wine/ddraw # Synced to WineStaging-1.7.37
|
||||
|
|
Loading…
Reference in a new issue