Skip to content

Commit c63e38d

Browse files
committed
[BUG] Fixing broken vertex overlap
1 parent 5c9c924 commit c63e38d

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

gempy_engine/API/dual_contouring/multi_scalar_dual_contouring.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ def dual_contouring_multi_scalar(
103103
# region Vertex gen and triangulation
104104
left_right_per_mesh = []
105105
# Generate meshes for each scalar field
106-
if LEGACY:=True:
106+
if LEGACY:=False:
107107
for n_scalar_field in range(data_descriptor.stack_structure.n_stacks):
108108
_compute_meshes_legacy(all_left_right_codes, all_mask_arrays, all_meshes, all_surfaces_intersection, all_valid_edges, n_scalar_field, octree_leaves, options, output_on_edges)
109109
else:
@@ -132,14 +132,15 @@ def dual_contouring_multi_scalar(
132132
)
133133

134134
dc_data_per_surface_all.append(dc_data_per_surface)
135+
left_right_per_mesh.append(all_left_right_codes[0][dc_data_per_surface.valid_voxels])
135136

136137
from gempy_engine.modules.dual_contouring._dual_contouring_v2 import compute_dual_contouring_v2
137138
all_meshes = compute_dual_contouring_v2(
138139
dc_data_list=dc_data_per_surface_all,
139140
)
140141
# endregion
141-
if (options.debug or len(all_left_right_codes) > 1) and True:
142-
apply_faults_vertex_overlap(all_meshes, data_descriptor.stack_structure, all_left_right_codes)
142+
if (options.debug or len(all_left_right_codes) > 1) and True:
143+
apply_faults_vertex_overlap(all_meshes, data_descriptor.stack_structure, left_right_per_mesh)
143144

144145
return all_meshes
145146

0 commit comments

Comments
 (0)