Output is padded with an extra two bytes, to Possibly work better with other tools.

master
TigerKat 5 years ago
parent a2515dc7f3
commit 5ce02d497a

@ -846,6 +846,10 @@ class Model:
self.header_data += struct.pack("<fff", *self.autolod_dists) self.header_data += struct.pack("<fff", *self.autolod_dists)
self.header_data += struct.pack("<h", self.id) self.header_data += struct.pack("<h", self.id)
if self.geo.version >= 8:
#Pad to match the alignment of "ModelFormatOnDisk_v8" produced by "GetVrml/output.c"
self.header_data += struct.pack("<h", 0)
self.header_data = struct.pack("<i", len(self.header_data) + 4) + self.header_data self.header_data = struct.pack("<i", len(self.header_data) + 4) + self.header_data
pass pass
def encodeHeader(self): def encodeHeader(self):

Loading…
Cancel
Save