Find mesh nodes using a shader resource (.tres)

Godot Version



Hi , was trying to fetch all the mesh nodes that are using a shader resource (.tres). Say suppose a same shader resource is applied to multiple mesh nodes shader material, changing its shader parameter will reflect in other mesh nodes using it.In the source code can any body tell how I can fetch this data?
One approach I know is by checking the RID of the material for each mesh nodes but if there was any other way to fetch it directly instead of a binary search approach it will be useful.