Commit 75deeb45 authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

d3drm: Avoid LPCSTR.

parent 5daf5e80
......@@ -329,20 +329,16 @@ static HRESULT WINAPI IDirect3DRMImpl_LoadTextureFromResource(IDirect3DRM *iface
return Direct3DRMTexture_create(&IID_IDirect3DRMTexture, (IUnknown **)texture);
}
static HRESULT WINAPI IDirect3DRMImpl_SetSearchPath(IDirect3DRM* iface, LPCSTR path)
static HRESULT WINAPI IDirect3DRMImpl_SetSearchPath(IDirect3DRM *iface, const char *path)
{
IDirect3DRMImpl *This = impl_from_IDirect3DRM(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, path);
FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
return E_NOTIMPL;
}
static HRESULT WINAPI IDirect3DRMImpl_AddSearchPath(IDirect3DRM* iface, LPCSTR path)
static HRESULT WINAPI IDirect3DRMImpl_AddSearchPath(IDirect3DRM *iface, const char *path)
{
IDirect3DRMImpl *This = impl_from_IDirect3DRM(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, path);
FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
return E_NOTIMPL;
}
......@@ -696,20 +692,16 @@ static HRESULT WINAPI IDirect3DRM2Impl_LoadTextureFromResource(IDirect3DRM2 *ifa
return Direct3DRMTexture_create(&IID_IDirect3DRMTexture2, (IUnknown **)texture);
}
static HRESULT WINAPI IDirect3DRM2Impl_SetSearchPath(IDirect3DRM2* iface, LPCSTR path)
static HRESULT WINAPI IDirect3DRM2Impl_SetSearchPath(IDirect3DRM2 *iface, const char *path)
{
IDirect3DRMImpl *This = impl_from_IDirect3DRM2(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, path);
FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
return E_NOTIMPL;
}
static HRESULT WINAPI IDirect3DRM2Impl_AddSearchPath(IDirect3DRM2* iface, LPCSTR path)
static HRESULT WINAPI IDirect3DRM2Impl_AddSearchPath(IDirect3DRM2 *iface, const char *path)
{
IDirect3DRMImpl *This = impl_from_IDirect3DRM2(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, path);
FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
return E_NOTIMPL;
}
......@@ -1082,20 +1074,16 @@ static HRESULT WINAPI IDirect3DRM3Impl_LoadTextureFromResource(IDirect3DRM3 *ifa
return Direct3DRMTexture_create(&IID_IDirect3DRMTexture3, (IUnknown **)texture);
}
static HRESULT WINAPI IDirect3DRM3Impl_SetSearchPath(IDirect3DRM3* iface, LPCSTR path)
static HRESULT WINAPI IDirect3DRM3Impl_SetSearchPath(IDirect3DRM3 *iface, const char *path)
{
IDirect3DRMImpl *This = impl_from_IDirect3DRM3(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, path);
FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
return E_NOTIMPL;
}
static HRESULT WINAPI IDirect3DRM3Impl_AddSearchPath(IDirect3DRM3* iface, LPCSTR path)
static HRESULT WINAPI IDirect3DRM3Impl_AddSearchPath(IDirect3DRM3* iface, const char *path)
{
IDirect3DRMImpl *This = impl_from_IDirect3DRM3(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, path);
FIXME("iface %p, path %s stub!\n", iface, debugstr_a(path));
return E_NOTIMPL;
}
......
......@@ -168,11 +168,9 @@ static DWORD WINAPI IDirect3DRMDevice2Impl_GetAppData(IDirect3DRMDevice2* iface)
return 0;
}
static HRESULT WINAPI IDirect3DRMDevice2Impl_SetName(IDirect3DRMDevice2* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMDevice2Impl_SetName(IDirect3DRMDevice2 *iface, const char *name)
{
IDirect3DRMDeviceImpl *This = impl_from_IDirect3DRMDevice2(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......@@ -580,11 +578,9 @@ static DWORD WINAPI IDirect3DRMDevice3Impl_GetAppData(IDirect3DRMDevice3* iface)
return 0;
}
static HRESULT WINAPI IDirect3DRMDevice3Impl_SetName(IDirect3DRMDevice3* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMDevice3Impl_SetName(IDirect3DRMDevice3 *iface, const char *name)
{
IDirect3DRMDeviceImpl *This = impl_from_IDirect3DRMDevice3(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......@@ -1070,11 +1066,9 @@ static DWORD WINAPI IDirect3DRMWinDeviceImpl_GetAppData(IDirect3DRMWinDevice* if
return 0;
}
static HRESULT WINAPI IDirect3DRMWinDeviceImpl_SetName(IDirect3DRMWinDevice* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMWinDeviceImpl_SetName(IDirect3DRMWinDevice *iface, const char *name)
{
IDirect3DRMDeviceImpl *This = impl_from_IDirect3DRMWinDevice(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......
......@@ -150,11 +150,9 @@ static DWORD WINAPI IDirect3DRMFaceImpl_GetAppData(IDirect3DRMFace* iface)
return 0;
}
static HRESULT WINAPI IDirect3DRMFaceImpl_SetName(IDirect3DRMFace* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMFaceImpl_SetName(IDirect3DRMFace *iface, const char *name)
{
IDirect3DRMFaceImpl *This = impl_from_IDirect3DRMFace(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......@@ -472,11 +470,9 @@ static DWORD WINAPI IDirect3DRMFace2Impl_GetAppData(IDirect3DRMFace2* iface)
return 0;
}
static HRESULT WINAPI IDirect3DRMFace2Impl_SetName(IDirect3DRMFace2* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMFace2Impl_SetName(IDirect3DRMFace2 *iface, const char *name)
{
IDirect3DRMFaceImpl *This = impl_from_IDirect3DRMFace2(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......
......@@ -561,11 +561,9 @@ static DWORD WINAPI IDirect3DRMFrame2Impl_GetAppData(IDirect3DRMFrame2* iface)
return 0;
}
static HRESULT WINAPI IDirect3DRMFrame2Impl_SetName(IDirect3DRMFrame2* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMFrame2Impl_SetName(IDirect3DRMFrame2 *iface, const char *name)
{
IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame2(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......@@ -1419,11 +1417,9 @@ static DWORD WINAPI IDirect3DRMFrame3Impl_GetAppData(IDirect3DRMFrame3* iface)
return 0;
}
static HRESULT WINAPI IDirect3DRMFrame3Impl_SetName(IDirect3DRMFrame3* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMFrame3Impl_SetName(IDirect3DRMFrame3 *iface, const char *name)
{
IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......@@ -2356,13 +2352,11 @@ static HRESULT WINAPI IDirect3DRMFrame3Impl_RayPick(IDirect3DRMFrame3 *iface, ID
return E_NOTIMPL;
}
static HRESULT WINAPI IDirect3DRMFrame3Impl_Save(IDirect3DRMFrame3* iface, LPCSTR filename,
D3DRMXOFFORMAT d3dFormat,
D3DRMSAVEOPTIONS d3dSaveFlags)
static HRESULT WINAPI IDirect3DRMFrame3Impl_Save(IDirect3DRMFrame3 *iface,
const char *filename, D3DRMXOFFORMAT format, D3DRMSAVEOPTIONS flags)
{
IDirect3DRMFrameImpl *This = impl_from_IDirect3DRMFrame3(iface);
FIXME("(%p/%p)->(%p,%u,%u): stub\n", iface, This, filename, d3dFormat, d3dSaveFlags);
FIXME("iface %p, filename %s, format %#x, flags %#x stub!\n",
iface, debugstr_a(filename), format, flags);
return E_NOTIMPL;
}
......
......@@ -145,11 +145,9 @@ static DWORD WINAPI IDirect3DRMLightImpl_GetAppData(IDirect3DRMLight* iface)
return 0;
}
static HRESULT WINAPI IDirect3DRMLightImpl_SetName(IDirect3DRMLight* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMLightImpl_SetName(IDirect3DRMLight *iface, const char *name)
{
IDirect3DRMLightImpl *This = impl_from_IDirect3DRMLight(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......
......@@ -141,9 +141,9 @@ static DWORD WINAPI IDirect3DRMMaterial2Impl_GetAppData(IDirect3DRMMaterial2* if
return 0;
}
static HRESULT WINAPI IDirect3DRMMaterial2Impl_SetName(IDirect3DRMMaterial2* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMMaterial2Impl_SetName(IDirect3DRMMaterial2 *iface, const char *name)
{
FIXME("(%p)->(%s): stub\n", iface, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......
......@@ -464,14 +464,13 @@ static DWORD WINAPI IDirect3DRMMeshBuilder2Impl_GetAppData(IDirect3DRMMeshBuilde
return 0;
}
static HRESULT WINAPI IDirect3DRMMeshBuilder2Impl_SetName(IDirect3DRMMeshBuilder2* iface,
LPCSTR name)
static HRESULT WINAPI IDirect3DRMMeshBuilder2Impl_SetName(IDirect3DRMMeshBuilder2 *iface, const char *name)
{
IDirect3DRMMeshBuilderImpl *This = impl_from_IDirect3DRMMeshBuilder2(iface);
IDirect3DRMMeshBuilderImpl *mesh_builder = impl_from_IDirect3DRMMeshBuilder2(iface);
TRACE("(%p)->(%s)\n", This, debugstr_a(name));
TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
return IDirect3DRMMeshBuilder3_SetName(&This->IDirect3DRMMeshBuilder3_iface, name);
return IDirect3DRMMeshBuilder3_SetName(&mesh_builder->IDirect3DRMMeshBuilder3_iface, name);
}
static HRESULT WINAPI IDirect3DRMMeshBuilder2Impl_GetName(IDirect3DRMMeshBuilder2* iface,
......@@ -1049,13 +1048,12 @@ static DWORD WINAPI IDirect3DRMMeshBuilder3Impl_GetAppData(IDirect3DRMMeshBuilde
return 0;
}
static HRESULT WINAPI IDirect3DRMMeshBuilder3Impl_SetName(IDirect3DRMMeshBuilder3* iface,
LPCSTR name)
static HRESULT WINAPI IDirect3DRMMeshBuilder3Impl_SetName(IDirect3DRMMeshBuilder3 *iface, const char *name)
{
IDirect3DRMMeshBuilderImpl *This = impl_from_IDirect3DRMMeshBuilder3(iface);
IDirect3DRMMeshBuilderImpl *mesh_builder = impl_from_IDirect3DRMMeshBuilder3(iface);
char *string = NULL;
TRACE("(%p)->(%s)\n", This, debugstr_a(name));
TRACE("iface %p, name %s.\n", iface, debugstr_a(name));
if (name)
{
......@@ -1063,8 +1061,8 @@ static HRESULT WINAPI IDirect3DRMMeshBuilder3Impl_SetName(IDirect3DRMMeshBuilder
if (!string) return E_OUTOFMEMORY;
strcpy(string, name);
}
HeapFree(GetProcessHeap(), 0, This->name);
This->name = string;
HeapFree(GetProcessHeap(), 0, mesh_builder->name);
mesh_builder->name = string;
return D3DRM_OK;
}
......@@ -2589,12 +2587,9 @@ static DWORD WINAPI IDirect3DRMMeshImpl_GetAppData(IDirect3DRMMesh* iface)
return 0;
}
static HRESULT WINAPI IDirect3DRMMeshImpl_SetName(IDirect3DRMMesh* iface,
LPCSTR pName)
static HRESULT WINAPI IDirect3DRMMeshImpl_SetName(IDirect3DRMMesh *iface, const char *name)
{
IDirect3DRMMeshImpl *This = impl_from_IDirect3DRMMesh(iface);
FIXME("(%p)->(%s): stub\n", This, pName);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......
......@@ -146,9 +146,9 @@ static DWORD WINAPI IDirect3DRMTexture2Impl_GetAppData(IDirect3DRMTexture2* ifac
return IDirect3DRMTexture3_GetAppData(&This->IDirect3DRMTexture3_iface);
}
static HRESULT WINAPI IDirect3DRMTexture2Impl_SetName(IDirect3DRMTexture2* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMTexture2Impl_SetName(IDirect3DRMTexture2 *iface, const char *name)
{
FIXME("(%p)->(%s): stub\n", iface, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......@@ -354,12 +354,11 @@ static HRESULT WINAPI IDirect3DRMTexture2Impl_InitFromImage(IDirect3DRMTexture2
return E_NOTIMPL;
}
static HRESULT WINAPI IDirect3DRMTexture2Impl_InitFromResource2(IDirect3DRMTexture2* iface, HMODULE module,
LPCSTR /* LPCTSTR */ name, LPCSTR /* LPCTSTR */ type)
static HRESULT WINAPI IDirect3DRMTexture2Impl_InitFromResource2(IDirect3DRMTexture2 *iface,
HMODULE module, const char *name, const char *type)
{
IDirect3DRMTextureImpl *This = impl_from_IDirect3DRMTexture2(iface);
FIXME("(%p/%p)->(%p, %s, %s): stub\n", iface, This, module, debugstr_a(name), debugstr_a(type));
FIXME("iface %p, module %p, name %s, type %s stub!\n",
iface, module, debugstr_a(name), debugstr_a(type));
return E_NOTIMPL;
}
......@@ -516,9 +515,9 @@ static DWORD WINAPI IDirect3DRMTexture3Impl_GetAppData(IDirect3DRMTexture3* ifac
return This->app_data;
}
static HRESULT WINAPI IDirect3DRMTexture3Impl_SetName(IDirect3DRMTexture3* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMTexture3Impl_SetName(IDirect3DRMTexture3 *iface, const char *name)
{
FIXME("(%p)->(%s): stub\n", iface, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......@@ -729,12 +728,11 @@ static HRESULT WINAPI IDirect3DRMTexture3Impl_InitFromImage(IDirect3DRMTexture3
return E_NOTIMPL;
}
static HRESULT WINAPI IDirect3DRMTexture3Impl_InitFromResource2(IDirect3DRMTexture3* iface, HMODULE module,
LPCSTR /* LPCTSTR */ name, LPCSTR /* LPCTSTR */ type)
static HRESULT WINAPI IDirect3DRMTexture3Impl_InitFromResource2(IDirect3DRMTexture3 *iface,
HMODULE module, const char *name, const char *type)
{
IDirect3DRMTextureImpl *This = impl_from_IDirect3DRMTexture3(iface);
FIXME("(%p/%p)->(%p, %s, %s): stub\n", iface, This, module, debugstr_a(name), debugstr_a(type));
FIXME("iface %p, module %p, name %s, type %s stub!\n",
iface, module, debugstr_a(name), debugstr_a(type));
return E_NOTIMPL;
}
......
......@@ -154,11 +154,9 @@ static DWORD WINAPI IDirect3DRMViewportImpl_GetAppData(IDirect3DRMViewport* ifac
return 0;
}
static HRESULT WINAPI IDirect3DRMViewportImpl_SetName(IDirect3DRMViewport* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMViewportImpl_SetName(IDirect3DRMViewport *iface, const char *name)
{
IDirect3DRMViewportImpl *This = impl_from_IDirect3DRMViewport(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......@@ -554,11 +552,9 @@ static DWORD WINAPI IDirect3DRMViewport2Impl_GetAppData(IDirect3DRMViewport2* if
return 0;
}
static HRESULT WINAPI IDirect3DRMViewport2Impl_SetName(IDirect3DRMViewport2* iface, LPCSTR name)
static HRESULT WINAPI IDirect3DRMViewport2Impl_SetName(IDirect3DRMViewport2 *iface, const char *name)
{
IDirect3DRMViewportImpl *This = impl_from_IDirect3DRMViewport2(iface);
FIXME("(%p/%p)->(%s): stub\n", iface, This, name);
FIXME("iface %p, name %s stub!\n", iface, debugstr_a(name));
return E_NOTIMPL;
}
......
......@@ -89,8 +89,8 @@ DECLARE_INTERFACE_(IDirect3DRM,IUnknown)
STDMETHOD(CreateUserVisual)(THIS_ D3DRMUSERVISUALCALLBACK cb, void *ctx, IDirect3DRMUserVisual **visual) PURE;
STDMETHOD(LoadTexture)(THIS_ const char *filename, IDirect3DRMTexture **texture) PURE;
STDMETHOD(LoadTextureFromResource)(THIS_ HRSRC resource, IDirect3DRMTexture **texture) PURE;
STDMETHOD(SetSearchPath)(THIS_ LPCSTR) PURE;
STDMETHOD(AddSearchPath)(THIS_ LPCSTR) PURE;
STDMETHOD(SetSearchPath)(THIS_ const char *path) PURE;
STDMETHOD(AddSearchPath)(THIS_ const char *path) PURE;
STDMETHOD(GetSearchPath)(THIS_ DWORD *size_return, LPSTR path_return) PURE;
STDMETHOD(SetDefaultTextureColors)(THIS_ DWORD) PURE;
STDMETHOD(SetDefaultTextureShades)(THIS_ DWORD) PURE;
......@@ -229,8 +229,8 @@ DECLARE_INTERFACE_(IDirect3DRM2,IUnknown)
STDMETHOD(LoadTexture)(THIS_ const char *filename, IDirect3DRMTexture2 **texture) PURE;
STDMETHOD(LoadTextureFromResource)(THIS_ HMODULE module, const char *resource_name,
const char *resource_type, IDirect3DRMTexture2 **texture) PURE;
STDMETHOD(SetSearchPath)(THIS_ LPCSTR) PURE;
STDMETHOD(AddSearchPath)(THIS_ LPCSTR) PURE;
STDMETHOD(SetSearchPath)(THIS_ const char *path) PURE;
STDMETHOD(AddSearchPath)(THIS_ const char *path) PURE;
STDMETHOD(GetSearchPath)(THIS_ DWORD *size_return, LPSTR path_return) PURE;
STDMETHOD(SetDefaultTextureColors)(THIS_ DWORD) PURE;
STDMETHOD(SetDefaultTextureShades)(THIS_ DWORD) PURE;
......@@ -372,8 +372,8 @@ DECLARE_INTERFACE_(IDirect3DRM3,IUnknown)
STDMETHOD(LoadTexture)(THIS_ const char *filename, IDirect3DRMTexture3 **texture) PURE;
STDMETHOD(LoadTextureFromResource)(THIS_ HMODULE module, const char *resource_name,
const char *resource_type, IDirect3DRMTexture3 **texture) PURE;
STDMETHOD(SetSearchPath)(THIS_ LPCSTR) PURE;
STDMETHOD(AddSearchPath)(THIS_ LPCSTR) PURE;
STDMETHOD(SetSearchPath)(THIS_ const char *path) PURE;
STDMETHOD(AddSearchPath)(THIS_ const char *path) PURE;
STDMETHOD(GetSearchPath)(THIS_ DWORD *size_return, LPSTR path_return) PURE;
STDMETHOD(SetDefaultTextureColors)(THIS_ DWORD) PURE;
STDMETHOD(SetDefaultTextureShades)(THIS_ DWORD) PURE;
......
......@@ -354,10 +354,11 @@ typedef DWORD D3DRMLOADOPTIONS;
#define D3DRMLOAD_ASYNCHRONOUS __MSABI_LONG(0x400)
typedef struct _D3DRMLOADRESOURCE {
typedef struct _D3DRMLOADRESOURCE
{
HMODULE hModule;
LPCSTR /*LPCTSTR*/ lpName;
LPCSTR /*LPCTSTR*/ lpType;
const char *lpName;
const char *lpType;
} D3DRMLOADRESOURCE, *LPD3DRMLOADRESOURCE;
typedef struct _D3DRMLOADMEMORY {
......
......@@ -51,7 +51,7 @@ DECLARE_INTERFACE_(IDirect3DRMWinDevice,IDirect3DRMObject)
STDMETHOD(DeleteDestroyCallback)(THIS_ D3DRMOBJECTCALLBACK, LPVOID argument) PURE;
STDMETHOD(SetAppData)(THIS_ DWORD data) PURE;
STDMETHOD_(DWORD, GetAppData)(THIS) PURE;
STDMETHOD(SetName)(THIS_ LPCSTR) PURE;
STDMETHOD(SetName)(THIS_ const char *name) PURE;
STDMETHOD(GetName)(THIS_ LPDWORD lpdwSize, LPSTR lpName) PURE;
STDMETHOD(GetClassName)(THIS_ LPDWORD lpdwSize, LPSTR lpName) PURE;
/*** IDirect3DRMWinDevice methods ***/
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment