By shortest path do you mean least number of hops, or shortest distance traveled? In either case, I feel that it is not possible. If you were to use RSSI alone then the network would surely favor long routes around obstacles that - total energy expenditure wise - would have been cheaper to transmit through. In the diagram attached, the least number of hops (Path D) would have the lowest RSSI. I hope this helps.