If the passing gas analogy works for your example then masks would be proved useless because, as Kelly on Real Housewives of Orange County said, "does your underwear stop a fart?"
The reason the analogy doesn't work in either case is because one is actually a gas and the other is particles of virus.
The reason that outdoors is a low risk for infection is because it is the most "well ventilated" that you can be outside of a clean room or something specifically designed for changing out air very frequently. It takes a critical mass of virus particles to infect somebody. Indoors or outdoors if somebody is infected and coughs in your face, you will be somewhat likely to get infected. However, the spread from presymptomatic or asymptomatic people is due to the particles building up in the air to the point that you can ingest a high enough viral load to get infected. Outdoors, these particles will not build up in any spot nearly as much. The more wind, the less build up.
If it is daytime, the sunlight will kill the virus relatively quickly as well, further preventing the buildup.
For an analogy, if you grilled burgers on a propane grill in your kitchen, it wouldn't take too long for smoke to build up to the point that nobody wants to be in your house. If you do the same outside, the smoke doesn't build up like that and everybody is having fun in the back yard.