Foliage bounding box per instanced mesh

Hey there!

Im making a wind shader for some tree meshes and Im using their bounding box to calculate a gradient mask in the Z-axis for bending the entire tree. Sadly though this doesnt work when I paint my trees as foliage instances, since they share the same bounding box. So I was wondering whether or not there is a way to get a bounding box per instanced mesh?

Im uploading a photo showing the result I want on a cube and what result I get when using the foliage tool, just for clarity

Thanks! :smiley: