Skip to content

Conversation

@dongclin
Copy link

@dongclin dongclin commented Dec 4, 2025

Description

This PR enhances the Mesh::to_string() method to include a string representation of the mesh's children properties, such as the BSDF. This provide more comprehensive information when inspecting mesh objects.

Shapes like mi.Disk and mi.Rectangle include information about their children (e.g. BSDF) in their string representation by calling get_children_string(). However, mi.Mesh and by extension its subclasses like mi.OBJMesh and mi.Cube didn't include this information in their to_string() output.

Testing

The existing Python tests in src/render/tests/test_mesh.py have been updated to account for the modified output of the to_string() method. These tests now validate that the child properties are correctly included in the string representation of the mesh.

Checklist

  • My code follows the style guidelines of this project
  • My changes generate no new warnings
  • My code also compiles for cuda_* and llvm_* variants. If you can't test this, please leave below
  • I have commented my code
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • I cleaned the commit history and removed any "Merge" commits
  • I give permission that the Mitsuba 3 project may redistribute my contributions under the terms of its license

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant