Added consistent naming for methods for geo

This commit is contained in:
_ 2018-05-17 16:30:01 -07:00
parent 0c86779304
commit 058e395735
2 changed files with 4 additions and 4 deletions

View File

@ -94,7 +94,7 @@ if __name__ == "__main__":
gh = pyGeoHeader(data)
gh.show()
print("-------------")
print(gh.getmeshno())
print(gh.getnummesh())
print(gh.getunknownb())
print(gh.getunknownc())
print(gh.getunknownd())

View File

@ -158,7 +158,7 @@ class pyGeoHeader:
def show(self):
devil1geo.printheader(self.cstruct)
def getmeshno(self):
def getnummesh(self):
return self.cstruct.contents.numMesh
def getunknownb(self):
@ -190,7 +190,7 @@ class pyMeshHeader:
def show(self):
devil1geo.printmeshheader(self.cstruct)
def getbatchno(self):
def getnumbatch(self):
return self.cstruct.contents.numBatch
def getnumvertex(self):
@ -211,7 +211,7 @@ class pyMesh:
if filedata:
mh = pyMeshHeader(i, filedata)
# allocate memory for the size of batch * number of batches
memsize = ctypes.sizeof(Batch) * mh.getbatchno()
memsize = ctypes.sizeof(Batch) * mh.getnumbatch()
self.cstruct.b = ctypes.cast(
ctypes.create_string_buffer(memsize),
ctypes.POINTER(Batch))