@@ -1231,7 +1231,6 @@ class IntersectionShaper : public Shaper
1231
1231
const int device_allocator = m_allocatorId;
1232
1232
1233
1233
constexpr int NUM_TETS_PER_HEX = 24 ;
1234
- constexpr double ZERO_THRESHOLD = 1 .e -10 ;
1235
1234
1236
1235
SLIC_INFO (axom::fmt::format (" {:-^80}" ,
1237
1236
" Inserting shapes' bounding boxes into BVH " ));
@@ -1260,11 +1259,6 @@ class IntersectionShaper : public Shaper
1260
1259
1261
1260
axom::ArrayView<const BoundingBox3D> hex_bbs_device_view = m_hex_bbs.view ();
1262
1261
1263
- // Set shape components to zero if within threshold
1264
- snapShapeVerticesToZero<ExecSpace, ShapeType>(shapes,
1265
- shape_count,
1266
- ZERO_THRESHOLD);
1267
-
1268
1262
// Find which shape bounding boxes intersect hexahedron bounding boxes
1269
1263
SLIC_INFO (axom::fmt::format (
1270
1264
" {:-^80}" ,
@@ -2782,7 +2776,6 @@ class IntersectionShaper : public Shaper
2782
2776
2783
2777
m_hexes = axom::Array<HexahedronType>(m_cellCount, m_cellCount, allocId);
2784
2778
axom::ArrayView<HexahedronType> hexes_device_view = m_hexes.view ();
2785
- constexpr double ZERO_THRESHOLD = 1 .e -10 ;
2786
2779
axom::for_all<ExecSpace>(
2787
2780
m_cellCount,
2788
2781
AXOM_LAMBDA (axom::IndexType i) {
@@ -2796,63 +2789,10 @@ class IntersectionShaper : public Shaper
2796
2789
Point3D ({vertCoords_device_view[vertIndex],
2797
2790
vertCoords_device_view[vertIndex + 1 ],
2798
2791
vertCoords_device_view[vertIndex + 2 ]});
2799
-
2800
- // Set hexahedra components to zero if within threshold
2801
- if (axom::utilities::isNearlyEqual (hexes_device_view[i][j][0 ],
2802
- 0.0 ,
2803
- ZERO_THRESHOLD))
2804
- {
2805
- hexes_device_view[i][j][0 ] = 0.0 ;
2806
- }
2807
-
2808
- if (axom::utilities::isNearlyEqual (hexes_device_view[i][j][1 ],
2809
- 0.0 ,
2810
- ZERO_THRESHOLD))
2811
- {
2812
- hexes_device_view[i][j][1 ] = 0.0 ;
2813
- }
2814
-
2815
- if (axom::utilities::isNearlyEqual (hexes_device_view[i][j][2 ],
2816
- 0.0 ,
2817
- ZERO_THRESHOLD))
2818
- {
2819
- hexes_device_view[i][j][2 ] = 0.0 ;
2820
- }
2821
2792
}
2822
2793
}); // end of loop to initialize hexahedral elements and bounding boxes
2823
2794
}
2824
2795
2825
- // !\brief Set shape vertices to zero of within threshold.
2826
- template <typename ExecSpace, typename ShapeType>
2827
- void snapShapeVerticesToZero (axom::Array<ShapeType>& shapes,
2828
- axom::IndexType shapeCount,
2829
- double zeroThreshold)
2830
- {
2831
- AXOM_ANNOTATE_SCOPE (" snapShapeVerticesToZero" );
2832
- axom::ArrayView<ShapeType> shapesView = shapes.view ();
2833
- axom::for_all<ExecSpace>(
2834
- shapeCount,
2835
- AXOM_LAMBDA (axom::IndexType i) {
2836
- for (int j = 0 ; j < ShapeType::NUM_VERTS; j++)
2837
- {
2838
- if (axom::utilities::isNearlyEqual (shapesView[i][j][0 ], 0.0 , zeroThreshold))
2839
- {
2840
- shapesView[i][j][0 ] = 0.0 ;
2841
- }
2842
-
2843
- if (axom::utilities::isNearlyEqual (shapesView[i][j][1 ], 0.0 , zeroThreshold))
2844
- {
2845
- shapesView[i][j][1 ] = 0.0 ;
2846
- }
2847
-
2848
- if (axom::utilities::isNearlyEqual (shapesView[i][j][2 ], 0.0 , zeroThreshold))
2849
- {
2850
- shapesView[i][j][2 ] = 0.0 ;
2851
- }
2852
- }
2853
- });
2854
- }
2855
-
2856
2796
#if defined(AXOM_USE_CONDUIT)
2857
2797
template <typename ExecSpace>
2858
2798
void populateVertCoordsFromBlueprintMesh2D (axom::Array<double >& vertCoords)
0 commit comments