Details
Diff Detail
- Repository
- rB Blender
Event Timeline
Without reading the code for BKE_mesh_copy I also got a bit tripped up that you had to do id_free instead of mesh_free.
Perhaps the additional variable bmain in the copy call could be enough of a hint that it is simply not just copying that data for the mesh... (But to me it was still unclear if I just go by what the actual function is called)
This patch seems fine to me, but I feel that perhaps we could make it more clear that mesh_copy doesn't actually just copy the mesh?
@Brecht Van Lommel (brecht) ^
Thought that would most likely not be something we should slap into this patch.
Yes, we should rename the BKE_mesh_copy to something else and document it, but that is separate task.
Talked to @Bastien Montagne (mont29) and all these copy functions can be replaced w/ ID copy, see: T71219: Refactor out BKE ID copy functions