Skip to main content

Module fracture_csg

Module fracture_csg 

Expand description

Principled Stress-Cleavage Dynamic Fracture (fracture_csg.rs).

Wires evaluate_stress_cleavage_partition directly into the 3D collision impulse handler:

  • When impact stress $\sigma = J / A$ exceeds tensile_strength, evaluates the principal stress cleavage plane ($\mathbf{n}_{\text{cleavage}} \cdot \mathbf{p} - d_0 = 0$),
  • Splits a convex / box collider into two child debris RigidBody3D bodies with conserved total mass and conserved linear/angular momentum.

Structs§

FractureOutcome3D
Result of splitting a RigidBody3D along a principal tensile stress cleavage plane.

Functions§

evaluate_and_fracture_body
Evaluates whether an impact impulse impact_impulse_ns over contact_area_m2 fractures body, and if $\sigma = J / A \ge \text{tensile_strength}$, partitions the collider along the cleavage plane using evaluate_stress_cleavage_partition.
evaluate_stress_cleavage_partition
Evaluate structural fracture criterion under principal tensile stress $\sigma_1$. Returns Some(true/false) if $\sigma_1 \ge \sigma_{\text{crit}}$ indicating the cleavage partition half-space sign, or None if below threshold.