mirror of
https://notabug.org/scuti/lib3ddevil1
synced 2024-11-29 10:12:02 +05:30
Fixed getmeshheader()
This commit is contained in:
parent
360d57477d
commit
918e12544d
@ -189,7 +189,7 @@ class Devil1GEO_FN(ctypes.Structure):
|
||||
ctypes.c_char_p)),
|
||||
("getmeshheader", ctypes.CFUNCTYPE(
|
||||
ctypes.c_bool,
|
||||
ctypes.POINTER(MeshHeader),
|
||||
ctypes.POINTER(ctypes.POINTER(MeshHeader)),
|
||||
ctypes.c_uint,
|
||||
ctypes.c_char_p)),
|
||||
("getbatch", ctypes.CFUNCTYPE(
|
||||
@ -224,8 +224,14 @@ if __name__ == "__main__":
|
||||
def geotest(devil1geo, geoheader):
|
||||
with open("pl00.pld_0", "rb") as f:
|
||||
data = f.read()
|
||||
geoheader = ctypes.cast(data, ctypes.POINTER(Header))
|
||||
# geoheader = ctypes.cast(data, ctypes.POINTER(Header))
|
||||
gh = ctypes.pointer(geoheader)
|
||||
devil1geo.getheader(ctypes.byref(gh), data)
|
||||
devil1geo.printheader(geoheader)
|
||||
meshheader = MeshHeader()
|
||||
mh = ctypes.pointer(meshheader)
|
||||
devil1geo.getmeshheader(ctypes.byref(mh), 1, data)
|
||||
devil1geo.printmeshheader(mh)
|
||||
|
||||
def main():
|
||||
sharedlib='./lib3ddevil1.so'
|
||||
|
Loading…
Reference in New Issue
Block a user