I've tried to figure this out before. There was a 5.4 Raptor that would be in the parking lot at my previous location in Maryland and I parked next to him and spent about 20 minutes just gawking at both trucks. Of course mine looked better and was a 6.2L.
The only thing that I really found just by looking, you can't really see from one driving by. If you get down on the drivers side wheel well and look through into the engine, you can see the 6.2L sitting in there. I know what the side of the 5.4L looks like, so it looked "different". That's about all I could really tell.
I think that the badges are the way to go -- but even then, I like making people guess. Not that others around here necessarily care what engine I have, or even that it's any different than an F-150. Hell, the Ford dealer didn't even know what it was.