[Mesa-dev] [PATCH 61/75] st/nine: Switch {Set/Get/Free}PrivateData functions
Axel Davy
axel.davy at ens.fr
Wed Oct 5 20:09:34 UTC 2016
From: Patrick Rudolph <siro at das-labor.org>
Switch {Set/Get/Free}PrivateData function to introduced IUnknown functions.
Signed-off-by: Patrick Rudolph <siro at das-labor.org>
Reviewed-by: Axel Davy <axel.davy at ens.fr>
---
src/gallium/state_trackers/nine/cubetexture9.c | 6 +-
src/gallium/state_trackers/nine/indexbuffer9.c | 6 +-
src/gallium/state_trackers/nine/nine_lock.c | 80 ++++++++++++------------
src/gallium/state_trackers/nine/surface9.c | 6 +-
src/gallium/state_trackers/nine/texture9.c | 6 +-
src/gallium/state_trackers/nine/vertexbuffer9.c | 6 +-
src/gallium/state_trackers/nine/volume9.c | 6 +-
src/gallium/state_trackers/nine/volumetexture9.c | 6 +-
8 files changed, 61 insertions(+), 61 deletions(-)
diff --git a/src/gallium/state_trackers/nine/cubetexture9.c b/src/gallium/state_trackers/nine/cubetexture9.c
index dd1a430..912d508 100644
--- a/src/gallium/state_trackers/nine/cubetexture9.c
+++ b/src/gallium/state_trackers/nine/cubetexture9.c
@@ -302,9 +302,9 @@ IDirect3DCubeTexture9Vtbl NineCubeTexture9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)NineResource9_SetPrivateData,
- (void *)NineResource9_GetPrivateData,
- (void *)NineResource9_FreePrivateData,
+ (void *)NineUnknown_SetPrivateData,
+ (void *)NineUnknown_GetPrivateData,
+ (void *)NineUnknown_FreePrivateData,
(void *)NineResource9_SetPriority,
(void *)NineResource9_GetPriority,
(void *)NineBaseTexture9_PreLoad,
diff --git a/src/gallium/state_trackers/nine/indexbuffer9.c b/src/gallium/state_trackers/nine/indexbuffer9.c
index 0a31d7e..4e65ed7 100644
--- a/src/gallium/state_trackers/nine/indexbuffer9.c
+++ b/src/gallium/state_trackers/nine/indexbuffer9.c
@@ -115,9 +115,9 @@ IDirect3DIndexBuffer9Vtbl NineIndexBuffer9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)NineResource9_SetPrivateData,
- (void *)NineResource9_GetPrivateData,
- (void *)NineResource9_FreePrivateData,
+ (void *)NineUnknown_SetPrivateData,
+ (void *)NineUnknown_GetPrivateData,
+ (void *)NineUnknown_FreePrivateData,
(void *)NineResource9_SetPriority,
(void *)NineResource9_GetPriority,
(void *)NineResource9_PreLoad,
diff --git a/src/gallium/state_trackers/nine/nine_lock.c b/src/gallium/state_trackers/nine/nine_lock.c
index 6e15cc1..228abec 100644
--- a/src/gallium/state_trackers/nine/nine_lock.c
+++ b/src/gallium/state_trackers/nine/nine_lock.c
@@ -122,56 +122,56 @@ IDirect3DAuthenticatedChannel9Vtbl LockAuthenticatedChannel9_vtable = {
(void *)LockAuthenticatedChannel9_Configure
};
-#if 0
static HRESULT NINE_WINAPI
-LockResource9_GetDevice( struct NineResource9 *This,
- IDirect3DDevice9 **ppDevice )
+LockUnknown_SetPrivateData( struct NineUnknown *This,
+ REFGUID refguid,
+ const void *pData,
+ DWORD SizeOfData,
+ DWORD Flags )
{
HRESULT r;
pipe_mutex_lock(d3dlock_global);
- r = NineUnknown_GetDevice(NineUnknown(This), ppDevice);
+ r = NineUnknown_SetPrivateData(This, refguid, pData, SizeOfData, Flags);
pipe_mutex_unlock(d3dlock_global);
return r;
}
-#endif
static HRESULT NINE_WINAPI
-LockResource9_SetPrivateData( struct NineResource9 *This,
- REFGUID refguid,
- const void *pData,
- DWORD SizeOfData,
- DWORD Flags )
+LockUnknown_GetPrivateData( struct NineUnknown *This,
+ REFGUID refguid,
+ void *pData,
+ DWORD *pSizeOfData )
{
HRESULT r;
pipe_mutex_lock(d3dlock_global);
- r = NineResource9_SetPrivateData(This, refguid, pData, SizeOfData, Flags);
+ r = NineUnknown_GetPrivateData(This, refguid, pData, pSizeOfData);
pipe_mutex_unlock(d3dlock_global);
return r;
}
static HRESULT NINE_WINAPI
-LockResource9_GetPrivateData( struct NineResource9 *This,
- REFGUID refguid,
- void *pData,
- DWORD *pSizeOfData )
+LockUnknown_FreePrivateData( struct NineUnknown *This,
+ REFGUID refguid )
{
HRESULT r;
pipe_mutex_lock(d3dlock_global);
- r = NineResource9_GetPrivateData(This, refguid, pData, pSizeOfData);
+ r = NineUnknown_FreePrivateData(This, refguid);
pipe_mutex_unlock(d3dlock_global);
return r;
}
+#if 0
static HRESULT NINE_WINAPI
-LockResource9_FreePrivateData( struct NineResource9 *This,
- REFGUID refguid )
+LockResource9_GetDevice( struct NineResource9 *This,
+ IDirect3DDevice9 **ppDevice )
{
HRESULT r;
pipe_mutex_lock(d3dlock_global);
- r = NineResource9_FreePrivateData(This, refguid);
+ r = NineUnknown_GetDevice(NineUnknown(This), ppDevice);
pipe_mutex_unlock(d3dlock_global);
return r;
}
+#endif
static DWORD NINE_WINAPI
LockResource9_SetPriority( struct NineResource9 *This,
@@ -483,9 +483,9 @@ IDirect3DCubeTexture9Vtbl LockCubeTexture9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)LockResource9_SetPrivateData,
- (void *)LockResource9_GetPrivateData,
- (void *)LockResource9_FreePrivateData,
+ (void *)LockUnknown_SetPrivateData,
+ (void *)LockUnknown_GetPrivateData,
+ (void *)LockUnknown_FreePrivateData,
(void *)LockResource9_SetPriority,
(void *)LockResource9_GetPriority,
(void *)LockBaseTexture9_PreLoad,
@@ -2495,9 +2495,9 @@ IDirect3DIndexBuffer9Vtbl LockIndexBuffer9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)LockResource9_SetPrivateData,
- (void *)LockResource9_GetPrivateData,
- (void *)LockResource9_FreePrivateData,
+ (void *)LockUnknown_SetPrivateData,
+ (void *)LockUnknown_GetPrivateData,
+ (void *)LockUnknown_FreePrivateData,
(void *)LockResource9_SetPriority,
(void *)LockResource9_GetPriority,
(void *)NineResource9_PreLoad, /* nop */
@@ -2729,9 +2729,9 @@ IDirect3DSurface9Vtbl LockSurface9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)LockResource9_SetPrivateData,
- (void *)LockResource9_GetPrivateData,
- (void *)LockResource9_FreePrivateData,
+ (void *)LockUnknown_SetPrivateData,
+ (void *)LockUnknown_GetPrivateData,
+ (void *)LockUnknown_FreePrivateData,
(void *)LockResource9_SetPriority,
(void *)LockResource9_GetPriority,
(void *)NineResource9_PreLoad, /* nop */
@@ -2961,9 +2961,9 @@ IDirect3DTexture9Vtbl LockTexture9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)LockResource9_SetPrivateData,
- (void *)LockResource9_GetPrivateData,
- (void *)LockResource9_FreePrivateData,
+ (void *)LockUnknown_SetPrivateData,
+ (void *)LockUnknown_GetPrivateData,
+ (void *)LockUnknown_FreePrivateData,
(void *)LockResource9_SetPriority,
(void *)LockResource9_GetPriority,
(void *)LockBaseTexture9_PreLoad,
@@ -3023,9 +3023,9 @@ IDirect3DVertexBuffer9Vtbl LockVertexBuffer9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)LockResource9_SetPrivateData,
- (void *)LockResource9_GetPrivateData,
- (void *)LockResource9_FreePrivateData,
+ (void *)LockUnknown_SetPrivateData,
+ (void *)LockUnknown_GetPrivateData,
+ (void *)LockUnknown_FreePrivateData,
(void *)LockResource9_SetPriority,
(void *)LockResource9_GetPriority,
(void *)NineResource9_PreLoad, /* nop */
@@ -3205,9 +3205,9 @@ IDirect3DVolume9Vtbl LockVolume9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Volume9 iface */
- (void *)LockVolume9_SetPrivateData,
- (void *)LockVolume9_GetPrivateData,
- (void *)LockVolume9_FreePrivateData,
+ (void *)NineUnknown_SetPrivateData,
+ (void *)NineUnknown_GetPrivateData,
+ (void *)NineUnknown_FreePrivateData,
(void *)LockVolume9_GetContainer,
(void *)NineVolume9_GetDesc, /* immutable */
(void *)LockVolume9_LockBox,
@@ -3283,9 +3283,9 @@ IDirect3DVolumeTexture9Vtbl LockVolumeTexture9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)LockResource9_SetPrivateData,
- (void *)LockResource9_GetPrivateData,
- (void *)LockResource9_FreePrivateData,
+ (void *)LockUnknown_SetPrivateData,
+ (void *)LockUnknown_GetPrivateData,
+ (void *)LockUnknown_FreePrivateData,
(void *)LockResource9_SetPriority,
(void *)LockResource9_GetPriority,
(void *)LockBaseTexture9_PreLoad,
diff --git a/src/gallium/state_trackers/nine/surface9.c b/src/gallium/state_trackers/nine/surface9.c
index bf485bb..ffa8c2a 100644
--- a/src/gallium/state_trackers/nine/surface9.c
+++ b/src/gallium/state_trackers/nine/surface9.c
@@ -545,9 +545,9 @@ IDirect3DSurface9Vtbl NineSurface9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)NineResource9_SetPrivateData,
- (void *)NineResource9_GetPrivateData,
- (void *)NineResource9_FreePrivateData,
+ (void *)NineUnknown_SetPrivateData,
+ (void *)NineUnknown_GetPrivateData,
+ (void *)NineUnknown_FreePrivateData,
(void *)NineResource9_SetPriority,
(void *)NineResource9_GetPriority,
(void *)NineResource9_PreLoad,
diff --git a/src/gallium/state_trackers/nine/texture9.c b/src/gallium/state_trackers/nine/texture9.c
index 4f16e60..a13d7f4 100644
--- a/src/gallium/state_trackers/nine/texture9.c
+++ b/src/gallium/state_trackers/nine/texture9.c
@@ -345,9 +345,9 @@ IDirect3DTexture9Vtbl NineTexture9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)NineResource9_SetPrivateData,
- (void *)NineResource9_GetPrivateData,
- (void *)NineResource9_FreePrivateData,
+ (void *)NineUnknown_SetPrivateData,
+ (void *)NineUnknown_GetPrivateData,
+ (void *)NineUnknown_FreePrivateData,
(void *)NineResource9_SetPriority,
(void *)NineResource9_GetPriority,
(void *)NineBaseTexture9_PreLoad,
diff --git a/src/gallium/state_trackers/nine/vertexbuffer9.c b/src/gallium/state_trackers/nine/vertexbuffer9.c
index 7c00b2d..b0eebfb 100644
--- a/src/gallium/state_trackers/nine/vertexbuffer9.c
+++ b/src/gallium/state_trackers/nine/vertexbuffer9.c
@@ -98,9 +98,9 @@ IDirect3DVertexBuffer9Vtbl NineVertexBuffer9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)NineResource9_SetPrivateData,
- (void *)NineResource9_GetPrivateData,
- (void *)NineResource9_FreePrivateData,
+ (void *)NineUnknown_SetPrivateData,
+ (void *)NineUnknown_GetPrivateData,
+ (void *)NineUnknown_FreePrivateData,
(void *)NineResource9_SetPriority,
(void *)NineResource9_GetPriority,
(void *)NineResource9_PreLoad,
diff --git a/src/gallium/state_trackers/nine/volume9.c b/src/gallium/state_trackers/nine/volume9.c
index eb712f5..f597849 100644
--- a/src/gallium/state_trackers/nine/volume9.c
+++ b/src/gallium/state_trackers/nine/volume9.c
@@ -513,9 +513,9 @@ IDirect3DVolume9Vtbl NineVolume9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Volume9 iface */
- (void *)NineVolume9_SetPrivateData,
- (void *)NineVolume9_GetPrivateData,
- (void *)NineVolume9_FreePrivateData,
+ (void *)NineUnknown_SetPrivateData,
+ (void *)NineUnknown_GetPrivateData,
+ (void *)NineUnknown_FreePrivateData,
(void *)NineVolume9_GetContainer,
(void *)NineVolume9_GetDesc,
(void *)NineVolume9_LockBox,
diff --git a/src/gallium/state_trackers/nine/volumetexture9.c b/src/gallium/state_trackers/nine/volumetexture9.c
index e5db6fc..4908ed7 100644
--- a/src/gallium/state_trackers/nine/volumetexture9.c
+++ b/src/gallium/state_trackers/nine/volumetexture9.c
@@ -243,9 +243,9 @@ IDirect3DVolumeTexture9Vtbl NineVolumeTexture9_vtable = {
(void *)NineUnknown_AddRef,
(void *)NineUnknown_Release,
(void *)NineUnknown_GetDevice, /* actually part of Resource9 iface */
- (void *)NineResource9_SetPrivateData,
- (void *)NineResource9_GetPrivateData,
- (void *)NineResource9_FreePrivateData,
+ (void *)NineUnknown_SetPrivateData,
+ (void *)NineUnknown_GetPrivateData,
+ (void *)NineUnknown_FreePrivateData,
(void *)NineResource9_SetPriority,
(void *)NineResource9_GetPriority,
(void *)NineBaseTexture9_PreLoad,
--
2.10.0
More information about the mesa-dev
mailing list