I have to use a native dll that takes a int** as a parameter.
I have linked the dll function correctly ....
[DllImport(DllPath, CallingConvention = CallingConvention.Cdecl)]
public static extern int *MethodName(int** x,int n,char* filename);
But I can't for the life of me work out how to make a double pointer in c#. I can do it for a single array and single pointer ...
int sarray = new int;
fixed (int* sptr = sarray)
I have built a 2d array of ints
int data = new int[n];
and I loop through a populate etc
Now how do I get a int** from this?
fixed (int** dptr = data)