argtype Problem
Verfasst: Donnerstag 13. August 2009, 11:07
Ich lade eine DLL mittels Numpy load_library ein. Das klappt auch alles wunderbar.
Ich bekomme nur keine variable an die funktion übergeben. Da bekomme ich sofort
Ich bekomme nur keine variable an die funktion übergeben. Da bekomme ich sofort
Code: Alles auswählen
ValueError: Procedure called with not enough arguments (4 bytes missing) or wrong calling convention
Code: Alles auswählen
from mpl_toolkits.mplot3d import Axes3D
from numpy import *
import matplotlib
matplotlib.use('Tkagg')
import matplotlib.pylab as pylab
mydll = ctypeslib.load_library('meineDLL.dll',__file__)
mydll.ArrayTest2.restype = ctypeslib.ndpointer(dtype=double, ndim=1, shape=(444,444), flags='CONTIGUOUS')
mydll.ArrayTest2.argtype = ctypeslib.ctypes.c_int
X = mydll.GetArrayXYZ(1)
Code: Alles auswählen
double* GetArrayXYZ(int axes);