manipulation.letter_generation
- manipulation.letter_generation.create_sdf_asset_from_letter(text, font_name='Arial', letter_height_meters=0.4, extrusion_depth_meters=0.2, mass=1.0, is_compliant=False, hydroelastic_modulus=100000000.0, hunt_crossley_dissipation=None, mu_dynamic=1.0, mu_static=None, output_dir='.', use_bbox_collision_geometry=False, include_normals=True)
Creates a complete SDF asset (mesh + SDF file) from a single letter.
- Parameters:
text (str) – The character to convert (single letter only).
font_name (str) – The name of the font to use (e.g., ‘Arial’, ‘Times New Roman’).
letter_height_meters (float) – The physical height of the letter in meters.
extrusion_depth_meters (float) – The physical depth/thickness of the letter in meters.
mass (float) – The mass in kg of the object for inertia calculations.
is_compliant (bool) – Whether to use compliant hydroelastic contact.
hydroelastic_modulus (float) – The hydroelastic modulus (Pa).
hunt_crossley_dissipation (float | None) – Hunt-Crossley dissipation parameter (s/m).
mu_dynamic (float | None) – Coefficient of dynamic friction.
mu_static (float | None) – Coefficient of static friction.
output_dir (str) – Directory where the output files will be saved.
use_bbox_collision_geometry (bool) – Whether to use axis-aligned bbox or coacd as collision geometry
include_normals (bool) – Whether to include the normals in the obj file.
- Returns:
Path to the created SDF file, or None if creation failed.
- Return type:
Path | None