st/nine: Increase minor d3dadapter9drm ABI
authorAxel Davy <axel.davy@ens.fr>
Sat, 5 Mar 2016 11:17:06 +0000 (12:17 +0100)
committerAxel Davy <axel.davy@ens.fr>
Wed, 18 May 2016 21:37:14 +0000 (23:37 +0200)
Version 0.1 allows to assume that the second
element of the IDirect3D* structures will
be a pointer to the internal nine vtable.

This is useful if the gallium nine user wants
to wrap some interfaces.

Signed-off-by: Axel Davy <axel.davy@ens.fr>
include/d3dadapter/drm.h
src/gallium/state_trackers/nine/iunknown.c
src/gallium/state_trackers/nine/iunknown.h

index 9ec3e60661cfd008cdca411eabf640e749204a00..647f017fc7f2feec5871667ff87f3c0f92552e57 100644 (file)
 #define D3DADAPTER9DRM_NAME "drm"
 /* current version */
 #define D3DADAPTER9DRM_MAJOR 0
-#define D3DADAPTER9DRM_MINOR 0
+#define D3DADAPTER9DRM_MINOR 1
+
+/* version 0.0: Initial release
+ *         0.1: All IDirect3D objects can be assumed to have a pointer to the
+ *              internal vtable in second position of the structure */
 
 struct D3DAdapter9DRM
 {
index 515ceaa263f38ad4f1de6d6fd9c60c510bcbfebd..58ed9dc73a110b964300f9f6a2dd804c4c788e99 100644 (file)
@@ -39,6 +39,7 @@ NineUnknown_ctor( struct NineUnknown *This,
         NineUnknown_AddRef(NineUnknown(This->device));
 
     This->vtable = pParams->vtable;
+    This->vtable_internal = pParams->vtable;
     This->guids = pParams->guids;
     This->dtor = pParams->dtor;
 
index b8de6be966374fd792f097c26aea43db75b0d6e1..bcd0b8bce9dbe562e41e93dd92a9a7969177f396 100644 (file)
@@ -39,8 +39,10 @@ struct NineDevice9;
 
 struct NineUnknown
 {
-    /* pointer to vtable  */
+    /* pointer to vtable (can be overriden outside gallium nine) */
     void *vtable;
+    /* pointer to internal vtable  */
+    void *vtable_internal;
 
     int32_t refs; /* external reference count */
     int32_t bind; /* internal bind count */