@@ -18,12 +18,12 @@ def process_output(meshes: list[DualContouringMesh], n_stack: int, solutions: So
1818 unstructured_data_meshes : UnstructuredData = _meshes_to_unstruct (meshes , logger )
1919 if PLOT_SUBSURFACE_OBJECT :
2020 _plot_subsurface_object (unstructured_data_meshes )
21- body_meshes , header_meshes = unstructured_data_meshes .to_binary ()
22- header_json = json .dumps (header_meshes )
23- header_json_bytes = header_json .encode ('utf-8' )
24- header_json_length = len (header_json_bytes )
25- header_json_length_bytes = header_json_length .to_bytes (4 , byteorder = 'little' )
26- body_meshes = header_json_length_bytes + header_json_bytes + body_meshes
21+ body_meshes = unstructured_data_meshes .to_binary ()
22+ # header_json = json.dumps(header_meshes)
23+ # header_json_bytes = header_json.encode('utf-8')
24+ # header_json_length = len(header_json_bytes)
25+ # header_json_length_bytes = header_json_length.to_bytes(4, byteorder='little')
26+ # body_meshes = header_json_length_bytes + header_json_bytes + body_meshes
2727
2828 # * serialize octrees
2929 unstructured_data_volume = subsurface .UnstructuredData .from_array (
@@ -35,12 +35,12 @@ def process_output(meshes: list[DualContouringMesh], n_stack: int, solutions: So
3535 ) # TODO: We have to create an array with the shape of simplex array with the id of each simplex
3636 )
3737
38- body_volume , header_volume = unstructured_data_volume .to_binary ()
39- header_json = json .dumps (header_volume )
40- header_json_bytes = header_json .encode ('utf-8' )
41- header_json_length = len (header_json_bytes )
42- header_json_length_bytes = header_json_length .to_bytes (4 , byteorder = 'little' )
43- body_volume = header_json_length_bytes + header_json_bytes + body_volume
38+ body_volume = unstructured_data_volume .to_binary ()
39+ # header_json = json.dumps(header_volume)
40+ # header_json_bytes = header_json.encode('utf-8')
41+ # header_json_length = len(header_json_bytes)
42+ # header_json_length_bytes = header_json_length.to_bytes(4, byteorder='little')
43+ # body_volume = header_json_length_bytes + header_json_bytes + body_volume
4444
4545 # * serialize global header
4646 body = body_meshes + body_volume
0 commit comments