Page MenuHome

Fix: Volume grid duplication after importing USD file
ClosedPublic

Authored by Piotr Makal (pmakal) on Feb 27 2022, 8:40 PM.

Details

Summary

This patch fixes volume grid duplication which was occurring during importing USD files. This was caused by calling BKE_volume_grid_add twice per grid (excluding 'density' grid) for the same Volume object: (1) in USDVolumeReader::read_object_data and (2) later in BKE_volume_load.

Can be tested with:


Diff Detail

Repository
rB Blender

Event Timeline

Piotr Makal (pmakal) requested review of this revision.Feb 27 2022, 8:40 PM
Piotr Makal (pmakal) created this revision.
Piotr Makal (pmakal) edited the summary of this revision. (Show Details)Feb 27 2022, 9:07 PM

Good catch, @Piotr Makal (pmakal)! I will test this functionality this week.

This change looks good to me! Again, thanks for discovering this @Piotr Makal (pmakal). Unless @Sybren A. Stüvel (sybren) has additional remarks or wants to review further, I think this can be committed. We can confirm whether additional review is needed this week.

I'm approving these changes and will commit the fix.

This revision is now accepted and ready to land.Mar 24 2022, 4:31 PM